diff options
-rw-r--r-- | engines/kyra/scene.cpp | 20 | ||||
-rw-r--r-- | engines/kyra/scene_v1.cpp | 4 |
2 files changed, 13 insertions, 11 deletions
diff --git a/engines/kyra/scene.cpp b/engines/kyra/scene.cpp index bf85ab1474..22cf2e0f2b 100644 --- a/engines/kyra/scene.cpp +++ b/engines/kyra/scene.cpp @@ -65,11 +65,11 @@ int KyraEngine::findWay(int x, int y, int toX, int toY, int *moveTable, int move return 0x7D00; } // debug drawing - //if (curX >= 0 && curY >= 0 && curX < 320 && curY < 200) { - // _screen->setPagePixel(0, curX, curY, 11); - // _screen->updateScreen(); - // waitTicks(5); - //} + /*if (curX >= 0 && curY >= 0 && curX < 320 && curY < 200) { + screen()->setPagePixel(0, curX, curY, 11); + screen()->updateScreen(); + //waitTicks(5); + }*/ moveTable[lastUsedEntry++] = newFacing; x = curX; y = curY; @@ -81,11 +81,11 @@ int KyraEngine::findWay(int x, int y, int toX, int toY, int *moveTable, int move newFacing = getFacingFromPointToPoint(curX, curY, toX, toY); changePosTowardsFacing(curX, curY, newFacing); // debug drawing - //if (curX >= 0 && curY >= 0 && curX < 320 && curY < 200) { - // _screen->setPagePixel(0, curX, curY, 8); - // _screen->updateScreen(); - // waitTicks(5); - //} + /*if (curX >= 0 && curY >= 0 && curX < 320 && curY < 200) { + screen()->setPagePixel(0, curX, curY, 8); + screen()->updateScreen(); + //waitTicks(5); + }*/ if (!lineIsPassable(curX, curY)) { if (curX != toX || curY != toY) diff --git a/engines/kyra/scene_v1.cpp b/engines/kyra/scene_v1.cpp index 3754d5e2ab..9940063d24 100644 --- a/engines/kyra/scene_v1.cpp +++ b/engines/kyra/scene_v1.cpp @@ -1166,7 +1166,9 @@ void KyraEngine_v1::setCharactersPositions(int character) { int KyraEngine_v1::findWay(int x, int y, int toX, int toY, int *moveTable, int moveTableSize) { debugC(9, kDebugLevelMain, "KyraEngine_v1::findWay(%d, %d, %d, %d, %p, %d)", x, y, toX, toY, (const void *)moveTable, moveTableSize); - KyraEngine::findWay(x, y, toX, toY, moveTable, moveTableSize); + int ret = KyraEngine::findWay(x, y, toX, toY, moveTable, moveTableSize); + if (ret == 0x7D00) + return 0; return getMoveTableSize(moveTable); } |