add tiles with more cost
This commit is contained in:
parent
94e2175859
commit
b6879f3c77
14
main.py
14
main.py
@ -193,11 +193,25 @@ def kuchnia(x, y):
|
||||
def menu(x, y):
|
||||
screen.blit(menuImg, (x * blockSize, y * blockSize))
|
||||
|
||||
kosztKosztownejPlytki = 5
|
||||
|
||||
def kosztownaPlytka(x, y):
|
||||
if x > 60*4 and x < 60*7 and y < 60*9:
|
||||
return True
|
||||
if x > 60*13 and x < 60*16 and y > 60*5:
|
||||
return True
|
||||
if x > 60*20 and y < 60*9 and y > 60*3:
|
||||
return True
|
||||
return False
|
||||
|
||||
def wypiszOkno():
|
||||
screen.fill((0, 0, 0))
|
||||
for x in range(0, width, blockSize):
|
||||
for y in range(0, height, blockSize):
|
||||
rect = pygame.Rect(x, y, blockSize, blockSize)
|
||||
if kosztownaPlytka(x, y):
|
||||
pygame.draw.rect(screen, (200, 0, 0), rect, 1)
|
||||
else:
|
||||
pygame.draw.rect(screen, (200, 200, 200), rect, 1) #-------------Wypisz kratę -TA
|
||||
|
||||
run = True
|
||||
|
Loading…
Reference in New Issue
Block a user