aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNipun Garg2019-06-18 23:30:59 +0530
committerEugene Sandulenko2019-09-03 17:16:48 +0200
commit0091735d0a2a67bdc0695099ece6c8b4866d7ad6 (patch)
tree8d9d66c52f1c378d391536631167bfc3e5d634c4
parent70ab42ea7e62e111386067b9e6e9ea319610fd29 (diff)
downloadscummvm-rg350-0091735d0a2a67bdc0695099ece6c8b4866d7ad6.tar.gz
scummvm-rg350-0091735d0a2a67bdc0695099ece6c8b4866d7ad6.tar.bz2
scummvm-rg350-0091735d0a2a67bdc0695099ece6c8b4866d7ad6.zip
HDB: Add additional debug output for C_MOVECAMERA
-rw-r--r--engines/hdb/ai.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/engines/hdb/ai.cpp b/engines/hdb/ai.cpp
index c414fd21b4..44c02baa6c 100644
--- a/engines/hdb/ai.cpp
+++ b/engines/hdb/ai.cpp
@@ -105,13 +105,14 @@ void AI::processCines() {
case C_MOVECAMERA:
_cameraLock = true;
if (!(_cine[i]->start)) {
+ debug(3, "C_MOVECAMERA: [%d] now: x: %d, y: %d, speed: %d", i, _cine[i]->x, i, _cine[i]->y, _cine[i]->speed);
_cine[i]->xv = (((double)_cine[i]->x) - _cameraX) / (double)_cine[i]->speed;
_cine[i]->yv = (((double)_cine[i]->y) - _cameraY) / (double)_cine[i]->speed;
_cine[i]->start = 1;
}
_cameraX += _cine[i]->xv;
_cameraY += _cine[i]->yv;
- debug(3, "_cine[%d]->xv: %d, _cine[%d]->yv: %d", i, _cine[i]->xv, i, _cine[i]->yv);
+ debug(3, "C_MOVECAMERA: _cine[%d]->xv: %d, _cine[%d]->yv: %d", i, _cine[i]->xv, i, _cine[i]->yv);
debug(3, "C_MOVECAMERA: abs(_cameraX - _cine[i]->x): %d, abs(_cameraY - _cine[i]->y): %d", abs(_cameraX - _cine[i]->x), abs(_cameraY - _cine[i]->y));
if (abs(_cameraX - _cine[i]->x) <= 1 && abs(_cameraY - _cine[i]->y) <= 1) {
_cameraX = _cine[i]->x;
@@ -202,6 +203,7 @@ void AI::cineMoveCamera(int x, int y, int speed) {
cmd->start = 0;
cmd->x = x * kTileWidth;
cmd->y = y * kTileHeight;
+ debug("Setting up C_MOVECAMERA: x: %d, y: %d", cmd->x, cmd->y);
cmd->cmdType = C_MOVECAMERA;
_cine.push_back(cmd);
}