From cf19b39b4fbc4ae5fd134cfe6c76f7718cc3097f Mon Sep 17 00:00:00 2001 From: Sam Moore Date: Tue, 20 Dec 2011 12:20:36 +0800 Subject: [PATCH] Whoops Read the diff Also, forgot to mention progress in simulate.py in last commit. Made progress with total.html results file, and round by round results files. Although since the round number is never updated properly, we only ever get "round1.html", overwritten each round. --- progcomp/agents/basic_python/basic_python.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/progcomp/agents/basic_python/basic_python.py b/progcomp/agents/basic_python/basic_python.py index 849c6f7..9b427c7 100755 --- a/progcomp/agents/basic_python/basic_python.py +++ b/progcomp/agents/basic_python/basic_python.py @@ -31,13 +31,13 @@ def is_integer(s): def move(x, y, direction, multiplier): """ Moves point (x,y) in direction, returns a pair """ if direction == "UP": - return (x,y-1) + return (x,y-multiplier) elif direction == "DOWN": - return (x,y+1) + return (x,y+multiplier) elif direction == "LEFT": - return (x-1, y) + return (x-multiplier, y) elif direction == "RIGHT": - return (x+1, y) + return (x+multiplier, y) return (x,y) -- 2.20.1