diff options
author | Johannes Schickel | 2007-08-31 13:11:26 +0000 |
---|---|---|
committer | Johannes Schickel | 2007-08-31 13:11:26 +0000 |
commit | 318c8a1d472ad329f352c39fd87c6cfb376ec4fb (patch) | |
tree | 45a2b1984f91988c0f93753ef47223fc65635600 | |
parent | 89e10f450fa29513e01941b49ca80826322ff380 (diff) | |
download | scummvm-rg350-318c8a1d472ad329f352c39fd87c6cfb376ec4fb.tar.gz scummvm-rg350-318c8a1d472ad329f352c39fd87c6cfb376ec4fb.tar.bz2 scummvm-rg350-318c8a1d472ad329f352c39fd87c6cfb376ec4fb.zip |
Fix for bug #1784937 ("KYRA: Wrong path for Brandon in starting location").
svn-id: r28773
-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); } |