refactor #26

Merged
s481834 merged 34 commits from refactor into master 2024-06-04 13:25:11 +02:00
Showing only changes of commit 9ebac46bef - Show all commits

View File

@ -173,10 +173,12 @@ class Tractor:
attributes=self.get_attributes()
decision = drzewo.makeDecision(attributes)
self.pretty_print_tree([str("({:02d}, {:02d})").format(self.slot.x_axis, self.slot.y_axis),decision,*self.get_attributes_for_print()])
if decision == "Podlewac":
if decision == "Tak":
self.slot.irrigatePlant()
counter += 1
condition.cycle()
pygame.time.delay(50)
self.waterLevel=random.randint(0,100)
#condition.getCondition()
self.move_forward(pole, False)
if i % 2 == 0 and i != dCon.NUM_Y - 1:
@ -187,7 +189,6 @@ class Tractor:
self.turn_left()
self.move_forward(pole, False)
self.turn_left()
pygame.time.delay(50)
print("podlanych slotów: ", str(counter))
def snake_move(self,pole,x,y):