Saturday, October 25, 2014

Experiments with Procedural Generation, Part 2

Conway's Game of Life

Tools: LUA, Love2D, ZeroBrane Studio

A friend of mine from college introduced me to the Game of Life when he built his own for class. Ever since then I've been interested in the subject and I've always wanted to write my own version of it. Since I was planning on learning about Cellular Automata this month, I figured the Game of Life would be a great starting point.



The rules of the Game of Life are:
- Any living cell that has fewer than 2 neighbors dies.
- Any living cell that has more than 3 neighbors dies.
- Any living cell that has 2-3 neighbors lives on.
- Any dead cell that has exactly 3 neighbors becomes alive.

These simple rules working together can create some extremely complex and seemingly-intelligent behavior, which is what makes the Game of Life so fascinating.

My implementation of it has pause/unpause, fast forward, stepping forward, and a series of brushes that should make it a little easier to create complex patterns.

Download the project here.

Controls:
Left Mouse Button - Place cell(s).
Right Mouse Button - Delete cell(s).
Space - Pause/unpause the simulation.
Enter - Fast forward when unpaused. When paused, step forward one tick.
Backspace - Clear the entire grid.
Mouse Wheel - Scroll through the brushes.
#1-6 - Select a specific brush.

No comments:

Post a Comment