Update 'garbageTruck.py'
This commit is contained in:
parent
298fba3f6d
commit
bfd78aee90
@ -1,12 +1,13 @@
|
|||||||
from typing import List
|
from typing import List
|
||||||
|
|
||||||
class garbageTruck:
|
class GarbageTruck:
|
||||||
position: List[int, int]
|
position: Tuple[int, int]
|
||||||
paper: []
|
paper: []
|
||||||
plastic_and_metal: []
|
plastic_and_metal: []
|
||||||
glass: []
|
glass: []
|
||||||
bio: []
|
bio: []
|
||||||
mixed: []
|
mixed: []
|
||||||
|
RecognizedGarbage: []
|
||||||
truckSpritePath = 'imgs/dust_car.png'
|
truckSpritePath = 'imgs/dust_car.png'
|
||||||
def __init__(self, position: List[int, int]) -> None:
|
def __init__(self, position: List[int, int]) -> None:
|
||||||
self.position = position
|
self.position = position
|
||||||
@ -16,6 +17,7 @@ class garbageTruck:
|
|||||||
self.bio = []
|
self.bio = []
|
||||||
self.mixed = []
|
self.mixed = []
|
||||||
|
|
||||||
|
|
||||||
def sort_garbage(self, RecognizedGarbage) -> None:
|
def sort_garbage(self, RecognizedGarbage) -> None:
|
||||||
if RecognizedGarbage.garbage_type == 0:
|
if RecognizedGarbage.garbage_type == 0:
|
||||||
self.paper.append(RecognizedGarbage)
|
self.paper.append(RecognizedGarbage)
|
||||||
|
Loading…
Reference in New Issue
Block a user