|
@ -200,7 +200,7 @@ func generate_world() -> void: |
|
|
cell_states.append([]) |
|
|
cell_states.append([]) |
|
|
cell_states[x].resize(world_size.x) |
|
|
cell_states[x].resize(world_size.x) |
|
|
for y in range(world_size.y): |
|
|
for y in range(world_size.y): |
|
|
var is_alive: int = randi_range(0, 1) |
|
|
|
|
|
|
|
|
var is_alive: int = randi_range(CellStates.DEAD, CellStates.ALIVE) |
|
|
total_living += is_alive |
|
|
total_living += is_alive |
|
|
cell_states[x][y] = is_alive |
|
|
cell_states[x][y] = is_alive |
|
|
cell_ids[x][y] = create_cell(Vector2(x, y), bool(is_alive)) |
|
|
cell_ids[x][y] = create_cell(Vector2(x, y), bool(is_alive)) |
|
|