aboutsummaryrefslogtreecommitdiff
path: root/engines/hdb
diff options
context:
space:
mode:
authorNipun Garg2019-07-14 02:55:48 +0530
committerEugene Sandulenko2019-09-03 17:17:20 +0200
commitc31217f1ee471278115006afd6f6c6a5a8b95705 (patch)
tree37c1b7c8b77c7912a9d8087d50f0a678b12db73e /engines/hdb
parentb36569d201d45e65cabe3fc409a2de97dbaef00e (diff)
downloadscummvm-rg350-c31217f1ee471278115006afd6f6c6a5a8b95705.tar.gz
scummvm-rg350-c31217f1ee471278115006afd6f6c6a5a8b95705.tar.bz2
scummvm-rg350-c31217f1ee471278115006afd6f6c6a5a8b95705.zip
HDB: Add Debug checks
Diffstat (limited to 'engines/hdb')
-rw-r--r--engines/hdb/input.cpp15
-rw-r--r--engines/hdb/menu.cpp3
2 files changed, 15 insertions, 3 deletions
diff --git a/engines/hdb/input.cpp b/engines/hdb/input.cpp
index 4b7ee6afc9..35346f50c5 100644
--- a/engines/hdb/input.cpp
+++ b/engines/hdb/input.cpp
@@ -173,7 +173,17 @@ void Input::stylusDown(int x, int y) {
return;
// Check for map dragging in debug Mode and place player there
- warning("STUB: stylusDown: Check for Map dragging in Debug Mode");
+ if ((GAME_PLAY == g_hdb->getGameState()) && g_hdb->getDebug() == 2) {
+ int mx, my;
+
+ g_hdb->_map->getMapXY(&mx, &my);
+ mx = ((mx + _stylusDownY) / kTileWidth) * kTileWidth;
+ my = ((my + _stylusDownY) / kTileHeight) * kTileHeight;
+ g_hdb->_ai->setPlayerXY(mx, my);
+
+ g_hdb->startMoveMap(x, y);
+ return;
+ }
// Clicked in the world
g_hdb->_map->getMapXY(&worldX, &worldY);
@@ -218,7 +228,8 @@ void Input::stylusMove(int x, int y) {
switch (g_hdb->getGameState()) {
case GAME_PLAY:
- warning("STUB: stylusMove: Add GetDebug() check");
+ if (g_hdb->getDebug() == 2)
+ g_hdb->moveMap(x, y);
break;
case GAME_MENU:
g_hdb->_menu->processInput(x, y);
diff --git a/engines/hdb/menu.cpp b/engines/hdb/menu.cpp
index 99d9c7790e..d70642e7be 100644
--- a/engines/hdb/menu.cpp
+++ b/engines/hdb/menu.cpp
@@ -1220,7 +1220,8 @@ void Menu::processInput(int x, int y) {
_warpActive = map + 2;
g_hdb->paint();
- debug(9, "STUB: Add Debug check");
+ if (g_hdb->getDebug())
+ g_hdb->_gfx->updateVideo();
_warpActive = 0;
if (map < 10)