diff options
author | Johannes Schickel | 2005-12-22 19:31:38 +0000 |
---|---|---|
committer | Johannes Schickel | 2005-12-22 19:31:38 +0000 |
commit | 22033482b0d47c5ed03de8e0226af4e65c85393d (patch) | |
tree | c5dba8507dd182d6baacff38384e8ba864648c76 /kyra/kyra.cpp | |
parent | c36104ac0ca2f350decd4622a70690f651ce7446 (diff) | |
download | scummvm-rg350-22033482b0d47c5ed03de8e0226af4e65c85393d.tar.gz scummvm-rg350-22033482b0d47c5ed03de8e0226af4e65c85393d.tar.bz2 scummvm-rg350-22033482b0d47c5ed03de8e0226af4e65c85393d.zip |
Small bugfixes with enterNewScene and cmd_pauseSeconds.
Implemented opcode: cmd_setSceneFile
svn-id: r19829
Diffstat (limited to 'kyra/kyra.cpp')
-rw-r--r-- | kyra/kyra.cpp | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/kyra/kyra.cpp b/kyra/kyra.cpp index 2de295f445..7abcf00f42 100644 --- a/kyra/kyra.cpp +++ b/kyra/kyra.cpp @@ -1341,7 +1341,7 @@ void KyraEngine::enterNewScene(int sceneId, int facing, int unk1, int unk2, int } void KyraEngine::transcendScenes(int roomIndex, int roomName) { - debug(9, "transcendScenes(%d, %d, %d, %d)", roomIndex, roomName); + debug(9, "transcendScenes(%d, %d)", roomIndex, roomName); assert(roomIndex < _roomTableSize); if (_features & GF_TALKIE) { char file[32]; @@ -1364,6 +1364,12 @@ void KyraEngine::transcendScenes(int roomIndex, int roomName) { _unkScreenVar3 = 0; } +void KyraEngine::setSceneFile(int roomIndex, int roomName) { + debug(9, "setSceneFile(%d, %d)", roomIndex, roomName); + assert(roomIndex < _roomTableSize); + _roomTable[roomIndex].nameIndex = roomName; +} + void KyraEngine::moveCharacterToPos(int character, int facing, int xpos, int ypos) { debug(9, "moveCharacterToPos(%d, %d, %d, %d)", character, facing, xpos, ypos); Character *ch = &_characterList[character]; @@ -1690,8 +1696,8 @@ void KyraEngine::initSceneData(int facing, int unk1, int brandonAlive) { break; } - if ((uint8)(_northExitHeight & 0xFF) >= ypos) { - ypos = (_northExitHeight & 0xFF); + if ((uint8)(_northExitHeight & 0xFF) + 2 >= ypos) { + ypos = (_northExitHeight & 0xFF) + 4; } if (xpos >= 308) { xpos = 304; @@ -1743,7 +1749,7 @@ void KyraEngine::initSceneData(int facing, int unk1, int brandonAlive) { _currentCharacter->x2 = xpos; _currentCharacter->y1 = ypos; _currentCharacter->y2 = ypos; - facing = 4; + facing = 2; xpos2 = 192; ypos2 = 128; setFacing = 0; |