diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/gob/game.cpp | 28 | ||||
-rw-r--r-- | engines/gob/game.h | 4 | ||||
-rw-r--r-- | engines/gob/inter_v2.cpp | 6 |
3 files changed, 19 insertions, 19 deletions
diff --git a/engines/gob/game.cpp b/engines/gob/game.cpp index 2ee25b008d..f8775d884b 100644 --- a/engines/gob/game.cpp +++ b/engines/gob/game.cpp @@ -321,7 +321,7 @@ void Game::prepareStart() { _startTimeKey = _vm->_util->getTimeKey(); } -void Game::playTot(int16 skipPlay) { +void Game::playTot(int16 function) { char savedTotName[20]; int16 *oldCaptureCounter; int16 *oldBreakFrom; @@ -341,12 +341,12 @@ void Game::playTot(int16 skipPlay) { _vm->_scenery->_pCaptureCounter = &captureCounter; strcpy(savedTotName, _curTotFile); - if (skipPlay <= 0) { + if (function <= 0) { while (!_vm->shouldQuit()) { if (_vm->_inter->_variables) _vm->_draw->animateCursor(4); - if (skipPlay != -1) { + if (function != -1) { _vm->_inter->initControlVars(1); for (int i = 0; i < 4; i++) { @@ -377,9 +377,9 @@ void Game::playTot(int16 skipPlay) { if ((_curTotFile[0] == 0) && (!_script->isLoaded())) break; - if (skipPlay == -2) { + if (function == -2) { _vm->_vidPlayer->closeVideo(); - skipPlay = 0; + function = 0; } if (!_script->load(_curTotFile)) { @@ -423,7 +423,7 @@ void Game::playTot(int16 skipPlay) { for (int i = 0; i < *_vm->_scenery->_pCaptureCounter; i++) capturePop(0); - if (skipPlay != -1) { + if (function != -1) { _vm->_goblin->freeObjects(); _vm->_sound->blasterStop(0); @@ -449,11 +449,11 @@ void Game::playTot(int16 skipPlay) { _vm->_inter->initControlVars(0); _vm->_scenery->_pCaptureCounter = oldCaptureCounter; - if (skipPlay > 13) { - warning("Addy: skipPlay = %d", skipPlay); - _script->skip(skipPlay); + if (function > 13) { + warning("Addy: function = %d", function); + _script->skip(function); } else - _script->seek(_script->getFunctionOffset(skipPlay + 1)); + _script->seek(_script->getFunctionOffset(function + 1)); _vm->_inter->callSub(2); @@ -641,7 +641,7 @@ void Game::start() { _vm->_draw->_scummvmCursor.reset(); } -// flagbits: 0 = freeInterVariables, 1 = skipPlay +// flagbits: 0 = freeInterVariables, 1 = function -1 void Game::totSub(int8 flags, const char *newTotFile) { int8 curBackupPos; @@ -714,7 +714,7 @@ void Game::totSub(int8 flags, const char *newTotFile) { _vm->_global->_inter_animDataSize = _script->getAnimDataSize(); } -void Game::switchTotSub(int16 index, int16 skipPlay) { +void Game::switchTotSub(int16 index, int16 function) { int16 backupedCount; int16 curBackupPos; @@ -727,7 +727,7 @@ void Game::switchTotSub(int16 index, int16 skipPlay) { // WORKAROUND: Some versions don't make the MOVEMENT menu item unselectable // in the dreamland screen, resulting in a crash when it's clicked. - if ((_vm->getGameType() == kGameTypeGob2) && (index == -1) && (skipPlay == 7) && + if ((_vm->getGameType() == kGameTypeGob2) && (index == -1) && (function == 7) && !scumm_stricmp(_environments->getTotFile(newPos), "gob06.tot")) return; @@ -750,7 +750,7 @@ void Game::switchTotSub(int16 index, int16 skipPlay) { } _hotspots->push(0, true); - playTot(skipPlay); + playTot(function); if (_vm->_inter->_terminate != 2) _vm->_inter->_terminate = 0; diff --git a/engines/gob/game.h b/engines/gob/game.h index 7f8bf67153..a6a3968435 100644 --- a/engines/gob/game.h +++ b/engines/gob/game.h @@ -108,7 +108,7 @@ public: void prepareStart(); - void playTot(int16 skipPlay); + void playTot(int16 function); void capturePush(int16 left, int16 top, int16 width, int16 height); void capturePop(char doDraw); @@ -123,7 +123,7 @@ public: void start(); void totSub(int8 flags, const char *newTotFile); - void switchTotSub(int16 index, int16 skipPlay); + void switchTotSub(int16 index, int16 function); protected: char _tempStr[256]; diff --git a/engines/gob/inter_v2.cpp b/engines/gob/inter_v2.cpp index 3cdde460b8..7fe425b007 100644 --- a/engines/gob/inter_v2.cpp +++ b/engines/gob/inter_v2.cpp @@ -603,12 +603,12 @@ void Inter_v2::o2_totSub() { void Inter_v2::o2_switchTotSub() { int16 index; - int16 skipPlay; + int16 function; index = _vm->_game->_script->readInt16(); - skipPlay = _vm->_game->_script->readInt16(); + function = _vm->_game->_script->readInt16(); - _vm->_game->switchTotSub(index, skipPlay); + _vm->_game->switchTotSub(index, function); } void Inter_v2::o2_pushVars() { |