aboutsummaryrefslogtreecommitdiff
path: root/engines/fullpipe/fullpipe.cpp
diff options
context:
space:
mode:
authorEugene Sandulenko2013-07-25 15:43:10 +0300
committerEugene Sandulenko2013-09-06 14:51:05 +0300
commitaaf5bae026416e158d69633eb1b07c73a63fcccd (patch)
tree85b3142f8841c0502c11420363e1e379a5ba8a35 /engines/fullpipe/fullpipe.cpp
parentdbe5524fe036e51ebaafa900ce237b85e79020e8 (diff)
downloadscummvm-rg350-aaf5bae026416e158d69633eb1b07c73a63fcccd.tar.gz
scummvm-rg350-aaf5bae026416e158d69633eb1b07c73a63fcccd.tar.bz2
scummvm-rg350-aaf5bae026416e158d69633eb1b07c73a63fcccd.zip
FULLPIPE: Fixed initial scene drawing. Scene bg is shown
Diffstat (limited to 'engines/fullpipe/fullpipe.cpp')
-rw-r--r--engines/fullpipe/fullpipe.cpp34
1 files changed, 31 insertions, 3 deletions
diff --git a/engines/fullpipe/fullpipe.cpp b/engines/fullpipe/fullpipe.cpp
index 2e0444417c..de4da66f3a 100644
--- a/engines/fullpipe/fullpipe.cpp
+++ b/engines/fullpipe/fullpipe.cpp
@@ -110,16 +110,44 @@ Common::Error FullpipeEngine::run() {
ent._sceneId = 3896;
sceneSwitcher(&ent);
+ _currentScene->draw();
+
while (!g_fullpipe->_needQuit) {
updateEvents();
_system->delayMillis(10);
_system->updateScreen();
- _currentScene->draw();
-
- if (g_fullpipe->_keyState == ' ') {
+ switch (g_fullpipe->_keyState) {
+ case Common::KEYCODE_q:
+ g_fullpipe->_needQuit = true;
+ break;
+ case Common::KEYCODE_UP:
+ _sceneRect.moveTo(_sceneRect.left, _sceneRect.top + 10);
+ _currentScene->draw();
+ g_fullpipe->_keyState = Common::KEYCODE_INVALID;
+ break;
+ case Common::KEYCODE_DOWN:
+ _sceneRect.moveTo(_sceneRect.left, _sceneRect.top - 10);
+ _currentScene->draw();
+ g_fullpipe->_keyState = Common::KEYCODE_INVALID;
+ break;
+ case Common::KEYCODE_LEFT:
+ _sceneRect.moveTo(_sceneRect.left + 10, _sceneRect.top);
+ _currentScene->draw();
g_fullpipe->_keyState = Common::KEYCODE_INVALID;
break;
+ case Common::KEYCODE_RIGHT:
+ _sceneRect.moveTo(_sceneRect.left - 10, _sceneRect.top);
+ _currentScene->draw();
+ g_fullpipe->_keyState = Common::KEYCODE_INVALID;
+ break;
+ case Common::KEYCODE_z:
+ _sceneRect.moveTo(0, 0);
+ _currentScene->draw();
+ g_fullpipe->_keyState = Common::KEYCODE_INVALID;
+ break;
+ default:
+ break;
}
}