2022-04-23 19:14:23 +02:00
|
|
|
import pygame as pg
|
2022-05-10 01:05:34 +02:00
|
|
|
from enum import Enum
|
2022-05-13 08:31:40 +02:00
|
|
|
from random import randrange
|
2022-05-10 01:05:34 +02:00
|
|
|
from map.tile import Tile
|
|
|
|
class Trashbin(Tile):
|
2022-05-13 08:31:40 +02:00
|
|
|
def __init__(self, img, x, y, width, height, waste_type):
|
2022-05-10 01:05:34 +02:00
|
|
|
super().__init__(img, x, y, width, height)
|
2022-05-13 08:31:40 +02:00
|
|
|
# dis_dump dis_trash mass space trash_mass trash_space
|
|
|
|
self.x = x
|
|
|
|
self.y = y
|
2022-05-10 01:05:34 +02:00
|
|
|
|
2022-05-13 08:31:40 +02:00
|
|
|
self.season = randrange(4)
|
|
|
|
self.trash_type = randrange(5)
|
|
|
|
self.mass = randrange(5)
|
|
|
|
self.space = randrange(5)
|
2022-05-13 12:47:08 +02:00
|
|
|
self.trash_mass = randrange(5)
|
2022-05-13 08:31:40 +02:00
|
|
|
|
|
|
|
|
|
|
|
def get_coords(self):
|
|
|
|
return (self.x, self.y)
|
|
|
|
|
|
|
|
def get_attributes(self):
|
|
|
|
return (self.season, self.trash_type, self.mass, self.space, self.trash_mass)
|