https://github.com/programmingrainbow/asteroids-c-sdl2
Asteroids! written in C and using SDL2 game library.
https://github.com/programmingrainbow/asteroids-c-sdl2
Last synced: 3 months ago
JSON representation
Asteroids! written in C and using SDL2 game library.
- Host: GitHub
- URL: https://github.com/programmingrainbow/asteroids-c-sdl2
- Owner: ProgrammingRainbow
- Created: 2025-06-17T02:29:36.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2025-06-17T02:36:52.000Z (7 months ago)
- Last Synced: 2025-09-12T19:33:19.764Z (5 months ago)
- Language: C
- Size: 1.5 MB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README

# Asteroids!
Earn points by shooting all the Asteroids, But don't get hit. Points start out at 100 * level, but are reduced with each shot.
# Build
To build the Asteroids binary you will need all build tools needed to compile via Makefile and gcc. You will also need SDL2, SDL2_image, SDL2_mixer and SDL2_ttf both the libraries and headerfiles.
## ArchLinux instructions.
sudo pacman -S --needed base-devel
sudo pacman -S --needed sdl2 sdl2_image sdl2_mixer sdl2_ttf
make release run
The Makefile also supports these commands:
```
make rebuild
make clean
make release
make debug
SRC_DIR=Video8 make rebuild run
CC=clang make clean release run
```
# Controls
Up Arrow - Fires the main engines.\
Right Arrow - Rotates Clockwise.\
Left Arrow - Rotates Anticlockwise.\
Space Bar - Fires the main gun.\
Escape - Quits and closes game.\
W - Toggles Fullscreen.\
M - Toggles Music.\
F - Toggle FPS Display.