ATAR Notes: Forum

General Discussion => Coding Corner => Topic started by: Chessnutter on January 11, 2021, 11:19:57 am

Title: PROJECT: Conway's Game of Life
Post by: Chessnutter on January 11, 2021, 11:19:57 am
Made Conway's Game of Life in Python using Pygame.

If you haven't heard of it before, it is a simulation which is as powerful as a computer (Turing Complete). This means it can run anything a computer can run. It is composed of an infinitely large 2D grid of cells in one of 2 states, dead or alive. A dead cell becomes alive if and only if 3 neighbours are alive, and an alive cell stays alive if and only if 2 or 3 of its neighbours are alive.

Here is an example of what it can do: https://www.youtube.com/watch?v=C2vgICfQawE

Known bugs: Zooming is half broken, everything from the centre cell expands outwards. Spent too much time trying to fix to keep working on it and from a first glance it appears like it works.

This is my first time using Pygame and turning a script to an exe - the logic took a few hours but everything else took several days  :(

Source code and exe in Google Drive:
https://drive.google.com/drive/folders/1S7DQPBJVrZvFV0hqU1WZ1sQ_c8DZHE_f?usp=sharing