From dc16ca8c5d55a8fc9fbad998c200b19d71a6ddfa Mon Sep 17 00:00:00 2001 From: csd4ni3l Date: Tue, 24 Jun 2025 13:25:36 +0200 Subject: [PATCH] Remove copying cell grid to improve performance --- game/play.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/game/play.py b/game/play.py index 80a3955..a0acf28 100644 --- a/game/play.py +++ b/game/play.py @@ -110,7 +110,7 @@ class Game(arcade.gui.UIView): self.pypresence_generation_count = 0 self.pypresence_client.update(state='In Game', details=f'Generation: {self.generation} Population: {self.population}', start=self.pypresence_client.start_time) - old_grid = self.cell_grid.copy() + old_grid = self.cell_grid self.cell_grid = update_generation(self.cell_grid) changed_rows, changed_cols = np.where(old_grid != self.cell_grid)