diff options
author | Strangerke | 2016-03-20 19:21:00 +0100 |
---|---|---|
committer | Eugene Sandulenko | 2016-05-10 09:54:21 +0200 |
commit | e6496188f71dcb0435471bf82bab71cafabc73f3 (patch) | |
tree | 1385bad0f896962301ef92e12d349297291244a4 /engines | |
parent | 6d1a6738f49e195276089666db166b17285bcce3 (diff) | |
download | scummvm-rg350-e6496188f71dcb0435471bf82bab71cafabc73f3.tar.gz scummvm-rg350-e6496188f71dcb0435471bf82bab71cafabc73f3.tar.bz2 scummvm-rg350-e6496188f71dcb0435471bf82bab71cafabc73f3.zip |
GNAP: Rename scene 43, 44 and 45 variables for consistency
Diffstat (limited to 'engines')
-rw-r--r-- | engines/gnap/gnap.h | 14 | ||||
-rw-r--r-- | engines/gnap/scenes/scene43.cpp | 54 | ||||
-rw-r--r-- | engines/gnap/scenes/scene44.cpp | 92 | ||||
-rw-r--r-- | engines/gnap/scenes/scene45.cpp | 14 |
4 files changed, 87 insertions, 87 deletions
diff --git a/engines/gnap/gnap.h b/engines/gnap/gnap.h index 873255bafa..a440f4a092 100644 --- a/engines/gnap/gnap.h +++ b/engines/gnap/gnap.h @@ -864,8 +864,8 @@ public: void scene42_updateAnimations(); // Scene 43 - int _currTwoHeadedGuySequenceId; - int _nextTwoHeadedGuySequenceId; + int _s43_currTwoHeadedGuySequenceId; + int _s43_nextTwoHeadedGuySequenceId; int scene43_init(); void scene43_updateHotspots(); @@ -873,17 +873,17 @@ public: void scene43_updateAnimations(); // Scene 44 - int _nextSpringGuySequenceId; - int _nextKissingLadySequenceId; - int _currSpringGuySequenceId; - int _currKissingLadySequenceId; + int _s44_nextSpringGuySequenceId; + int _s44_nextKissingLadySequenceId; + int _s44_currSpringGuySequenceId; + int _s44_currKissingLadySequenceId; int scene44_init(); void scene44_updateHotspots(); void scene44_run(); void scene44_updateAnimations(); // Scene 45 - int _currDancerSequenceId; + int _s45_currDancerSequenceId; int scene45_init(); void scene45_updateHotspots(); void scene45_run(); diff --git a/engines/gnap/scenes/scene43.cpp b/engines/gnap/scenes/scene43.cpp index e0cc8ad033..51917d5389 100644 --- a/engines/gnap/scenes/scene43.cpp +++ b/engines/gnap/scenes/scene43.cpp @@ -92,11 +92,11 @@ void GnapEngine::scene43_run() { if (!isFlag(14)) _gameSys->insertSequence(0x1086F, 1, 0, 0, kSeqNone, 0, 0, 0); - _currTwoHeadedGuySequenceId = 0x13C; - _nextTwoHeadedGuySequenceId = -1; + _s43_currTwoHeadedGuySequenceId = 0x13C; + _s43_nextTwoHeadedGuySequenceId = -1; _gameSys->setAnimation(0x13C, 1, 2); - _gameSys->insertSequence(_currTwoHeadedGuySequenceId, 1, 0, 0, kSeqNone, 0, 0, 0); + _gameSys->insertSequence(_s43_currTwoHeadedGuySequenceId, 1, 0, 0, kSeqNone, 0, 0, 0); if (isFlag(12)) { _toyUfoId = 0; @@ -332,27 +332,27 @@ void GnapEngine::scene43_run() { updateGnapIdleSequence(); if (!_timers[4] && (!isFlag(12) || !isFlag(19))) { _timers[4] = getRandom(100) + 100; - if (_gnapActionStatus < 0 && _beaverActionStatus < 0 && _nextTwoHeadedGuySequenceId == -1) { + if (_gnapActionStatus < 0 && _beaverActionStatus < 0 && _s43_nextTwoHeadedGuySequenceId == -1) { _gnapRandomValue = getRandom(5); switch (_gnapRandomValue) { case 0: - _nextTwoHeadedGuySequenceId = 0x13C; + _s43_nextTwoHeadedGuySequenceId = 0x13C; break; case 1: - _nextTwoHeadedGuySequenceId = 0x134; + _s43_nextTwoHeadedGuySequenceId = 0x134; break; case 2: - _nextTwoHeadedGuySequenceId = 0x135; + _s43_nextTwoHeadedGuySequenceId = 0x135; break; case 3: - _nextTwoHeadedGuySequenceId = 0x136; + _s43_nextTwoHeadedGuySequenceId = 0x136; break; case 4: - _nextTwoHeadedGuySequenceId = 0x13A; + _s43_nextTwoHeadedGuySequenceId = 0x13A; break; } - if (_nextTwoHeadedGuySequenceId == _currTwoHeadedGuySequenceId) - _nextTwoHeadedGuySequenceId = -1; + if (_s43_nextTwoHeadedGuySequenceId == _s43_currTwoHeadedGuySequenceId) + _s43_nextTwoHeadedGuySequenceId = -1; } } } @@ -391,11 +391,11 @@ void GnapEngine::scene43_updateAnimations() { _gnapSequenceId = 0x13D; _gnapSequenceDatNum = 0; _gameSys->setAnimation(0x13D, _gnapId, 0); - _nextTwoHeadedGuySequenceId = 0x13B; - _gameSys->insertSequence(0x13B, 1, _currTwoHeadedGuySequenceId, 1, kSeqSyncWait, 0, 0, 0); - _gameSys->setAnimation(_nextTwoHeadedGuySequenceId, 1, 2); - _currTwoHeadedGuySequenceId = _nextTwoHeadedGuySequenceId; - _nextTwoHeadedGuySequenceId = -1; + _s43_nextTwoHeadedGuySequenceId = 0x13B; + _gameSys->insertSequence(0x13B, 1, _s43_currTwoHeadedGuySequenceId, 1, kSeqSyncWait, 0, 0, 0); + _gameSys->setAnimation(_s43_nextTwoHeadedGuySequenceId, 1, 2); + _s43_currTwoHeadedGuySequenceId = _s43_nextTwoHeadedGuySequenceId; + _s43_nextTwoHeadedGuySequenceId = -1; _timers[4] = getRandom(100) + 100; _gnapActionStatus = -1; } @@ -409,24 +409,24 @@ void GnapEngine::scene43_updateAnimations() { } if (_gameSys->getAnimationStatus(2) == 2) { - if (_currTwoHeadedGuySequenceId == 0x13A) { + if (_s43_currTwoHeadedGuySequenceId == 0x13A) { if (isFlag(19)) { - _nextTwoHeadedGuySequenceId = 0x13E; + _s43_nextTwoHeadedGuySequenceId = 0x13E; stopSound(0x108F6); } else if (getRandom(2) != 0) { - _nextTwoHeadedGuySequenceId = 0x137; + _s43_nextTwoHeadedGuySequenceId = 0x137; } else { - _nextTwoHeadedGuySequenceId = 0x138; + _s43_nextTwoHeadedGuySequenceId = 0x138; } - } else if (_currTwoHeadedGuySequenceId == 0x13E) { + } else if (_s43_currTwoHeadedGuySequenceId == 0x13E) { _sceneDone = true; _newSceneNum = 54; } - if (_nextTwoHeadedGuySequenceId != -1) { - _gameSys->insertSequence(_nextTwoHeadedGuySequenceId, 1, _currTwoHeadedGuySequenceId, 1, kSeqSyncWait, 0, 0, 0); - _gameSys->setAnimation(_nextTwoHeadedGuySequenceId, 1, 2); - _currTwoHeadedGuySequenceId = _nextTwoHeadedGuySequenceId; - _nextTwoHeadedGuySequenceId = -1; + if (_s43_nextTwoHeadedGuySequenceId != -1) { + _gameSys->insertSequence(_s43_nextTwoHeadedGuySequenceId, 1, _s43_currTwoHeadedGuySequenceId, 1, kSeqSyncWait, 0, 0, 0); + _gameSys->setAnimation(_s43_nextTwoHeadedGuySequenceId, 1, 2); + _s43_currTwoHeadedGuySequenceId = _s43_nextTwoHeadedGuySequenceId; + _s43_nextTwoHeadedGuySequenceId = -1; _timers[4] = getRandom(100) + 100; } } @@ -458,7 +458,7 @@ void GnapEngine::scene43_updateAnimations() { _gnapActionStatus = 3; break; case 8: - _nextTwoHeadedGuySequenceId = 0x13A; + _s43_nextTwoHeadedGuySequenceId = 0x13A; _toyUfoX = 514; _toyUfoY = 125; toyUfoFlyTo(835, 125, 0, 835, 0, 300, 3); diff --git a/engines/gnap/scenes/scene44.cpp b/engines/gnap/scenes/scene44.cpp index 1041734dbc..c0905c7434 100644 --- a/engines/gnap/scenes/scene44.cpp +++ b/engines/gnap/scenes/scene44.cpp @@ -86,31 +86,31 @@ void GnapEngine::scene44_run() { _gameSys->insertSequence(0xFC, 256, 0, 0, kSeqNone, 0, 0, 0); if (isFlag(15)) - _currSpringGuySequenceId = 0xF8; + _s44_currSpringGuySequenceId = 0xF8; else - _currSpringGuySequenceId = 0xF9; + _s44_currSpringGuySequenceId = 0xF9; - _nextSpringGuySequenceId = -1; - _gameSys->setAnimation(_currSpringGuySequenceId, 1, 4); - _gameSys->insertSequence(_currSpringGuySequenceId, 1, 0, 0, kSeqNone, 0, 0, 0); + _s44_nextSpringGuySequenceId = -1; + _gameSys->setAnimation(_s44_currSpringGuySequenceId, 1, 4); + _gameSys->insertSequence(_s44_currSpringGuySequenceId, 1, 0, 0, kSeqNone, 0, 0, 0); if (isFlag(13)) { if (_prevSceneNum != 50 || _sceneSavegameLoaded) { - _currKissingLadySequenceId = 0xF6; - _nextKissingLadySequenceId = -1; + _s44_currKissingLadySequenceId = 0xF6; + _s44_nextKissingLadySequenceId = -1; } else { setGrabCursorSprite(kItemGum); - _currKissingLadySequenceId = 0xF5; - _nextKissingLadySequenceId = 0xF6; + _s44_currKissingLadySequenceId = 0xF5; + _s44_nextKissingLadySequenceId = 0xF6; _gameSys->setAnimation(0xF5, 1, 2); } } else { - _currKissingLadySequenceId = 0xEC; - _nextKissingLadySequenceId = -1; + _s44_currKissingLadySequenceId = 0xEC; + _s44_nextKissingLadySequenceId = -1; _gameSys->setAnimation(0xEC, 1, 2); } - _gameSys->insertSequence(_currKissingLadySequenceId, 1, 0, 0, kSeqNone, 0, 0, 0); + _gameSys->insertSequence(_s44_currKissingLadySequenceId, 1, 0, 0, kSeqNone, 0, 0, 0); if (isFlag(12)) { _toyUfoId = 0; @@ -306,7 +306,7 @@ void GnapEngine::scene44_run() { case GRAB_CURSOR: playGnapPullOutDevice(8, 0); playGnapUseDevice(8, 0); - _nextSpringGuySequenceId = 0xFB; + _s44_nextSpringGuySequenceId = 0xFB; invAdd(kItemSpring); setFlag(15); scene44_updateHotspots(); @@ -369,50 +369,50 @@ void GnapEngine::scene44_run() { toyUfoCheckTimer(); if (!_isLeavingScene) { - if (_beaverActionStatus < 0 && !isFlag(12) && _currKissingLadySequenceId != 0xF5) + if (_beaverActionStatus < 0 && !isFlag(12) && _s44_currKissingLadySequenceId != 0xF5) updateBeaverIdleSequence(); if (_gnapActionStatus < 0 && !isFlag(12)) updateGnapIdleSequence(); if (!_timers[4]) { _timers[4] = getRandom(20) + 20; - if (_gnapActionStatus < 0 && _beaverActionStatus < 0 && _nextKissingLadySequenceId == -1) { + if (_gnapActionStatus < 0 && _beaverActionStatus < 0 && _s44_nextKissingLadySequenceId == -1) { _gnapRandomValue = getRandom(20); switch (_gnapRandomValue) { case 0: - _nextKissingLadySequenceId = 0xED; + _s44_nextKissingLadySequenceId = 0xED; break; case 1: - _nextKissingLadySequenceId = 0xEE; + _s44_nextKissingLadySequenceId = 0xEE; break; case 2: - _nextKissingLadySequenceId = 0xF0; + _s44_nextKissingLadySequenceId = 0xF0; break; case 3: - _nextKissingLadySequenceId = 0xF3; + _s44_nextKissingLadySequenceId = 0xF3; break; case 4: - _nextKissingLadySequenceId = 0xF4; + _s44_nextKissingLadySequenceId = 0xF4; break; default: - _nextKissingLadySequenceId = 0xEC; + _s44_nextKissingLadySequenceId = 0xEC; break; } - if (_nextKissingLadySequenceId != 0xEC && _nextKissingLadySequenceId == _currKissingLadySequenceId) - _nextKissingLadySequenceId = -1; + if (_s44_nextKissingLadySequenceId != 0xEC && _s44_nextKissingLadySequenceId == _s44_currKissingLadySequenceId) + _s44_nextKissingLadySequenceId = -1; } } if (!_timers[5]) { _timers[5] = getRandom(20) + 20; - if (_gnapActionStatus < 0 && _beaverActionStatus < 0 && _nextSpringGuySequenceId == -1) { + if (_gnapActionStatus < 0 && _beaverActionStatus < 0 && _s44_nextSpringGuySequenceId == -1) { _gnapRandomValue = getRandom(5); if (_gnapRandomValue != 0) { if (!isFlag(15)) - _nextSpringGuySequenceId = 0xF9; + _s44_nextSpringGuySequenceId = 0xF9; } else { if (isFlag(15)) - _nextSpringGuySequenceId = 0xF8; + _s44_nextSpringGuySequenceId = 0xF8; else - _nextSpringGuySequenceId = 0xFA; + _s44_nextSpringGuySequenceId = 0xFA; } } } @@ -439,10 +439,10 @@ void GnapEngine::scene44_updateAnimations() { _sceneDone = true; break; case 1: - _nextKissingLadySequenceId = 0xEF; + _s44_nextKissingLadySequenceId = 0xEF; break; case 2: - _nextKissingLadySequenceId = 0xF2; + _s44_nextKissingLadySequenceId = 0xF2; break; } _gnapActionStatus = -1; @@ -457,7 +457,7 @@ void GnapEngine::scene44_updateAnimations() { _beaverSequenceId = 0xFE; _beaverSequenceDatNum = 0; _gameSys->setAnimation(0xFE, _beaverId, 1); - _gameSys->removeSequence(_currKissingLadySequenceId, 1, true); + _gameSys->removeSequence(_s44_currKissingLadySequenceId, 1, true); _beaverActionStatus = 5; } break; @@ -472,31 +472,31 @@ void GnapEngine::scene44_updateAnimations() { } if (_gameSys->getAnimationStatus(2) == 2) { - if (_nextKissingLadySequenceId == 0xF6) { - _gameSys->insertSequence(_nextKissingLadySequenceId, 1, _currKissingLadySequenceId, 1, kSeqSyncWait, 0, 0, 0); + if (_s44_nextKissingLadySequenceId == 0xF6) { + _gameSys->insertSequence(_s44_nextKissingLadySequenceId, 1, _s44_currKissingLadySequenceId, 1, kSeqSyncWait, 0, 0, 0); initBeaverPos(5, 8, 0); - _currKissingLadySequenceId = _nextKissingLadySequenceId; - _nextKissingLadySequenceId = -1; + _s44_currKissingLadySequenceId = _s44_nextKissingLadySequenceId; + _s44_nextKissingLadySequenceId = -1; _gameSys->setAnimation(0, 0, 2); - } else if (_nextKissingLadySequenceId != -1) { - _gameSys->insertSequence(_nextKissingLadySequenceId, 1, _currKissingLadySequenceId, 1, kSeqSyncWait, 0, 0, 0); - _gameSys->setAnimation(_nextKissingLadySequenceId, 1, 2); - _currKissingLadySequenceId = _nextKissingLadySequenceId; - _nextKissingLadySequenceId = -1; + } else if (_s44_nextKissingLadySequenceId != -1) { + _gameSys->insertSequence(_s44_nextKissingLadySequenceId, 1, _s44_currKissingLadySequenceId, 1, kSeqSyncWait, 0, 0, 0); + _gameSys->setAnimation(_s44_nextKissingLadySequenceId, 1, 2); + _s44_currKissingLadySequenceId = _s44_nextKissingLadySequenceId; + _s44_nextKissingLadySequenceId = -1; _timers[4] = getRandom(20) + 20; } } if (_gameSys->getAnimationStatus(4) == 2) { - if (_currSpringGuySequenceId == 0xFB) { + if (_s44_currSpringGuySequenceId == 0xFB) { setGrabCursorSprite(kItemSpring); - _nextSpringGuySequenceId = 0xF8; + _s44_nextSpringGuySequenceId = 0xF8; } - if (_nextSpringGuySequenceId != -1) { - _gameSys->insertSequence(_nextSpringGuySequenceId, 1, _currSpringGuySequenceId, 1, kSeqSyncWait, 0, 0, 0); - _gameSys->setAnimation(_nextSpringGuySequenceId, 1, 4); - _currSpringGuySequenceId = _nextSpringGuySequenceId; - _nextSpringGuySequenceId = -1; + if (_s44_nextSpringGuySequenceId != -1) { + _gameSys->insertSequence(_s44_nextSpringGuySequenceId, 1, _s44_currSpringGuySequenceId, 1, kSeqSyncWait, 0, 0, 0); + _gameSys->setAnimation(_s44_nextSpringGuySequenceId, 1, 4); + _s44_currSpringGuySequenceId = _s44_nextSpringGuySequenceId; + _s44_nextSpringGuySequenceId = -1; _timers[5] = getRandom(20) + 20; } } diff --git a/engines/gnap/scenes/scene45.cpp b/engines/gnap/scenes/scene45.cpp index a3dd758545..b25216d5bf 100644 --- a/engines/gnap/scenes/scene45.cpp +++ b/engines/gnap/scenes/scene45.cpp @@ -93,9 +93,9 @@ void GnapEngine::scene45_run() { _gameSys->setAnimation(0x96, 1, 3); _gameSys->insertSequence(0x99, 1, 0, 0, kSeqNone, 0, 0, 0); _gameSys->setAnimation(0x99, 1, 4); - _currDancerSequenceId = 0x8F; - _gameSys->setAnimation(_currDancerSequenceId, 1, 2); - _gameSys->insertSequence(_currDancerSequenceId, 1, 0, 0, kSeqNone, 0, 0, 0); + _s45_currDancerSequenceId = 0x8F; + _gameSys->setAnimation(_s45_currDancerSequenceId, 1, 2); + _gameSys->insertSequence(_s45_currDancerSequenceId, 1, 0, 0, kSeqNone, 0, 0, 0); if (isFlag(12)) { _toyUfoId = 0; @@ -149,9 +149,9 @@ void GnapEngine::scene45_run() { _gameSys->setAnimation(0, 0, 2); _gnapRandomValue = getRandom(7); int newSeqId = _gnapRandomValue + 0x8F; - _gameSys->insertSequence(_gnapRandomValue + 0x8F, 1, _currDancerSequenceId, 1, kSeqSyncWait, 0, 0, 0); + _gameSys->insertSequence(_gnapRandomValue + 0x8F, 1, _s45_currDancerSequenceId, 1, kSeqSyncWait, 0, 0, 0); _gameSys->setAnimation(newSeqId, 1, 2); - _currDancerSequenceId = newSeqId; + _s45_currDancerSequenceId = newSeqId; } if (_gameSys->getAnimationStatus(3) == 2 && _gameSys->getAnimationStatus(4) == 2) { _gameSys->insertSequence(0x96, 1, 0x96, 1, kSeqSyncWait, 0, 0, 0); @@ -395,9 +395,9 @@ void GnapEngine::scene45_updateAnimations() { _gameSys->setAnimation(0, 0, 2); _gnapRandomValue = getRandom(7); int newSeqId = _gnapRandomValue + 0x8F; - _gameSys->insertSequence(_gnapRandomValue + 0x8F, 1, _currDancerSequenceId, 1, kSeqSyncWait, 0, 0, 0); + _gameSys->insertSequence(_gnapRandomValue + 0x8F, 1, _s45_currDancerSequenceId, 1, kSeqSyncWait, 0, 0, 0); _gameSys->setAnimation(newSeqId, 1, 2); - _currDancerSequenceId = newSeqId; + _s45_currDancerSequenceId = newSeqId; } if (_gameSys->getAnimationStatus(3) == 2 && _gameSys->getAnimationStatus(4) == 2) { |