A faithful C++/SDL port of Lander (Acorn Archimedes, 1987) by David Braben.
This demo was a precursor to the game Zarch (1987) and later Virus (1988) for the Amiga.
- Full 3D landscape with Fourier-synthesized terrain
- Physics-based ship controls with thrust, gravity, and friction
- Destructible objects (trees, buildings, rockets)
- Particle effects (exhaust, bullets, explosions, smoke, splashes)
- Falling rocks hazard (score >= 800)
- Star particles at high altitude
- Sound effects with spatial audio
- Smooth edge clipping (Sutherland-Hodgman)
- Multiple display resolutions and frame rates
- Persistent settings
- CMake 3.16+
- C++17 compiler
- SDL2
macOS (Homebrew):
brew install sdl2Ubuntu/Debian:
sudo apt install libsdl2-devWindows (vcpkg):
vcpkg install sdl2mkdir build
cd build
cmake ..
make./lander| Input | Action |
|---|---|
| Mouse movement | Ship orientation (pitch and yaw) |
| Left mouse button | Full thrust |
| Middle mouse button | Hover thrust |
| Right mouse button | Fire bullets |
| Key | Action |
|---|---|
| Escape | Exit game |
| P | Pause / Unpause |
| Tab | Toggle debug overlay |
| F11 or Alt+Enter | Toggle fullscreen |
| D | Toggle debug mode (keyboard flight) |
When debug mode is enabled, use arrow keys to fly:
- Arrow keys: Move horizontally
- A/Z: Move vertically
| Key | Setting | Options |
|---|---|---|
| 1 | Landscape scale | 1x (12x10), 2x (24x20), 4x (48x40), 8x (96x80) |
| 2 | Frame rate | 15, 30, 60, 120 FPS |
| 3 | Display resolution | 320x256, 640x512, 1280x1024 |
| 4 | Smooth edge clipping | On / Off |
| 5 | Sound effects | On / Off |
| 6 | Star particles | On / Off |
Settings are automatically saved to settings.cfg.
- Take off from the launchpad and explore the landscape
- Shoot objects (trees, buildings, rockets) to score points
- Land gently on the launchpad to refuel
- Avoid crashing into terrain or objects
- At score >= 800, falling rocks begin to appear
- Fuel is limited - manage your thrust carefully
- Game over when all lives are lost
Shows current settings across the bottom of the screen:
12x10 60/58 1280x1024 CLIP SFX STAR
- Landscape tiles
- Target FPS / Actual FPS
- Display resolution
- Clipping (CLIP = on, clip = off)
- Sound (SFX = on, sfx = off)
- Stars (STAR = on, star = off)
lander/
├── src/ # Source files
├── test/ # Test files
├── sounds/ # Sound effect WAV files
├── docs/ # Design documents (TASKS.md, PROGRESS.md, ...)
├── scripts/ # Build and release scripts
├── macos/ # App bundle Info.plist
├── windows/ # Version resource for lander.exe
├── tools/ # Icon generator
├── CMakeLists.txt # Project version lives here
└── README.md
ctest --output-on-failureThe version comes from project(lander VERSION ...) in CMakeLists.txt; the
release scripts stamp it into the app bundle and lander.exe.
Self-contained builds: releases build SDL2 from source and link it
statically (-DLANDER_VENDOR_SDL2=ON), so players need nothing installed. On
Windows that is a single lander.exe with the C runtime linked in too; on
macOS a universal (Apple Silicon and Intel) app for macOS 11 or later.
Everyday builds can use an installed SDL2, such as Homebrew's.
macOS (scripts/build_release.sh): builds dist/Lander.app self-contained
and universal, checks it links only system libraries, signs it with the
Developer ID certificate (hardened runtime, timestamped), launches it once as a
smoke test, notarises it with the lineage-notary notarytool profile, staples
the ticket and zips it to dist/Lander-macOS.zip. Override with
SIGN_IDENTITY / NOTARY_PROFILE, or use SKIP_NOTARIZE=1 for a quick
signed-only build. Without the certificate it produces an ad-hoc signed
Lander-macOS-unsigned.zip.
Windows (GitHub Actions, .github/workflows/ci.yml): every PR builds,
tests and smoke-tests on Windows and macOS. Pushing a vX.Y.Z tag (matching
the CMake version) also signs lander.exe with SSL.com eSigner, using the
ES_USERNAME, ES_PASSWORD, ES_CREDENTIAL_ID and ES_TOTP_SECRET repository
secrets, and publishes it to the itch.io windows channel with the
BUTLER_API_KEY secret, refusing to publish anything unsigned.
scripts/build_windows.ps1 does the same build and signing on a local
Windows machine (with the ES_* values as environment variables).
To release: bump project(lander VERSION ...), merge to main, tag it
(git tag v1.2.0 && git push origin v1.2.0) for Windows, then run
scripts/build_release.sh on the Mac and push the printed zip to the mac
channel with butler push.
- Original game: David Braben (1987)
- C++/SDL port: This project
This is an educational port of the original Lander demo. The original game is copyright David Braben / Frontier Developments.