sdl2-life

Conway's Game of Life with go-sdl2
git clone https://www.brianlane.com/git/sdl2-life
Log | Files | Refs | README

commit c2818c0e273627c03f3dfb0d72ad972e733d33c8
parent c98b38e8a420835b1f92818357223e99f03639ca
Author: Brian C. Lane <bcl@brianlane.com>
Date:   Mon, 11 Nov 2019 19:27:52 -0800

Fix random seed output at startup/reset

Diffstat:
Mmain.go | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/main.go b/main.go @@ -92,7 +92,7 @@ func (g *LifeGame) cleanup() { func (g *LifeGame) InitializeCells() { if cfg.Seed == 0 { seed := time.Now().UnixNano() - log.Printf("seed = %d\n", cfg.Seed) + log.Printf("seed = %d\n", seed) rand.Seed(seed) } else { log.Printf("seed = %d\n", cfg.Seed)