Skip to content

u-damien/conway_GoL

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

9 Commits
ย 
ย 
ย 
ย 

Repository files navigation

Conway's Game of Life

A Python implementation of the famous Conway's Game of Life, built with Pygame.


๐Ÿ“œ Rules of the Game

Rules-of-Conways-Game-of-Life

๐Ÿš€ Getting Started

1. Install dependencies

Make sure you have Python installed, then install pygame:

pip install pygame
# or
python3 -m pip install pygame

2. Run the program

python main.py

๐ŸŽฎ Controls

  • Left Click โ†’ Draw cells
  • Right Click โ†’ Erase cells
  • Space โ†’ Start / Stop simulation
  • i โ†’ Step-by-step mode (advance one generation)
  • r โ†’ Reset screen and stop simulation

โš™๏ธ Configuration

You can adjust the cell size in the code (line 9 of main.py):

CELL_SIZE = 10
  • A higher number โ†’ larger cells (fewer cells on screen).
  • A lower number โ†’ smaller cells (more cells on screen).

๐Ÿ“Œ Notes

  • Optimized to only compute neighbors of black cells โ†’ better performance on large grids.
  • Lightweight and easy to modify for experimentation.

About

The famous Conway's Game of Life

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages