From 2e114bc0ee97fe40db21514117a9baefdf1b56c6 Mon Sep 17 00:00:00 2001 From: s450026 Date: Tue, 26 May 2020 15:02:34 +0200 Subject: [PATCH] Improving model, fix plate prediction --- main.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index f79ff24..cfe64b5 100644 --- a/main.py +++ b/main.py @@ -21,7 +21,9 @@ if __name__ == "__main__": goal = None path = '' + # Maksymilian go = 0 + rand = 0 while True: for event in pygame.event.get(): @@ -49,13 +51,12 @@ if __name__ == "__main__": if event.key == pygame.K_m: tabPos = [[1, 2], [1, 5], [1, 8], [5, 4], [5, 8], [8, 2], [8, 5], [8, 8], [12, 3], [12, 7]] - rand = randrange(8) if not [waiter.X, waiter.Y] in tabPos or go == 0: if [waiter.X, waiter.Y] in tabPos: model = 'waiter_' + waiter.direction graphics.clear(waiter.X, waiter.Y - 1) - # save_dataset() + rand = randrange(9) x = tabPos[rand][0] y = tabPos[rand][1]