Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/0x7o/game_of_life
Implementation of the iconic game on Rust
https://github.com/0x7o/game_of_life
bevy game gameoflife rust
Last synced: 19 days ago
JSON representation
Implementation of the iconic game on Rust
- Host: GitHub
- URL: https://github.com/0x7o/game_of_life
- Owner: 0x7o
- License: mit
- Created: 2024-04-30T10:06:53.000Z (9 months ago)
- Default Branch: master
- Last Pushed: 2024-05-04T05:19:11.000Z (8 months ago)
- Last Synced: 2024-10-29T21:01:46.137Z (2 months ago)
- Topics: bevy, game, gameoflife, rust
- Language: Rust
- Homepage:
- Size: 61.5 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
![Cover](image.png)
# Game of Life
A simple implementation of the Game of Life on Rust. Used `bevy` as a game engine.## Run
To run the game, you need to install Rust and run the following command (it will take some time the first time):
```bash
$ git clone https://github.com/0x7o/game_of_life
$ cd game_of_life
$ cargo run --release
```## Control
- `Left mouse button` - add a cell
- `Right mouse button` - delete a cell
- `P or Enter or Space` - start/stop simulation
- `E` - clear all cells## Customization
If you want to customize the game to suit you, just edit the `src/main.rs` file:
```rust
/// Field refresh rate in seconds
const REFRESH_RATE: f32 = 0.05;
const CELL_SIZE: f32 = 18.0;
// Height and width of the window
const WIDTH: f32 = CELL_SIZE * 80.0;
const HEIGHT: f32 = CELL_SIZE * 45.0;
```