From 6fcd4d7711ed3ec6a44a042b581ab1290113ea61 Mon Sep 17 00:00:00 2001 From: dg <dg@51575b47-30f0-44d4-a5cc-537603b46e54> Date: Mon, 11 Jan 2010 16:15:15 +0000 Subject: [PATCH] run git-svn-id: http://svn.net-core.org/repos/t-engine4@223 51575b47-30f0-44d4-a5cc-537603b46e54 --- game/engine/interface/PlayerRun.lua | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/game/engine/interface/PlayerRun.lua b/game/engine/interface/PlayerRun.lua index fc7d8ec7b2..48c35095d1 100644 --- a/game/engine/interface/PlayerRun.lua +++ b/game/engine/interface/PlayerRun.lua @@ -49,13 +49,11 @@ function _M:runInit(dir) block_left = block_left, block_right = block_right, cnt = 1, --- dialog = Dialog:simplePopup("Resting...", "You are running, press any key to stop.", function() --- self:runStop() --- end), + dialog = Dialog:simplePopup("Running...", "You are running, press any key to stop.", function() + self:runStop() + end), } - print("run", dir, block_left, block_right) - self:runStep() end @@ -107,7 +105,6 @@ function _M:runCheck() if not checkDir(self, self.running.dir) and checkDir(self, self.running.dir, 2) and not checkDir(self, sides[self.running.dir].left) and checkDir(self, sides[self.running.dir].right) then self.running.newdir = turn[self.running.dir].left self.running.ignore_left = 2 - print("will turn left") return true end @@ -115,7 +112,6 @@ function _M:runCheck() if not checkDir(self, self.running.dir) and checkDir(self, self.running.dir, 2) and checkDir(self, sides[self.running.dir].left) and not checkDir(self, sides[self.running.dir].right) then self.running.newdir = turn[self.running.dir].right self.running.ignore_right = 2 - print("will turn right") return true end end @@ -131,7 +127,7 @@ end function _M:runStop(msg) if not self.running then return false end --- game:unregisterDialog(self.running.dialog) + game:unregisterDialog(self.running.dialog) if msg then game.log("Ran for %d turns (stop reason: %s).", self.running.cnt, msg) -- GitLab