
Conway's Game of Life
by plyingfig
Description
If too laggy on your PC, you can instead run on turbowarp: https://turbowarp.org/504922751 https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life This project started as me explaining to my kids what Conway's Game of Life is. I then thought that it would be a good idea to "finish" it and share it. So I added the instructions, and improved the editor, and added ability to import/export grids, and provided pre-defined patterns, and ... etc. I was litterally assailed by a gang of feeping creatures! All scratch code is by me. This project wasn't properly planned, and the resulting code is a bit messy... The simulation engine is pretty-much a straight implementation of the algorithm, without much optimisation. Those interested in better ways of implementing it should check out HashLife, which uses hashing and quad trees to speed the simulation up (it is quite cool!). Description of the methodology can be found here: https://github.com/mafm/HashLife The style of the instructions are very much inspired by the tutorials from @papipupepappa . Thx to @helloitsme23496 for beta-testing.
Instructions
โบ Hit the green flag. Then click or press any key to get to the main menu. โบ Listen/watch the ยซInstructionsยป [I] if you don't know what Conway's Game of Life is. โบ ยซDraw & Simulateยป [D] to explore the Game of Life. Draw/erase cells on the grid with the pencil/eraser, and let the cells evolve, step by step or in automatic mode. (More details below.) โบ If you lack inspiration, just ยซSimulate a Random Soupยป [S]. โโ Keyboard short-cuts โโโโโโโโโโโโโโโโโ [Space] displays/hides command buttons. [M] returns to the main menu. โบ Drawing [D] selects the pencil. [S]/{Play button} starts the simulation. [C]/{Clear button} clears the grid. [R]/{Reset button} resets the grid to its state at the start of the last simulation. [E] selects the eraser. [L]/{Pattern button} lets you select and load a pre-defined pattern (see below). {Import button} imports a saved grid. {Export button} exports the current grid. [Right arrow]/{Forward button} evolves the grid by one generation. [1], [2], [3], [4]/{Resol. button} changes the resolution of the grid, from high resolution (80x60) to low resolution (40x30). High resolution is slower and requires more CPU. Changing the resolution clears the grid. โบ Simulation [D]/{Stop button} stops the simulation and enters drawing mode. [P]/{Pause/Play button} pauses/resumes the simulation. [Right arrow]/{Forward button} evolves the grid by one generation (while simulation is paused). โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โโ Predefined patterns โโโโโโโโโโโโโโโโโโ You can look at some interesting patterns via the Pattern command. โบ Still life: pattern that is stable (it doesn't change). โบ Oscillator: pattern that repeats itself in a stationary way. โบ Spaceship: pattern that "moves"; it repeats itself, like an oscillator, but after a translation. โบ Gun: pattern that repeats itself after spawning a spaceship pattern (e.g. glider gun). โบ Methuselah: pattern that evolves for a LONG time before stabilizing or dying (the highest resolution grid is in fact too small to see the full evolution, but it nevertheless gives an idea). โบ Puffer: pattern that moves like a spaceship, but leaves debris behind. โบ Fuse: a sequence of stable/oscillator patterns that are "burnt" by a moving pattern. โบ Eater: stable pattern that is able to destroy another pattern, while restoring itself to its initial state. โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ The grid is a cylinder (kind of). Left and right sides are connected, but offset by one line. This is because I went for a basic implementation of the grid... โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ Share your cool patterns in the comments, by using the Export command (paste the export code in a comment). โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ #game #gameoflife #simulation
Project Details
- Visibility
- Visible
- Comments
- Enabled
More Cool Projects

Add a button to beat up Nano! 2
by gulkd2023

beat up dora (remastered)
by pbskidz489

Czech Lore in @bren319's style (W.I.P.)
by SillyGooseReturns

Beat up Lisa gaming roblox!
by newmyles

Beat up Sonic (1) 4remixs at once remix
by kubakoodziejczak

30 minute Timer
by SublightUp25

ใขใณใใผใใผใซใใฟใใผๆฆGใซใผใใใขใณใใผใใผใซรในใใใฉ
by ninnjinsirisiri

Beat up nano with so many buttons but better
by UnderratedMegaStar21

Beat Up K (CAL)
by themacs3cats

BarryFans + The Barrel Squad Band
by juanfrilla

Add buttons in beat up chrisrocks2021 remix remix remix remix
by bucket8

้ณใฒใผใๆฅตใๅใ
by norumaku

ScratchNite
by OG_RaidersFn

Beat Up Edward (NEW BUTTONS!)
by CharlesP_CodeCentral

Numberblock Piratasthophe but it goes to 30 (2nd most popular project)
by NumberblocksFan08

My First Vyond Effects Kit V2
by Lateone12

Car Anatomyโข Ford mustang
by meble2115

[BETA 0.1] ะะะ ะะะะะ ะฏะฉะะ ะกะะ ะะขะง ะะะข
by Serik22022010

Beat up mr bean Remastered Edition
by imnotaxiibuss123

talking tom and ben news 4 remix
by nononotomhorojfgdnn9

Ochocientos Ochenta y Ocho
by Greenlad2750

ใๅฎ้ณ่ปๅ ๆพ้ไปใใๅคง้ช็ฐ็ถ็ท้่ปขใทใฅใใฌใผใฟใผ
by kopitarou

Beat Up Edward Remastered remix
by ERFAN_AKHLAQI

BFDI Mini Resort Characters (Vector Look) (with assets)
by takumatakuma