This is a Lunar Lander clone written in C++ and OpenGL. Use the arrow keys to move the ship and avoid crashing into obstacles. Collect all the spinning keys and then land the ship on one of the landing pads. The levels are randomly generated and become progressively harder.
It’s written using relatively platform-neutral SDL, and I’ve successfully built and run it on Linux, Windows, and OS X.
NOTE: I haven’t been able to test the latest version on OS X, so it is likely that it will not build. I’ll hopefully post a Mac binary later.
A few screen shots:
Follow these links to download the latest version:
- Source code: lander-0.7.2.tar.xz
Previous version:
- Source code: lander-0.6.4.tar.gz
- Windows installer: Lander-0.6.0.msi
Thanks, it’s the best LL game I’ve seen so far.
Made FreeBSD port for it: http://www.freshports.org/games/lander/, compiles without problems out of box.
February 24, 2009 @ 12:30 am
I had an annoying problem with huge lag on the sound in the game. However, this is purely due to having an oversized sound buffer. The following change to SoundEffect.cpp completely fixes the problem:
int SoundEffect::audioRate(44100); //Halves the time it takes to get through the buffer and standard rate for sounds (considered optimal). Also this is the native format of the .wav files you use, so no conversion is needed…
int SoundEffect::audioChannels(2); //stereo sound is correct – no change here
int SoundEffect::audioBuffers(1024); //The smaller this is the less sound lag there is. 1024 is pretty standard for 44kHz sample rate I think. Definitely small enough, yet not too small.
Nice little game anyway! Much better than the last clone of this I tried…
March 1, 2009 @ 1:39 am
Scratch that, it still works when buffers is set to 0, and even then there’s some delay, so it must be a problem with the libs (possibly PulseAudio as you say but no clue). Try 1024 on other systems without the lag, and see if that works correctly (I suspect 4096 is probably really more acceptable), if so, this can be a workaround for the real issue… Of course, the sample rate should be 44100 regardless of all this!
March 1, 2009 @ 4:09 am
The license of the sound files (apparently Creative Commons Sampling+) is non-free, and prevents the game from being included into Libregamewiki.
If you make a source package without the sounds, it will be eligible.
Thanks.
March 17, 2009 @ 12:26 am
sorry i accedantly pressed submit.
5.
a few errors:
my comp:asus 901 eeepc linux i386 coreos linu version 2.6.41.4
new comp,new noob
full desktop enabled
adminastritive: on
errors:
nothing important i think + error –
basic manuals(typing to you cuz you will know whats the problem)
1.step: `cd’ to the directory containing the package’s source code and type
`./configure’ to configure the package for your system.
2.step:Type `make’ to compile the package.
3.step:Optionally, type `make check’ to run any self-tests that come with
the package.
4.step:Type `make install’ to install the programs and any data files and
documentation.
5.step: (i dont need this one.)
so:
1st. su
then typing ‘cd’…(no points upward codes) ‘cd /(directorys)/lander-0.5.2
+(opens folder and gets new line for code)
‘./configure'(writing in new line)(also why i need point here /configuration(point marked with ))
– error:
checking for a BSD-compatible install… /usr/bin/install -c
checking whether build environment is sane… yes
checking for a thread-safe mkdir -p… /bin/mkdir -p
checking for gawk… no
checking for mawk… mawk
checking whether make sets $(MAKE)… yes
checking for gcc… no
checking for cc… no
checking for cl.exe… no
configure: error: no acceptable C compiler found in $PATH
See `config.log’ for more details.
2nd.typing ‘make’
– first error:
“make: *** No targets specified and no makefile found. Stop.”(messages ” ” this like points)
or i am doing some mistake, so iam ignoring it and going further:
3rd.typing ‘make check’
– error:
“make: *** No rule to make target `check’. Stop.”
i fink i am doing a really seenable mistake but i dunno know what to write here for real.ignoring.
4th.typing ‘make insall’: “make: *** No rule to make target `install’. Stop.”
wtf-in rule?!
5.i said i dont need it idiot!(myself haha :) )
i am registered on su (sudo)so wha i should do now?
thanx for eweryone who post “step-by-step” (lol error ” “)
nice day and helping me guys!!
SP
March 22, 2009 @ 12:40 pm
oky doky Nick, thanx a lot i will bring more thanx to you later if it will work also my linux debian is on default but i am using full desktop i think it wouldnt bug my whells.
March 25, 2009 @ 6:38 pm
i think i can use wine for dis game but i need to learn something on this by using linux debian.
i dont know if it works because i just today had dinohunters for windows xp and used wine to work like dis:
wine Dinohunters.exe
it does installiation and other but i can’t play game so can you help me installing this game on linux debian.
March 28, 2009 @ 11:39 am
sorry for so big posting but:
i tried to do same again i wrote:
directorys/lander-0.5.2 make insta
and getting “write a new line”…
:(
March 28, 2009 @ 12:29 pm
i got installed bloddfrontier and i don’t know how i think it installed in it’s self…
cuz i just needed to press bloodfrontier.sh and it worked.
linux… give us more that like installing games!
April 4, 2009 @ 11:34 am
At some point I’ll add DEB and RPM packages for Lander… but it’s not quite finished yet ;-)
April 4, 2009 @ 6:56 pm
i got factory settings restarted :D
so can you make it downloadable trough repository. also i was at eeepc forum and i think it needs chmod a+x to work the configure file because it’s not executable…
April 8, 2009 @ 11:35 am
The configure script is already executable when you extract the archive (just checked).
I don’t really have any spare time at the moment to make a DEB/RPM package. If someone else wants to do it I’ll happily put it on the site…
April 8, 2009 @ 11:39 am
I’m considering making an RPM and submitting this for Fedora, but the licensing of the sounds prevents this. Did you create the sounds, or are they from somewhere else? I could help create new sounds if desired.
Cheers,
Jon
July 20, 2009 @ 4:27 pm
Great stuff!
Steve
LinuxLinks.com
http://www.linuxlinks.com
August 23, 2009 @ 3:32 pm
[…] Lunar Lander(责任编辑:A6) […]
May 2, 2010 @ 12:51 am
I can’t install Lunar Lander 0.6.0
make
g++ -I/usr/include/freetype2 -I/usr/include/libpng14 -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT -Wall -g -O2 -lfreetype -lpng14 -lSDL -lpthread -lboost_filesystem-1_35 -lGLU -o lander Main.o Game.o Font.o HighScores.o Input.o OpenGL.o Menu.o Emitter.o ScreenManager.o ObjectGrid.o Asteroid.o Ship.o Viewport.o LandingPad.o Surface.o Mine.o ElectricGate.o Key.o Missile.o Image.o AnimatedImage.o Texture.o Options.o ConfigFile.o SoundEffect.o Fade.o InterfaceSounds.o -lSDL_mixer -lSDL_image
Main.o: In function `__static_initialization_and_destruction_0′:
/usr/include/boost/system/error_code.hpp:209: undefined reference to `boost::system::get_generic_category()’
/usr/include/boost/system/error_code.hpp:214: undefined reference to `boost::system::get_generic_category()’
/usr/include/boost/system/error_code.hpp:215: undefined reference to `boost::system::get_generic_category()’
HighScores.o: In function `__static_initialization_and_destruction_0′:
/usr/include/boost/system/error_code.hpp:209: undefined reference to `boost::system::get_generic_category()’
/usr/include/boost/system/error_code.hpp:214: undefined reference to `boost::system::get_generic_category()’
HighScores.o:/usr/include/boost/system/error_code.hpp:215: more undefined references to `boost::system::get_generic_category()’ follow
collect2: ld returned 1 exit status
Also I can’t install Lunar Lander 0.5.3
make is good but
make install
test -z “/usr/local/share/lander” || /bin/mkdir -p “/usr/local/share/lander”
/bin/sh /games/Lunar Lander/Lunar Lander/lander-0.5.3/install-sh -c -m 644 ‘images/ship.png’ ‘/usr/local/share/lander/images/ship.png’
/bin/sh: /games/Lunar: No such file or directory
/bin/sh /games/Lunar Lander/Lunar Lander/lander-0.5.3/install-sh -c -m 644 ‘images/star.png’ ‘/usr/local/share/lander/images/star.png’
/bin/sh: /games/Lunar: No such file or directory
:o( Please correct this, thanks
June 13, 2010 @ 1:07 pm
> I can’t install Lunar Lander 0.6.0
>
Hi,
I’m not sure exactly what the problem is here, but it looks like it’s missing some symbol from the boost.system package. Which version of boost are you using? I can’t reproduce this with 1.40 or 1.42. Anyway, I think the attached patch may fix it.
>
> Also I can’t install Lunar Lander 0.5.3
>
The problem here is the space in the build path. Unfortunately I think this is a problem with GNU autotools rather than the Lander package itself…
June 13, 2010 @ 3:01 pm
I use boost-1.42 and also have this Problem with Lunar Lander 0.6.0 with boost-1.41.
> Anyway, I think the attached patch may fix it.
I have used this patch with
patch -p1 configure.ac < lander.patch
But the same with boost.
I use Gentoo, have all this Packages reinstalled, but the same with 0.5.3
sys-devel/libtool- 2.2.6b
sys-devel/autoconf-2.13
sys-devel/automake- 1.11.1
sys-devel/gettext-0.18.1
media-libs/libsdl-1.2.13-r1
What can I do to install Lunar Landen?
June 13, 2010 @ 5:26 pm
> I use boost-1.42 and also have this Problem with Lunar Lander 0.6.0 with boost-1.41.
That’s strange. Just to make sure everything has been regenerated properly after applying the patch, can you try:
make distclean
autoconf
automake -a
./configure
make
And see if the problem persists?
June 13, 2010 @ 5:49 pm
After patch I use all command twice but
./configure
…
checking for boostlib >= 1.33… yes
checking whether the Boost::Filesystem library is available… yes
checking for exit in -lboost_filesystem-1_35… yes
./configure: line 7526: AX_BOOST_SYSTEM: command not found
This is the Problem.
June 13, 2010 @ 6:08 pm
> ./configure: line 7526: AX_BOOST_SYSTEM: command not found
>
Try running this:
aclocal -I m4
And then autoconf, automake, etc.
June 13, 2010 @ 6:13 pm
I have made decompress into new direktory
patch -p1 configure.ac = 1.33… yes
checking whether the Boost::Filesystem library is available… yes
checking for exit in -lboost_filesystem-1_35… yes
./configure: line 7526: AX_BOOST_SYSTEM: command not found
make
Main.o: In function `__static_initialization_and_destruction_0′:
/usr/include/boost/system/error_code.hpp:209: undefined reference to `boost::system::get_generic_category()’
/usr/include/boost/system/error_code.hpp:214: undefined reference to `boost::system::get_generic_category()’
/usr/include/boost/system/error_code.hpp:215: undefined reference to `boost::system::get_generic_category()’
HighScores.o: In function `__static_initialization_and_destruction_0′:
/usr/include/boost/system/error_code.hpp:209: undefined reference to `boost::system::get_generic_category()’
/usr/include/boost/system/error_code.hpp:214: undefined reference to `boost::system::get_generic_category()’
HighScores.o:/usr/include/boost/system/error_code.hpp:215: more undefined references to `boost::system::get_generic_category()’ follow
collect2: ld returned 1 exit status
Very strange :o((((
June 13, 2010 @ 6:27 pm
This not helps :o(((
June 13, 2010 @ 6:36 pm
[…] ship on one of the landing pads. The levels are randomly generated and become progressively harder. Visit the website Share and […]
October 18, 2010 @ 3:12 pm
[…] Lunar Lander 转载请注明出处:麦麦的不老阁 » 《周末 Kill Time 系列:Lunar Lander》本文地址:http://www.linuxhobby.com/archives/3421订阅博客地址:http://www.uncle.ws/subscribe/ […]
November 29, 2010 @ 4:24 am