Inny's Game Of Life

Show off your games, demos and other (playable) creations.
Post Reply
User avatar
Inny
Party member
Posts: 652
Joined: Fri Jan 30, 2009 3:41 am
Location: New York

Inny's Game Of Life

Post by Inny »

I wrote a Conway's Game Of Life simulator just for my own experimentation, but then decided to turn it into an educational tool. I took it from a hundred line file to a 533 extensively commented file. If any of you guys have siblings, significant others, children, or anyone else that wants to learn some Lua and Love, then please walk through the source code with them. I'm going to put my own girlfriend through this, and I do want to take into account whatever feedback I get towards revisions. Thanks in advance for any comments.

Plus, it's Conway's Game Of Life, these are always fun to toy around with. :D

Note: I *believe* my implementation is correct. Gliders and stuff are working as expected. If I botched something, then please tell me. Also, I have the world wrap at the edges, rather than end. I like it better when spaceships wrap around and demonstrate that they're going to live forever.
Attachments
innysgameoflife.love
Version 1
(8.13 KiB) Downloaded 209 times
User avatar
vitaminx
Citizen
Posts: 95
Joined: Fri Oct 19, 2012 7:16 am
Location: international
Contact:

Re: Inny's Game Of Life

Post by vitaminx »

Your comments in the source are super useful, I've already learned about first class funcions from it :D
Germanunkol
Party member
Posts: 712
Joined: Fri Jun 22, 2012 4:54 pm
Contact:

Re: Inny's Game Of Life

Post by Germanunkol »

The "glider" and "toad" are nice :D

It's interesting how large populations (pressing 8 or 9) usually die off instantly...
trAInsported - Write AI to control your trains
Bandana (Dev blog) - Platformer featuring an awesome little ninja by Micha and me
GridCars - Our jam entry for LD31
Germanunkol.de
User avatar
xXxMoNkEyMaNxXx
Party member
Posts: 206
Joined: Thu Jan 10, 2013 6:16 am
Location: Canada

Re: Inny's Game Of Life

Post by xXxMoNkEyMaNxXx »

You need a 'Tick once' feature!

I can't help mentioning my implementation with pixel shaders and without educational documentation, which runs ridiculously fast because it's on the GPU:
GOL2.love
https://love2d.org/forums/viewtopic.php?f=5&t=15781
(50.11 KiB) Downloaded 120 times
Yours is definitely more visually pleasing, but it feels like it's lagging after playing with mine for a while :rofl:
User avatar
Username
Citizen
Posts: 54
Joined: Mon Jan 28, 2013 1:25 pm

Re: Inny's Game Of Life

Post by Username »

Germanunkol wrote:The "glider" and "toad" are nice :D

It's interesting how large populations (pressing 8 or 9) usually die off instantly...

Do this:

Pause game.
Clear game
Draw a straight line of 10 cells.
Enjoy.
User avatar
Inny
Party member
Posts: 652
Joined: Fri Jan 30, 2009 3:41 am
Location: New York

Re: Inny's Game Of Life

Post by Inny »

vitaminx wrote:Your comments in the source are super useful, I've already learned about first class funcions from it :D
Mission accomplished then. :P I'm glad I could help.
xXxMoNkEyMaNxXx wrote:You need a 'Tick once' feature!
I'm half stunned that I didn't think to add this. Also, GLSL game of life is brilliant.
Germanunkol wrote:It's interesting how large populations (pressing 8 or 9) usually die off instantly...
You should see how overcrowded New York City's subway system is, for comparison. :D
Post Reply

Who is online

Users browsing this forum: No registered users and 64 guests