https://github.com/bamless/raylib-gravity
https://github.com/bamless/raylib-gravity
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/bamless/raylib-gravity
- Owner: bamless
- License: mit
- Created: 2025-03-16T18:34:47.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2025-04-22T18:13:39.000Z (about 1 year ago)
- Last Synced: 2025-06-04T16:06:04.424Z (about 1 year ago)
- Language: C
- Size: 28.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# raylib-gravity
Simple 2D gravity simulation built for learning raylib.
## Details
The simulation in itself is pretty simple, using velocity Verlet to integrate the bodies and
Newton's law of universal gravitation to calculate forces between them.
Click and drag with your mouse to spawn new bodies. The initial path of the body will be shown as
a blue path.
May add some graphical effects in the future for testing shaders with raylib.
## Compilation
```bash
mkdir build
cd build
cmake ..
make -j
```
then run `build/src/raylib-gravity`.