Skip to content

Growing biomes with Perlin Noise and Cellular Automata.

Notifications You must be signed in to change notification settings

duncangrubbs/biome-evolution

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Biome Evolution

Growing biomes with Perlin Noise and Cellular Automata.

💻 Implementation

My implementation works in the following way. First, it creates a 500x500 2D array. Next, it populates the arraywithautomatacells that justcontain an elevationin their state. Then, a number(by default 1500)of random pixels are assigned the mountain (snow) biome based purely on their elevation(i.e. if their elevation is greater than 180). At this point, there is enough information in the map to start updating cells based on the automatarules. The biome(cell)that has the most complex update rulesand starts growing firstis RIVER. In one update iteration, each cell is updated based on the states of the cells in its Moore neighborhood. The most common update rule checks if there is a neighboring cell with a biome defined and the elevation. If the biome is compatible, the cell takes on that biome. When drawn, the color of each pixel on the map visualizes itscell’s biomewhich could beLAKE, RIVER, MOUNTAIN, FOREST, orPLAIN.MOUNTAIN(snow) is white, FORESTis a brown, PLAINis green, and RIVERand LAKEare blue. The colors are also adjusted according to the cell’s elevation so that lower elevations are darkened, and higher elevations are brightened.

🔨 How to Build

  • cd src
  • javac *.java
  • java Main

About

Growing biomes with Perlin Noise and Cellular Automata.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages