From bfbfe9bb43a5d1a70213832304b6332376eb2ad3 Mon Sep 17 00:00:00 2001 From: Dominik Roth Date: Mon, 22 Aug 2022 18:17:59 +0200 Subject: [PATCH] Fixed: Crash when drawing StateObservable with speed --- columbus/observables.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/columbus/observables.py b/columbus/observables.py index 6189ce2..53ec1ee 100644 --- a/columbus/observables.py +++ b/columbus/observables.py @@ -256,7 +256,7 @@ class StateObservable(Observable): (0, self.env.height/2), 3, width=0) pygame.draw.circle(self.env.screen, self.env.agent.col, (self.env.width/2, 0), 3, width=0) - for i in range(int(len(self.obs)/2)): + for i in range(int(len(self.obs)/2) - self.speedAgent): x, y = self.obs[i*2], self.obs[i*2+1] col = self.entities[i].col pygame.draw.circle(self.env.screen, col,