feat(tractor): update water level and add replenish functionality

This commit is contained in:
Wojciech Kubicki 2024-03-25 12:35:03 +01:00
parent e4aa771022
commit 2658f77669
1 changed files with 5 additions and 1 deletions

View File

@ -16,7 +16,8 @@ class Tractor(pygame.sprite.Sprite):
x, y = 0, 0
self.rect.topleft = (x, y)
self.water = 200
self.water = 50
def draw(self, surface):
surface.blit(self.image, self.rect)
@ -54,6 +55,9 @@ class Tractor(pygame.sprite.Sprite):
self.move('up')
if keys[pygame.K_DOWN]:
self.move('down')
if keys[pygame.K_r]:
self.water = 50
print(f"💧 replenished water level: {self.water} litres\n")
def print_tile_type(self):