diff --git a/squirrelbattle/interfaces.py b/squirrelbattle/interfaces.py index bf8ddbe..330301c 100644 --- a/squirrelbattle/interfaces.py +++ b/squirrelbattle/interfaces.py @@ -197,9 +197,11 @@ class Map: def is_visible_from(self, starty: int, startx: int, desty: int, destx: int, max_range: int) -> bool: oldvisibility = deepcopy(self.visibility) + oldseen = deepcopy(self.seen_tiles) self.compute_visibility(starty, startx, max_range) result = self.visibility[desty][destx] self.visibility = oldvisibility + self.seen_tiles = oldseen return result def compute_visibility(self, y: int, x: int, max_range: int) -> None: