Click here to play in web browser!
This is my second raylib project, made to learn about the library and basic game development. Like before, there were many features and some bugs that I didn't get to before my self-imposed deadline. But I'm pretty happy with how it turned out.
Runs on Windows, Linux, MacOS, and web browsers.
-
Select/Confirm:
Mouse click/Enter/Space -
Back/Cancel:
Esc/Backspace -
Ship Controls:
- Shoot:
Left click/Space - Thrust:
Right click/W/↑ - Aim:
Move mouse/A/D/←/→
- Shoot:
-
Pause:
P/Esc -
Toggle fullscreen:
Alt+Enter/F11/Shift+F(desktop only)
- Build by running
./build.sh cmakeor.\build.bat cmake, depending on your platform- Alternatively, just run
make, or the build script with no arguments.
- Alternatively, just run
- Play by running
./asteroidsor.\asteroids.exe
- Same as desktop, but add
webas an argument:- Run
build.sh cmake webormake web
- Run
- Play by running
emrun asteroids.html
- Library: raylib, duh :P
- A C compiler: GCC, Clang (llvm-mingw
on Windows), or Visual Studio
- emscripten (only for browser / web assembly compilation)
- Build system: CMake or Make (macOS requires CMake)
For Windows users with no build tools or less experience, w64devkit is a fast and easy way to build this project. Just download and extract it anywhere. Then use the included unix-like terminal, or add the w64devkit/bin tools to your PATH. Now you can simply make this project like you would on Linux. As an added bonus, you now have access to many nice Unix command line tools.