Terraflow is a basic weather simulation built with Bevy. The idea of the game is to control the weather to terraform different planets.
The world is procedurally generated by placing random volcano points across a hex grid. Elevation is incremented around these volcano points in a pseudorandom manner until a max elevation is reached. Any tiles remaining below the ocean level are made to be an ocean tile. Temperature attributes are then given to tiles according to their latitude and altitude. From these attributes, tiles are given a tile type.
There are currently the following tile types:
- Ocean
- Water
- Mountain
- Grass
- Hills
- Desert
- Dirt
- Rocky
- Forest
- Ice
- Jungle
- Swamp
- Waste
Every turn, there is a basic weather system that will change the current humidity and groundwater levels of each tile. If the tile has a higher temperature, it will experience more evaporation, which adds to the humidity of the tile. If there are lower elevation tiles around the tile, then some groundwater will overflow to the lower tiles. Humidity travels to neighbors that are higher in altitude until it reaches mountain tiles where it falls and becomes groundwater. If humidity/temperature/water levels change too much, the tile type will morph into a different tile.
There isn't much of a game, just a simulation of the weather patterns and how they affect the terrain. You can watch the weather change the tile types by pressing spacebar
to move 1 epoch forward or enter
to move 10 epochs.
- Install Rust for your operating system.
- Install Bevy dependencies.
- Run the project
cargo run