From d016fdb292f5307aac6ebb9ffda75bfe3be6099c Mon Sep 17 00:00:00 2001 From: James Gray Date: Sat, 21 Feb 2015 15:50:59 -0800 Subject: [PATCH] fix stuff --- app/main.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/main.py b/app/main.py index cecc95d5c..2a0579526 100644 --- a/app/main.py +++ b/app/main.py @@ -92,11 +92,11 @@ def get_possible_directions(nagini, board): for direction in look_ahead1: if direction == UP: - look_aheadUP = look_ahead(head_x, head_y+1, board) + look_aheadUP = look_ahead(head_x, head_y-1, board) if len(look_aheadUP) > 0: directions.append(UP) elif direction == DOWN: - look_aheadDOWN = look_ahead(head_x, head_y-1, board) + look_aheadDOWN = look_ahead(head_x, head_y+1, board) if len(look_aheadDOWN) > 0: directions.append(DOWN) elif direction == LEFT: @@ -104,7 +104,7 @@ def get_possible_directions(nagini, board): if len(look_aheadLEFT) > 0: directions.append(LEFT) elif direction == RIGHT: - look_aheadRIGHT = look_ahead(head_x+1, head_y+1, board) + look_aheadRIGHT = look_ahead(head_x+1, head_y, board) if len(look_aheadRIGHT) > 0: directions.append(RIGHT)