I respect that you're trying to make a pathfinder bot, but I looked at Decksource and what you did made it so the bot didn't move until it saw the goal. (In playing the deck it just moved randomly.) I recommendearning a real coding language like Lua.