add method for rendering can

This commit is contained in:
Pawel Felcyn 2023-04-15 19:37:56 +02:00
parent f937ce349f
commit fa3868746a
1 changed files with 5 additions and 1 deletions

View File

@ -1,5 +1,6 @@
from garbage import Garbage
from typing import List, Tuple
from gameContext import GameContext
class GarbageCan:
position: Tuple[int, int]
@ -13,4 +14,7 @@ class GarbageCan:
self.garbage.append(garbage)
def remove_garbage(self, garbage: Garbage) -> None:
self.garbage.remove(garbage)
self.garbage.remove(garbage)
def render(self, game_context: GameContext) -> None:
game_context.render_in_cell(self.position, "imgs/container.png")