This commit is contained in:
michalStarski 2019-03-19 18:40:36 +01:00
parent 219f523dac
commit 3347e7cf68
2 changed files with 5 additions and 12 deletions

View File

@ -35,13 +35,6 @@ for x in range(PLAY_HEIGHT//64):
grass = Grass(x,y)
cells[x].append(grass)
for x in range(PLAY_HEIGHT//64):
cells.append([])
for y in range(PLAY_HEIGHT//64):
grass = Grass(x,y)
cells[x].append(grass)
print( cells )
#Losowanie domków i dodawanie je do mapy
home_len = home_amount
while( home_len > 0 ):
@ -51,6 +44,7 @@ while( home_len > 0 ):
y = random.randint(0, (PLAY_WIDTH//64)-1)
if( type(cells[x][y]) == Grass ):
print('Moge byc domkiem!')
cells[x][y] = House(x,y, 10, 10, 10)
home_len = home_len - 1

View File

@ -33,4 +33,3 @@ class House(Cell):
def check_rubbish_status(self):
print( "plastic: " + str(self.rubbish[PLASTIC]) + " glass: " + str(self.rubbish[GLASS]) + " metal: " + str(self.rubbish[METAL]) )