diff options
author | Strangerke | 2013-09-09 23:34:12 +0200 |
---|---|---|
committer | Strangerke | 2013-09-09 23:34:12 +0200 |
commit | bc64dcf276f15fe9bd808d087762e100fb7d931d (patch) | |
tree | 469058f64dc645de0caacdb0e941247bf1b73e4c /engines/avalanche | |
parent | 1ca62e51b9a66711fd1b266bed1432509c489f8f (diff) | |
download | scummvm-rg350-bc64dcf276f15fe9bd808d087762e100fb7d931d.tar.gz scummvm-rg350-bc64dcf276f15fe9bd808d087762e100fb7d931d.tar.bz2 scummvm-rg350-bc64dcf276f15fe9bd808d087762e100fb7d931d.zip |
AVALANCHE: harmonize the use of constants for kMagic, kProc, kObject, kPeople
Diffstat (limited to 'engines/avalanche')
-rw-r--r-- | engines/avalanche/acci2.cpp | 98 | ||||
-rw-r--r-- | engines/avalanche/animation.cpp | 182 | ||||
-rw-r--r-- | engines/avalanche/avalanche.cpp | 9 | ||||
-rw-r--r-- | engines/avalanche/avalanche.h | 9 | ||||
-rw-r--r-- | engines/avalanche/avalot.cpp | 4 | ||||
-rw-r--r-- | engines/avalanche/dropdown2.cpp | 6 | ||||
-rw-r--r-- | engines/avalanche/enid2.cpp | 2 | ||||
-rw-r--r-- | engines/avalanche/lucerna2.cpp | 64 | ||||
-rw-r--r-- | engines/avalanche/scrolls2.cpp | 2 | ||||
-rw-r--r-- | engines/avalanche/sequence2.cpp | 4 | ||||
-rw-r--r-- | engines/avalanche/timer.cpp | 24 | ||||
-rw-r--r-- | engines/avalanche/visa2.cpp | 12 |
12 files changed, 208 insertions, 208 deletions
diff --git a/engines/avalanche/acci2.cpp b/engines/avalanche/acci2.cpp index 59a8ed8c37..cec9c422f9 100644 --- a/engines/avalanche/acci2.cpp +++ b/engines/avalanche/acci2.cpp @@ -378,7 +378,7 @@ void Acci::storeInterrogation(byte interrogation) { while ((_vm->_parser->_inputText.lastChar() == ' ') && (!_vm->_parser->_inputText.empty())) _vm->_parser->_inputText.deleteLastChar(); - _vm->_timer->loseTimer(_vm->_timer->kReasonCardiffsurvey); // If you want to use any other timer, put this into the case statement. + _vm->_timer->loseTimer(Timer::kReasonCardiffsurvey); // If you want to use any other timer, put this into the case statement. switch (interrogation) { case 1: @@ -408,7 +408,7 @@ void Acci::storeInterrogation(byte interrogation) { _vm->_visa->displayScrollChain('z', 5); // His closing statement... _vm->_animation->_sprites[1].walkTo(4); // The end of the drawbridge _vm->_animation->_sprites[1]._vanishIfStill = true; // Then go away! - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicNothing; + _vm->_gyro->_magics[1]._operation = Gyro::kMagicNothing; _vm->_gyro->_dna._cardiffQuestionNum = 5; break; case 99: @@ -783,7 +783,7 @@ void Acci::swallow() { // Eat something. _vm->_visa->displayScrollChain('U', 1); _vm->_pingo->wobble(); _vm->_visa->displayScrollChain('U', 2); - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectWine - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectWine - 1] = false; _vm->_lucerna->refreshObjectList(); drink(); break; @@ -814,7 +814,7 @@ void Acci::swallow() { // Eat something. _vm->_visa->displayScrollChain('U', 11); else { _vm->_visa->displayScrollChain('U', 8); - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectOnion - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectOnion - 1] = false; _vm->_lucerna->refreshObjectList(); } break; @@ -979,7 +979,7 @@ void Acci::putProc() { // Thing is the _thing which you're putting in. _thing2 is where you're putting it. switch (_thing2) { case Gyro::kObjectWine: - if (_thing == _vm->_gyro->kObjectOnion) { + if (_thing == Gyro::kObjectOnion) { if (_vm->_gyro->_dna._rottenOnion) _vm->_scrolls->displayText("That's a bit like shutting the stable door after the horse has bolted!"); else { // Put onion into wine? @@ -1056,7 +1056,7 @@ void Acci::notInOrder() { */ void Acci::goToCauldron() { _vm->_animation->_sprites[1]._callEachStepFl = false; // Stops Geida_Procs. - _vm->_timer->addTimer(1, _vm->_timer->kProcSpludwickGoesToCauldron, _vm->_timer->kReasonSpludwickWalk); + _vm->_timer->addTimer(1, Timer::kProcSpludwickGoesToCauldron, Timer::kReasonSpludwickWalk); _vm->_animation->_sprites[1].walkTo(2); } @@ -1072,7 +1072,7 @@ bool Acci::giveToSpludwick() { switch (_thing) { case Gyro::kObjectOnion: - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectOnion - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectOnion - 1] = false; if (_vm->_gyro->_dna._rottenOnion) _vm->_visa->displayScrollChain('q', 22); else { @@ -1084,7 +1084,7 @@ bool Acci::giveToSpludwick() { _vm->_lucerna->refreshObjectList(); break; case Gyro::kObjectInk: - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectInk - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectInk - 1] = false; _vm->_lucerna->refreshObjectList(); _vm->_gyro->_dna._givenToSpludwick++; _vm->_visa->displayScrollChain('q', 24); @@ -1092,12 +1092,12 @@ bool Acci::giveToSpludwick() { _vm->_lucerna->incScore(3); break; case Gyro::kObjectMushroom: - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectMushroom - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectMushroom - 1] = false; _vm->_visa->displayScrollChain('q', 25); _vm->_lucerna->incScore(5); _vm->_gyro->_dna._givenToSpludwick++; goToCauldron(); - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectPotion - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectPotion - 1] = true; _vm->_lucerna->refreshObjectList(); break; default: @@ -1110,7 +1110,7 @@ bool Acci::giveToSpludwick() { void Acci::drink() { _vm->_gyro->_dna._alcoholLevel += 1; if (_vm->_gyro->_dna._alcoholLevel == 5) { - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectKey - 1] = true; // Get the key. + _vm->_gyro->_dna._objects[Gyro::kObjectKey - 1] = true; // Get the key. _vm->_gyro->_dna._teetotal = true; _vm->_gyro->_dna._avvyIsAwake = false; _vm->_gyro->_dna._avvyInBed = true; @@ -1158,7 +1158,7 @@ void Acci::standUp() { _vm->_celer->drawBackgroundSprite(-1, -1, 4); // Picture of empty pillow. _vm->_lucerna->incScore(1); _vm->_gyro->_dna._avvyInBed = false; - _vm->_timer->loseTimer(_vm->_timer->kReasonArkataShouts); + _vm->_timer->loseTimer(Timer::kReasonArkataShouts); } else already(); break; @@ -1211,7 +1211,7 @@ void Acci::getProc(char thing) { _vm->_celer->drawBackgroundSprite(-1, -1, 4); // No pen there now. _vm->_animation->callSpecial(3); // Zap! _vm->_gyro->_dna._takenPen = true; - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectPen - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectPen - 1] = true; _vm->_lucerna->refreshObjectList(); _vm->_scrolls->displayText("Taken."); } @@ -1228,12 +1228,12 @@ void Acci::getProc(char thing) { } break; case r__robins: - if ((thing == _vm->_gyro->kObjectMushroom) & (_vm->_animation->inField(1)) & (_vm->_gyro->_dna._mushroomGrowing)) { + if ((thing == Gyro::kObjectMushroom) & (_vm->_animation->inField(1)) & (_vm->_gyro->_dna._mushroomGrowing)) { _vm->_celer->drawBackgroundSprite(-1, -1, 3); _vm->_scrolls->displayText("Got it!"); _vm->_gyro->_dna._mushroomGrowing = false; _vm->_gyro->_dna._takenMushroom = true; - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectMushroom - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectMushroom - 1] = true; _vm->_lucerna->refreshObjectList(); _vm->_lucerna->incScore(3); } else @@ -1253,11 +1253,11 @@ void Acci::giveGeidaTheLute() { _vm->_scrolls->displayText(Common::String("Not yet. Try later!") + Scrolls::kControlRegister + '2' + Scrolls::kControlSpeechBubble); return; } - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectLute - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectLute - 1] = false; _vm->_lucerna->refreshObjectList(); _vm->_visa->displayScrollChain('q', 64); // She plays it. - _vm->_timer->addTimer(1, _vm->_timer->kProcGiveLuteToGeida, _vm->_timer->kReasonGeidaSings); + _vm->_timer->addTimer(1, Timer::kProcGiveLuteToGeida, Timer::kReasonGeidaSings); _vm->_enid->backToBootstrap(4); } @@ -1274,7 +1274,7 @@ void Acci::winSequence() { _vm->_sequence->thenShow(8); _vm->_sequence->thenShow(9); _vm->_sequence->startToClose(); - _vm->_timer->addTimer(30, _vm->_timer->kProcWinning, _vm->_timer->kReasonWinning); + _vm->_timer->addTimer(30, Timer::kProcWinning, Timer::kReasonWinning); } void Acci::personSpeaks() { @@ -1418,14 +1418,14 @@ void Acci::doThat() { default: switch (_person) { case Gyro::kPeopleCrapulus: - if (_thing == _vm->_gyro->kObjectWine) { + if (_thing == Gyro::kObjectWine) { _vm->_scrolls->displayText("Crapulus grabs the wine and gulps it down."); - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectWine - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectWine - 1] = false; } else heyThanks(); break; case Gyro::kPeopleCwytalot: - if ((_thing == _vm->_gyro->kObjectCrossbow) || (_thing == _vm->_gyro->kObjectBolt)) + if ((_thing == Gyro::kObjectCrossbow) || (_thing == Gyro::kObjectBolt)) _vm->_scrolls->displayText(Common::String("You might be able to influence Cwytalot more if you used it!")); else heyThanks(); @@ -1435,11 +1435,11 @@ void Acci::doThat() { heyThanks(); break; case Gyro::kPeopleIbythneth: - if (_thing == _vm->_gyro->kObjectBadge) { + if (_thing == Gyro::kObjectBadge) { _vm->_visa->displayScrollChain('q', 32); // Thanks! Wow! _vm->_lucerna->incScore(3); - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectBadge - 1] = false; - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectHabit - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectBadge - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectHabit - 1] = true; _vm->_gyro->_dna._givenBadgeToIby = true; _vm->_celer->drawBackgroundSprite(-1, -1, 8); _vm->_celer->drawBackgroundSprite(-1, -1, 9); @@ -1448,10 +1448,10 @@ void Acci::doThat() { break; case Gyro::kPeopleAyles: if (_vm->_gyro->_dna._aylesIsAwake) { - if (_thing == _vm->_gyro->kObjectPen) { - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectPen - 1] = false; + if (_thing == Gyro::kObjectPen) { + _vm->_gyro->_dna._objects[Gyro::kObjectPen - 1] = false; _vm->_visa->displayScrollChain('q', 54); - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectInk - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectInk - 1] = true; _vm->_gyro->_dna._givenPenToAyles = true; _vm->_lucerna->refreshObjectList(); _vm->_lucerna->incScore(2); @@ -1463,7 +1463,7 @@ void Acci::doThat() { case Gyro::kPeopleGeida: switch (_thing) { case Gyro::kObjectPotion: - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectPotion - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectPotion - 1] = false; _vm->_visa->displayScrollChain('u', 16); // She drinks it. _vm->_lucerna->incScore(2); _vm->_gyro->_dna._givenPotionToGeida = true; @@ -1579,7 +1579,7 @@ void Acci::doThat() { _vm->_lucerna->refreshObjectList(); byte i; - if (_thing == _vm->_gyro->kObjectHabit) + if (_thing == Gyro::kObjectHabit) i = 3; else i = 0; @@ -1622,7 +1622,7 @@ void Acci::doThat() { // You won - strange! _vm->_visa->displayScrollChain('Q', 7); // You won! Give us a lute! - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectLute - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectLute - 1] = true; _vm->_lucerna->refreshObjectList(); _vm->_gyro->_dna._wonNim = true; _vm->_celer->drawBackgroundSprite(-1, -1, 1); // Show the settle with no lute on it. @@ -1645,10 +1645,10 @@ void Acci::doThat() { case Gyro::kObjectLute : _vm->_visa->displayScrollChain('U', 7); - if (_vm->_gyro->_whereIs[_vm->_gyro->kPeopleCwytalot - 150] == _vm->_gyro->_dna._room) + if (_vm->_gyro->_whereIs[Gyro::kPeopleCwytalot - 150] == _vm->_gyro->_dna._room) _vm->_visa->displayScrollChain('U', 10); - if (_vm->_gyro->_whereIs[_vm->_gyro->kPeopleDuLustie - 150] == _vm->_gyro->_dna._room) + if (_vm->_gyro->_whereIs[Gyro::kPeopleDuLustie - 150] == _vm->_gyro->_dna._room) _vm->_visa->displayScrollChain('U', 15); break; case 52: @@ -1671,7 +1671,7 @@ void Acci::doThat() { break; case kVerbCodeRing: if (isHolding()) { - if (_thing == _vm->_gyro->kObjectBell) { + if (_thing == Gyro::kObjectBell) { _vm->_scrolls->displayText("Ding, dong, ding, dong, ding, dong, ding, dong..."); if ((_vm->_gyro->_dna._bellsAreRinging) & (_vm->_gyro->setFlag('B'))) // \? are used to avoid that ??! is parsed as a trigraph @@ -1697,7 +1697,7 @@ void Acci::doThat() { case kVerbCodePee: if (_vm->_gyro->setFlag('P')) { _vm->_scrolls->displayText("Hmm, I don't think anyone will notice..."); - _vm->_timer->addTimer(4, _vm->_timer->kProcUrinate, _vm->_timer->kReasonGoToToilet); + _vm->_timer->addTimer(4, Timer::kProcUrinate, Timer::kReasonGoToToilet); } else _vm->_scrolls->displayText(Common::String("It would be ") + Scrolls::kControlItalic + "VERY" + Scrolls::kControlRoman + " unwise to do that here, Avvy!"); @@ -1721,7 +1721,7 @@ void Acci::doThat() { _vm->_animation->_sprites[1]._callEachStepFl = true; _vm->_animation->_sprites[1]._eachStepProc = _vm->_animation->kProcBackAndForth; _vm->_gyro->_dna._avariciusTalk = 14; - _vm->_timer->addTimer(177, _vm->_timer->kProcAvariciusTalks, _vm->_timer->kReasonAvariciusTalks); + _vm->_timer->addTimer(177, Timer::kProcAvariciusTalks, Timer::kReasonAvariciusTalks); } } else _vm->_scrolls->displayText("Nothing appears to happen..."); @@ -1784,13 +1784,13 @@ void Acci::doThat() { _vm->_celer->drawBackgroundSprite(-1, -1, 10); _vm->_gyro->_dna._malagauche = 177; - _vm->_timer->addTimer(27, _vm->_timer->kProcBuyDrinks, _vm->_timer->kReasonDrinks); + _vm->_timer->addTimer(27, Timer::kProcBuyDrinks, Timer::kReasonDrinks); break; case 52: examine(); break; // We have a right one here - buy Pepsi??! case Gyro::kObjectWine: - if (_vm->_gyro->_dna._objects[_vm->_gyro->kObjectWine - 1]) // We've already got the wine! + if (_vm->_gyro->_dna._objects[Gyro::kObjectWine - 1]) // We've already got the wine! _vm->_visa->displayScrollChain('D', 2); // 1 bottle's shufishent! else { if (_vm->_gyro->_dna._malagauche == 177) { // Already getting us one. @@ -1810,7 +1810,7 @@ void Acci::doThat() { _vm->_celer->drawBackgroundSprite(-1, -1, 10); _vm->_gyro->_dna._malagauche = 177; - _vm->_timer->addTimer(27, _vm->_timer->kProcBuyWine, _vm->_timer->kReasonDrinks); + _vm->_timer->addTimer(27, Timer::kProcBuyWine, Timer::kReasonDrinks); } break; } @@ -1820,8 +1820,8 @@ void Acci::doThat() { case r__outsideducks: if (_vm->_animation->inField(6)) { - if (_thing == _vm->_gyro->kObjectOnion) { - if (_vm->_gyro->_dna._objects[_vm->_gyro->kObjectOnion - 1]) + if (_thing == Gyro::kObjectOnion) { + if (_vm->_gyro->_dna._objects[Gyro::kObjectOnion - 1]) _vm->_visa->displayScrollChain('D', 10); // Not planning to juggle with the things! else if (_vm->_gyro->_dna._carryNum >= kCarryLimit) _vm->_scrolls->displayText("Before you ask, you remember that your hands are full."); @@ -1833,7 +1833,7 @@ void Acci::doThat() { _vm->_lucerna->incScore(3); } _vm->_gyro->decreaseMoney(3); // It costs thruppence. - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectOnion - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectOnion - 1] = true; _vm->_lucerna->refreshObjectList(); _vm->_gyro->_dna._boughtOnion = true; _vm->_gyro->_dna._rottenOnion = false; // It's OK when it leaves the stall! @@ -1854,9 +1854,9 @@ void Acci::doThat() { break; case kVerbCodeAttack: if ((_vm->_gyro->_dna._room == r__brummieroad) && - ((_person == 157) || (_thing == _vm->_gyro->kObjectCrossbow) || (_thing == _vm->_gyro->kObjectBolt)) + ((_person == 157) || (_thing == Gyro::kObjectCrossbow) || (_thing == Gyro::kObjectBolt)) && (_vm->_gyro->_whereIs[7] == _vm->_gyro->_dna._room)) { - switch (_vm->_gyro->_dna._objects[_vm->_gyro->kObjectBolt - 1] + _vm->_gyro->_dna._objects[_vm->_gyro->kObjectCrossbow - 1] * 2) { + switch (_vm->_gyro->_dna._objects[Gyro::kObjectBolt - 1] + _vm->_gyro->_dna._objects[Gyro::kObjectCrossbow - 1] * 2) { // 0 = neither, 1 = only bolt, 2 = only crossbow, 3 = both. case 0: _vm->_visa->displayScrollChain('Q', 10); @@ -1871,10 +1871,10 @@ void Acci::doThat() { case 3: _vm->_visa->displayScrollChain('Q', 11); _vm->_gyro->_dna._cwytalotGone = true; - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectBolt - 1] = false; - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectCrossbow - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectBolt - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectCrossbow - 1] = false; _vm->_lucerna->refreshObjectList(); - _vm->_gyro->_magics[11]._operation = _vm->_gyro->kMagicNothing; + _vm->_gyro->_magics[11]._operation = Gyro::kMagicNothing; _vm->_lucerna->incScore(7); _vm->_animation->_sprites[1].walkTo(2); _vm->_animation->_sprites[1]._vanishIfStill = true; @@ -1907,7 +1907,7 @@ void Acci::doThat() { else { _vm->_lucerna->incScore(4); _vm->_scrolls->displayText("The drawbridge opens!"); - _vm->_timer->addTimer(7, _vm->_timer->kProcOpenDrawbridge, _vm->_timer->kReasonDrawbridgeFalls); + _vm->_timer->addTimer(7, Timer::kProcOpenDrawbridge, Timer::kReasonDrawbridgeFalls); _vm->_gyro->_dna._drawbridgeOpen = 1; } } else @@ -1959,7 +1959,7 @@ void Acci::doThat() { _vm->_scrolls->displayText("Not with your head for heights, Avvy!"); break; case kVerbCodeJump: - _vm->_timer->addTimer(1, _vm->_timer->kProcJump, _vm->_timer->kReasonJumping); + _vm->_timer->addTimer(1, Timer::kProcJump, Timer::kReasonJumping); _vm->_gyro->_dna._userMovesAvvy = false; break; case kVerbCodeHiscores: @@ -2000,7 +2000,7 @@ void Acci::doThat() { _vm->_scrolls->displayText("You're already sitting!"); else { _vm->_animation->_sprites[0].walkTo(4); // Move Avvy to the place, and sit him down. - _vm->_timer->addTimer(1, _vm->_timer->kProcAvvySitDown, _vm->_timer->kReasonSittingDown); + _vm->_timer->addTimer(1, Timer::kProcAvvySitDown, Timer::kReasonSittingDown); } } else { // Default doodah. _vm->_lucerna->dusk(); diff --git a/engines/avalanche/animation.cpp b/engines/avalanche/animation.cpp index 9e73ea73c0..747f014dfb 100644 --- a/engines/avalanche/animation.cpp +++ b/engines/avalanche/animation.cpp @@ -470,66 +470,66 @@ void Animation::catacombMove(byte ped) { switch (here & 0xf) { // West. case 0: // no connection (wall) - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[4]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[4]._operation = Gyro::kMagicNothing; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 28); break; case 0x1: // no connection (wall + shield), - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[4]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[4]._operation = Gyro::kMagicNothing; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 28); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 29); // ...shield. break; case 0x2: // wall with door - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[4]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[4]._operation = Gyro::kMagicSpecial; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 28); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 30); // ...door. break; case 0x3: // wall with door and shield - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[4]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[4]._operation = Gyro::kMagicSpecial; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 28); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 30); // ...door, and... _vm->_celer->drawBackgroundSprite(-1, -1, 29); // ...shield. break; case 0x4: // no connection (wall + window), - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[4]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[4]._operation = Gyro::kMagicNothing; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 28); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 5); // ...window. break; case 0x5: // wall with door and window - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[4]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[4]._operation = Gyro::kMagicSpecial; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 28); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 30); // ...door, and... _vm->_celer->drawBackgroundSprite(-1, -1, 5); // ...window. break; case 0x6: // no connection (wall + torches), - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[4]._operation = _vm->_gyro->kMagicNothing; // No door. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[4]._operation = Gyro::kMagicNothing; // No door. _vm->_celer->drawBackgroundSprite(-1, -1, 28); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 7); // ...torches. break; case 0x7: // wall with door and torches - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[4]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[4]._operation = Gyro::kMagicSpecial; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 28); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 30); // ...door, and... _vm->_celer->drawBackgroundSprite(-1, -1, 7); // ...torches. break; case 0xf: // straight-through corridor. - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicNothing; // Sloping wall. - _vm->_gyro->_magics[2]._operation = _vm->_gyro->kMagicSpecial; // Straight wall. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicNothing; // Sloping wall. + _vm->_gyro->_magics[2]._operation = Gyro::kMagicSpecial; // Straight wall. break; } @@ -537,52 +537,52 @@ void Animation::catacombMove(byte ped) { switch ((here & 0xf0) >> 4) { // East case 0: // no connection (wall) - _vm->_gyro->_magics[4]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[5]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[6]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[4]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[5]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[6]._operation = Gyro::kMagicNothing; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 19); break; case 0x1: // no connection (wall + window), - _vm->_gyro->_magics[4]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[5]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[6]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[4]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[5]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[6]._operation = Gyro::kMagicNothing; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 19); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 20); // ...window. break; case 0x2: // wall with door - _vm->_gyro->_magics[4]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[5]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[6]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[4]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[5]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[6]._operation = Gyro::kMagicSpecial; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 19); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 21); // ...door. break; case 0x3: // wall with door and window - _vm->_gyro->_magics[4]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[5]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[6]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[4]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[5]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[6]._operation = Gyro::kMagicSpecial; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 19); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 20); // ...door, and... _vm->_celer->drawBackgroundSprite(-1, -1, 21); // ...window. break; case 0x6: // no connection (wall + torches), - _vm->_gyro->_magics[4]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[5]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[6]._operation = _vm->_gyro->kMagicNothing; // No door. + _vm->_gyro->_magics[4]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[5]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[6]._operation = Gyro::kMagicNothing; // No door. _vm->_celer->drawBackgroundSprite(-1, -1, 19); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 18); // ...torches. break; case 0x7: // wall with door and torches - _vm->_gyro->_magics[4]._operation = _vm->_gyro->kMagicBounce; // Sloping wall. - _vm->_gyro->_magics[5]._operation = _vm->_gyro->kMagicNothing; // Straight wall. - _vm->_gyro->_portals[6]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[4]._operation = Gyro::kMagicBounce; // Sloping wall. + _vm->_gyro->_magics[5]._operation = Gyro::kMagicNothing; // Straight wall. + _vm->_gyro->_portals[6]._operation = Gyro::kMagicSpecial; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 19); // Wall, plus... _vm->_celer->drawBackgroundSprite(-1, -1, 21); // ...door, and... _vm->_celer->drawBackgroundSprite(-1, -1, 18); // ...torches. break; case 0xf: // straight-through corridor. - _vm->_gyro->_magics[4]._operation = _vm->_gyro->kMagicNothing; // Sloping wall. - _vm->_gyro->_magics[5]._operation = _vm->_gyro->kMagicSpecial; // Straight wall. - _vm->_gyro->_portals[6]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[4]._operation = Gyro::kMagicNothing; // Sloping wall. + _vm->_gyro->_magics[5]._operation = Gyro::kMagicSpecial; // Straight wall. + _vm->_gyro->_portals[6]._operation = Gyro::kMagicNothing; // Door. break; } @@ -590,39 +590,39 @@ void Animation::catacombMove(byte ped) { switch ((here & 0xf00) >> 8) { // South case 0: // No connection. - _vm->_gyro->_magics[6]._operation = _vm->_gyro->kMagicBounce; - _vm->_gyro->_magics[11]._operation = _vm->_gyro->kMagicBounce; - _vm->_gyro->_magics[12]._operation = _vm->_gyro->kMagicBounce; + _vm->_gyro->_magics[6]._operation = Gyro::kMagicBounce; + _vm->_gyro->_magics[11]._operation = Gyro::kMagicBounce; + _vm->_gyro->_magics[12]._operation = Gyro::kMagicBounce; break; case 0x1: _vm->_celer->drawBackgroundSprite(-1, -1, 22); if ((xy_uint16 == 2051) && (_vm->_gyro->_dna._geidaFollows)) - _vm->_gyro->_magics[12]._operation = _vm->_gyro->kMagicExclaim; + _vm->_gyro->_magics[12]._operation = Gyro::kMagicExclaim; else - _vm->_gyro->_magics[12]._operation = _vm->_gyro->kMagicSpecial; // Right exit south. + _vm->_gyro->_magics[12]._operation = Gyro::kMagicSpecial; // Right exit south. - _vm->_gyro->_magics[6]._operation = _vm->_gyro->kMagicBounce; - _vm->_gyro->_magics[11]._operation = _vm->_gyro->kMagicBounce; + _vm->_gyro->_magics[6]._operation = Gyro::kMagicBounce; + _vm->_gyro->_magics[11]._operation = Gyro::kMagicBounce; break; case 0x2: _vm->_celer->drawBackgroundSprite(-1, -1, 23); - _vm->_gyro->_magics[6]._operation = _vm->_gyro->kMagicSpecial; // Middle exit south. - _vm->_gyro->_magics[11]._operation = _vm->_gyro->kMagicBounce; - _vm->_gyro->_magics[12]._operation = _vm->_gyro->kMagicBounce; + _vm->_gyro->_magics[6]._operation = Gyro::kMagicSpecial; // Middle exit south. + _vm->_gyro->_magics[11]._operation = Gyro::kMagicBounce; + _vm->_gyro->_magics[12]._operation = Gyro::kMagicBounce; break; case 0x3: _vm->_celer->drawBackgroundSprite(-1, -1, 24); - _vm->_gyro->_magics[11]._operation = _vm->_gyro->kMagicSpecial; // Left exit south. - _vm->_gyro->_magics[6]._operation = _vm->_gyro->kMagicBounce; - _vm->_gyro->_magics[12]._operation = _vm->_gyro->kMagicBounce; + _vm->_gyro->_magics[11]._operation = Gyro::kMagicSpecial; // Left exit south. + _vm->_gyro->_magics[6]._operation = Gyro::kMagicBounce; + _vm->_gyro->_magics[12]._operation = Gyro::kMagicBounce; break; } switch ((here & 0xf000) >> 12) { // North case 0: // No connection - _vm->_gyro->_magics[0]._operation = _vm->_gyro->kMagicBounce; - _vm->_gyro->_portals[3]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[0]._operation = Gyro::kMagicBounce; + _vm->_gyro->_portals[3]._operation = Gyro::kMagicNothing; // Door. break; // LEFT handles: #if 0 @@ -634,8 +634,8 @@ void Animation::catacombMove(byte ped) { #endif case 0x2: _vm->_celer->drawBackgroundSprite(-1, -1, 4); - _vm->_gyro->_magics[0]._operation = _vm->_gyro->kMagicBounce; // Middle exit north. - _vm->_gyro->_portals[3]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[0]._operation = Gyro::kMagicBounce; // Middle exit north. + _vm->_gyro->_portals[3]._operation = Gyro::kMagicSpecial; // Door. break; #if 0 case 0x3: @@ -652,8 +652,8 @@ void Animation::catacombMove(byte ped) { #endif case 0x5: _vm->_celer->drawBackgroundSprite(-1, -1, 3); - _vm->_gyro->_magics[0]._operation = _vm->_gyro->kMagicBounce; // Middle exit north. - _vm->_gyro->_portals[3]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_magics[0]._operation = Gyro::kMagicBounce; // Middle exit north. + _vm->_gyro->_portals[3]._operation = Gyro::kMagicSpecial; // Door. break; #if 0 case 0x6: @@ -673,26 +673,26 @@ void Animation::catacombMove(byte ped) { if (((here & 0xf000) >> 12) == 0x9) _vm->_celer->drawBackgroundSprite(-1, -1, 32); - _vm->_gyro->_magics[0]._operation = _vm->_gyro->kMagicSpecial; // Middle arch north. - _vm->_gyro->_portals[3]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[0]._operation = Gyro::kMagicSpecial; // Middle arch north. + _vm->_gyro->_portals[3]._operation = Gyro::kMagicNothing; // Door. } break; // DECORATIONS: case 0xd: // No connection + WINDOW - _vm->_gyro->_magics[0]._operation = _vm->_gyro->kMagicBounce; - _vm->_gyro->_portals[3]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[0]._operation = Gyro::kMagicBounce; + _vm->_gyro->_portals[3]._operation = Gyro::kMagicNothing; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 14); break; case 0xe: // No connection + TORCH - _vm->_gyro->_magics[0]._operation = _vm->_gyro->kMagicBounce; - _vm->_gyro->_portals[3]._operation = _vm->_gyro->kMagicNothing; // Door. + _vm->_gyro->_magics[0]._operation = Gyro::kMagicBounce; + _vm->_gyro->_portals[3]._operation = Gyro::kMagicNothing; // Door. _vm->_celer->drawBackgroundSprite(-1, -1, 8); break; // Recessed door: case 0xf: - _vm->_gyro->_magics[0]._operation = _vm->_gyro->kMagicNothing; // Door to Geida's room. + _vm->_gyro->_magics[0]._operation = Gyro::kMagicNothing; // Door to Geida's room. _vm->_celer->drawBackgroundSprite(-1, -1, 1); - _vm->_gyro->_portals[3]._operation = _vm->_gyro->kMagicSpecial; // Door. + _vm->_gyro->_portals[3]._operation = Gyro::kMagicSpecial; // Door. break; } @@ -741,7 +741,7 @@ void Animation::catacombMove(byte ped) { // This proc gets called whenever you touch a line defined as _vm->_gyro->special. void Animation::dawnDelay() { - _vm->_timer->addTimer(2, _vm->_timer->kProcDawnDelay, _vm->_timer->kReasonDawndelay); + _vm->_timer->addTimer(2, Timer::kProcDawnDelay, Timer::kReasonDawndelay); } void Animation::callSpecial(uint16 which) { @@ -749,17 +749,17 @@ void Animation::callSpecial(uint16 which) { case 1: // _vm->_gyro->special 1: Room 22: top of stairs. _vm->_celer->drawBackgroundSprite(-1, -1, 1); _vm->_gyro->_dna._brummieStairs = 1; - _vm->_gyro->_magics[9]._operation = _vm->_gyro->kMagicNothing; - _vm->_timer->addTimer(10, _vm->_timer->kProcStairs, _vm->_timer->kReasonBrummieStairs); + _vm->_gyro->_magics[9]._operation = Gyro::kMagicNothing; + _vm->_timer->addTimer(10, Timer::kProcStairs, Timer::kReasonBrummieStairs); stopWalking(); _vm->_gyro->_dna._userMovesAvvy = false; break; case 2: // _vm->_gyro->special 2: Room 22: bottom of stairs. _vm->_gyro->_dna._brummieStairs = 3; - _vm->_gyro->_magics[10]._operation = _vm->_gyro->kMagicNothing; - _vm->_gyro->_magics[11]._operation = _vm->_gyro->kMagicExclaim; + _vm->_gyro->_magics[10]._operation = Gyro::kMagicNothing; + _vm->_gyro->_magics[11]._operation = Gyro::kMagicExclaim; _vm->_gyro->_magics[11]._data = 5; - _vm->_gyro->_magics[3]._operation = _vm->_gyro->kMagicBounce; // Now works as planned! + _vm->_gyro->_magics[3]._operation = Gyro::kMagicBounce; // Now works as planned! stopWalking(); _vm->_visa->displayScrollChain('q', 26); _vm->_gyro->_dna._userMovesAvvy = true; @@ -784,13 +784,13 @@ void Animation::callSpecial(uint16 which) { case 4: // This is the ghost room link. _vm->_lucerna->dusk(); _sprites[0].turn(kDirRight); // you'll see this after we get back from bootstrap - _vm->_timer->addTimer(1, _vm->_timer->kProcGhostRoomPhew, _vm->_timer->kReasonGhostRoomPhew); + _vm->_timer->addTimer(1, Timer::kProcGhostRoomPhew, Timer::kReasonGhostRoomPhew); _vm->_enid->backToBootstrap(3); break; case 5: if (_vm->_gyro->_dna._friarWillTieYouUp) { // _vm->_gyro->special 5: Room 42: touched tree, and get tied up. - _vm->_gyro->_magics[4]._operation = _vm->_gyro->kMagicBounce; // Boundary effect is now working again. + _vm->_gyro->_magics[4]._operation = Gyro::kMagicBounce; // Boundary effect is now working again. _vm->_visa->displayScrollChain('q', 35); _sprites[0].remove(); //tr[1].vanishifstill:=true; @@ -801,8 +801,8 @@ void Animation::callSpecial(uint16 which) { _sprites[1].walkTo(3); _sprites[1]._vanishIfStill = true; _sprites[1]._doCheck = true; // One of them must have Check_Me switched on. - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleFriarTuck - 150] = 177; // Not here, then. - _vm->_timer->addTimer(364, _vm->_timer->kProcHangAround, _vm->_timer->kReasonHangingAround); + _vm->_gyro->_whereIs[Gyro::kPeopleFriarTuck - 150] = 177; // Not here, then. + _vm->_timer->addTimer(364, Timer::kProcHangAround, Timer::kReasonHangingAround); } break; case 6: // _vm->_gyro->special 6: fall down oubliette. @@ -810,17 +810,17 @@ void Animation::callSpecial(uint16 which) { _sprites[0]._moveX = 3; _sprites[0]._moveY = 0; _sprites[0]._facingDir = kDirRight; - _vm->_timer->addTimer(1, _vm->_timer->kProcFallDownOubliette, _vm->_timer->kReasonFallingDownOubliette); + _vm->_timer->addTimer(1, Timer::kProcFallDownOubliette, Timer::kReasonFallingDownOubliette); break; case 7: // _vm->_gyro->special 7: stop falling down oubliette. _sprites[0]._visible = false; - _vm->_gyro->_magics[9]._operation = _vm->_gyro->kMagicNothing; + _vm->_gyro->_magics[9]._operation = Gyro::kMagicNothing; stopWalking(); - _vm->_timer->loseTimer(_vm->_timer->kReasonFallingDownOubliette); + _vm->_timer->loseTimer(Timer::kReasonFallingDownOubliette); //_vm->_lucerna->mblit(12, 80, 38, 160, 3, 0); //_vm->_lucerna->mblit(12, 80, 38, 160, 3, 1); _vm->_scrolls->displayText("Oh dear, you seem to be down the bottom of an oubliette."); - _vm->_timer->addTimer(200, _vm->_timer->kProcMeetAvaroid, _vm->_timer->kReasonMeetingAvaroid); + _vm->_timer->addTimer(200, Timer::kProcMeetAvaroid, Timer::kReasonMeetingAvaroid); break; case 8: // _vm->_gyro->special 8: leave du Lustie's room. if ((_vm->_gyro->_dna._geidaFollows) && (!_vm->_gyro->_dna._lustieIsAsleep)) { @@ -838,12 +838,12 @@ void Animation::callSpecial(uint16 which) { _sprites[1].walkTo(4); // She walks to somewhere... _sprites[0].remove(); // Lose Avvy. _vm->_gyro->_dna._userMovesAvvy = false; - _vm->_timer->addTimer(40, _vm->_timer->kProcRobinHoodAndGeida, _vm->_timer->kReasonRobinHoodAndGeida); + _vm->_timer->addTimer(40, Timer::kProcRobinHoodAndGeida, Timer::kReasonRobinHoodAndGeida); break; case 10: // _vm->_gyro->special 10: transfer north in catacombs. if ((_vm->_gyro->_dna._catacombX == 4) && (_vm->_gyro->_dna._catacombY == 1)) { // Into Geida's room. - if (_vm->_gyro->_dna._objects[_vm->_gyro->kObjectKey - 1]) + if (_vm->_gyro->_dna._objects[Gyro::kObjectKey - 1]) _vm->_visa->displayScrollChain('q', 62); else { _vm->_visa->displayScrollChain('q', 61); @@ -1083,7 +1083,7 @@ void Animation::arrowProcs(byte tripnum) { _vm->_lucerna->gameOver(); _vm->_gyro->_dna._userMovesAvvy = false; // Stop the user from moving him. - _vm->_timer->addTimer(55, _vm->_timer->kProcNaughtyDuke, _vm->_timer->kReasonNaughtyDuke); + _vm->_timer->addTimer(55, Timer::kProcNaughtyDuke, Timer::kReasonNaughtyDuke); } } else { // Arrow has hit the wall! _sprites[tripnum].remove(); // Deallocate the arrow. diff --git a/engines/avalanche/avalanche.cpp b/engines/avalanche/avalanche.cpp index 3a952192cc..cdd6b7c3ab 100644 --- a/engines/avalanche/avalanche.cpp +++ b/engines/avalanche/avalanche.cpp @@ -525,10 +525,6 @@ void AvalancheEngine::bFlightOn() { _storage._skellern = kReset; // setintvec(0x1c, &b_flight); } -void AvalancheEngine::run(Common::String what, bool withJsb, bool withBflight, Elm how) { - warning("STUB: run(%s)", what.c_str()); - // Probably there'll be no need of this function, as all *.AVX-es will become classes. -} void AvalancheEngine::getArguments() { // This function should mess around with command line arguments, @@ -600,6 +596,11 @@ Common::Error AvalancheEngine::run() { } #if 0 +void AvalancheEngine::run(Common::String what, bool withJsb, bool withBflight, Elm how) { + warning("STUB: run(%s)", what.c_str()); + // Probably there'll be no need of this function, as all *.AVX-es will become classes. +} + void AvalancheEngine::bFlightOff() { // setintvec(0x1c, old_1c); } diff --git a/engines/avalanche/avalanche.h b/engines/avalanche/avalanche.h index d6327521b6..69c157fdbb 100644 --- a/engines/avalanche/avalanche.h +++ b/engines/avalanche/avalanche.h @@ -126,10 +126,6 @@ private: AvalancheConsole *_console; Common::Platform _platform; - // From bootstrp: - - enum Elm {kNormal, kMusical, kElmpoyten, kRegi}; - static const int16 kRunShootemup = 1, kRunDosshell = 2, kRunGhostroom = 3, kRunGolden = 4; static const char kRuncodes[2][3]; static const int16 kReset = 0; @@ -146,19 +142,22 @@ private: bool _zoomy; void bFlightOn(); - void run(Common::String what, bool withJsb, bool withBflight, Elm how); void getArguments(); void getSlope(); void callMenu(); void runAvalot(); #if 0 + // From bootstrp: + enum Elm {kNormal, kMusical, kElmpoyten, kRegi}; + Common::String _demoArgs, _argsWithNoFilename; byte _originalMode; byte *_old1c; Common::String _segofs; int32 _soundcard, _speed, _baseaddr, _irq, _dma; + void run(Common::String what, bool withJsb, bool withBflight, Elm how); void bFlightOff(); Common::String elmToStr(Elm how); bool keyPressed(); diff --git a/engines/avalanche/avalot.cpp b/engines/avalanche/avalot.cpp index 287f8443b3..af0079099d 100644 --- a/engines/avalanche/avalot.cpp +++ b/engines/avalanche/avalot.cpp @@ -170,7 +170,7 @@ void Avalot::setup() { int16 loadSlot = Common::ConfigManager::instance().getInt("save_slot"); if (loadSlot >= 0) { _vm->_gyro->_thinks = 2; // You always have money. - _vm->_lucerna->thinkAbout(_vm->_gyro->kObjectMoney, Gyro::kThing); + _vm->_lucerna->thinkAbout(Gyro::kObjectMoney, Gyro::kThing); _vm->loadGame(loadSlot); } else { @@ -179,7 +179,7 @@ void Avalot::setup() { _vm->_gyro->_soundFx = ! _vm->_gyro->_soundFx; _vm->_lucerna->fxToggle(); - _vm->_lucerna->thinkAbout(_vm->_gyro->kObjectMoney, Gyro::kThing); + _vm->_lucerna->thinkAbout(Gyro::kObjectMoney, Gyro::kThing); _vm->_visa->displayScrollChain('q', 83); // Info on the game, etc. } diff --git a/engines/avalanche/dropdown2.cpp b/engines/avalanche/dropdown2.cpp index 12af639ab7..0a5fe9f4d3 100644 --- a/engines/avalanche/dropdown2.cpp +++ b/engines/avalanche/dropdown2.cpp @@ -503,7 +503,7 @@ void Dropdown::setupMenuWith() { // We disable the "give" option if: (a), you haven't selected anybody, (b), the _person you've selected isn't in the room, // or (c), the _person you've selected is YOU! - if ((_vm->_gyro->_lastPerson == _vm->_gyro->kPeopleAvalot) || (_vm->_gyro->_lastPerson == _vm->_acci->kNothing) + if ((_vm->_gyro->_lastPerson == Gyro::kPeopleAvalot) || (_vm->_gyro->_lastPerson == _vm->_acci->kNothing) || (_vm->_gyro->_whereIs[_vm->_gyro->_lastPerson - 150] != _vm->_gyro->_dna._room)) _activeMenuItem.setupOption("Give to...", 'G', "", false); // Not here. else { @@ -528,7 +528,7 @@ void Dropdown::setupMenuWith() { break; case Gyro::kPeopleMalagauche: { bool isSober = !_vm->_gyro->_dna._teetotal; - _activeMenuItem.setupOption("Buy some wine", 'w', "", !_vm->_gyro->_dna._objects[_vm->_gyro->kObjectWine - 1]); + _activeMenuItem.setupOption("Buy some wine", 'w', "", !_vm->_gyro->_dna._objects[Gyro::kObjectWine - 1]); _activeMenuItem.setupOption("Buy some beer", 'b', "", isSober); _activeMenuItem.setupOption("Buy some whisky", 'h', "", isSober); _activeMenuItem.setupOption("Buy some cider", 'c', "", isSober); @@ -537,7 +537,7 @@ void Dropdown::setupMenuWith() { } break; case Gyro::kPeopleTrader: { - _activeMenuItem.setupOption("Buy an onion", 'o', "", !_vm->_gyro->_dna._objects[_vm->_gyro->kObjectOnion - 1]); + _activeMenuItem.setupOption("Buy an onion", 'o', "", !_vm->_gyro->_dna._objects[Gyro::kObjectOnion - 1]); _vm->_gyro->_verbStr = _vm->_gyro->_verbStr + 105; } break; diff --git a/engines/avalanche/enid2.cpp b/engines/avalanche/enid2.cpp index f6e22dfc59..a59db04a9f 100644 --- a/engines/avalanche/enid2.cpp +++ b/engines/avalanche/enid2.cpp @@ -274,7 +274,7 @@ void Enid::ednaReload() { _vm->_lucerna->majorRedraw(); - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleAvalot - 150] = _vm->_gyro->_dna._room; + _vm->_gyro->_whereIs[Gyro::kPeopleAvalot - 150] = _vm->_gyro->_dna._room; _vm->_gyro->_alive = true; diff --git a/engines/avalanche/lucerna2.cpp b/engines/avalanche/lucerna2.cpp index 041236c73b..ccb85b49c0 100644 --- a/engines/avalanche/lucerna2.cpp +++ b/engines/avalanche/lucerna2.cpp @@ -349,21 +349,21 @@ void Lucerna::exitRoom(byte x) { switch (x) { case r__spludwicks: - _vm->_timer->loseTimer(_vm->_timer->kReasonAvariciusTalks); + _vm->_timer->loseTimer(Timer::kReasonAvariciusTalks); _vm->_gyro->_dna._avariciusTalk = 0; // He doesn't HAVE to be talking for this to work. It just deletes it IF it exists. break; case r__bridge: if (_vm->_gyro->_dna._drawbridgeOpen > 0) { _vm->_gyro->_dna._drawbridgeOpen = 4; // Fully open. - _vm->_timer->loseTimer(_vm->_timer->kReasonDrawbridgeFalls); + _vm->_timer->loseTimer(Timer::kReasonDrawbridgeFalls); } break; case r__outsidecardiffcastle: - _vm->_timer->loseTimer(_vm->_timer->kReasonCardiffsurvey); + _vm->_timer->loseTimer(Timer::kReasonCardiffsurvey); break; case r__robins: - _vm->_timer->loseTimer(_vm->_timer->kReasonGettingTiedUp); + _vm->_timer->loseTimer(Timer::kReasonGettingTiedUp); break; } @@ -398,14 +398,14 @@ void Lucerna::enterNewTown() { _vm->_gyro->_dna._spludwickAtHome = true; _vm->_gyro->_dna._crapulusWillTell = false; } - if (_vm->_gyro->_dna._boxContent == _vm->_gyro->kObjectWine) + if (_vm->_gyro->_dna._boxContent == Gyro::kObjectWine) _vm->_gyro->_dna._wineState = 3; // Vinegar } break; } if (_vm->_gyro->_dna._room != r__outsideducks) { - if ((_vm->_gyro->_dna._objects[_vm->_gyro->kObjectOnion - 1]) && !(_vm->_gyro->_dna._onionInVinegar)) + if ((_vm->_gyro->_dna._objects[Gyro::kObjectOnion - 1]) && !(_vm->_gyro->_dna._onionInVinegar)) _vm->_gyro->_dna._rottenOnion = true; // You're holding the onion } } @@ -434,10 +434,10 @@ void Lucerna::enterRoom(byte room, byte ped) { if ((_vm->_gyro->_dna._roomCount[room] == 0) && (! _vm->_gyro->setFlag('S'))) incScore(1); - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleAvalot - 150] = _vm->_gyro->_dna._room; + _vm->_gyro->_whereIs[Gyro::kPeopleAvalot - 150] = _vm->_gyro->_dna._room; if (_vm->_gyro->_dna._geidaFollows) - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleGeida - 150] = room; + _vm->_gyro->_whereIs[Gyro::kPeopleGeida - 150] = room; _vm->_gyro->_roomTime = 0; @@ -451,7 +451,7 @@ void Lucerna::enterRoom(byte room, byte ped) { if (_vm->_gyro->_dna._avvyInBed) { _vm->_celer->drawBackgroundSprite(-1, -1, 3); _vm->_graphics->refreshBackground(); - _vm->_timer->addTimer(100, _vm->_timer->kProcArkataShouts, _vm->_timer->kReasonArkataShouts); + _vm->_timer->addTimer(100, Timer::kProcArkataShouts, Timer::kReasonArkataShouts); } break; @@ -459,7 +459,7 @@ void Lucerna::enterRoom(byte room, byte ped) { if (ped > 0) { if (! _vm->_gyro->_dna._talkedToCrapulus) { - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleCrapulus - 150] = r__outsideyours; + _vm->_gyro->_whereIs[Gyro::kPeopleCrapulus - 150] = r__outsideyours; _vm->_animation->_sprites[1].init(8, false, _vm->_animation); // load Crapulus if (_vm->_gyro->_dna._roomCount[r__outsideyours] == 1) { @@ -473,13 +473,13 @@ void Lucerna::enterRoom(byte room, byte ped) { _vm->_animation->_sprites[1]._callEachStepFl = true; _vm->_animation->_sprites[1]._eachStepProc = _vm->_animation->kProcFaceAvvy; // He always faces Avvy. - } else _vm->_gyro->_whereIs[_vm->_gyro->kPeopleCrapulus - 150] = r__nowhere; + } else _vm->_gyro->_whereIs[Gyro::kPeopleCrapulus - 150] = r__nowhere; if (_vm->_gyro->_dna._crapulusWillTell) { _vm->_animation->_sprites[1].init(8, false, _vm->_animation); _vm->_animation->appearPed(2, 2); _vm->_animation->_sprites[1].walkTo(4); - _vm->_timer->addTimer(20, _vm->_timer->kProcCrapulusSpludOut, _vm->_timer->kReasonCrapulusSaysSpludwickOut); + _vm->_timer->addTimer(20, Timer::kProcCrapulusSpludOut, Timer::kReasonCrapulusSaysSpludwickOut); _vm->_gyro->_dna._crapulusWillTell = false; } } @@ -487,7 +487,7 @@ void Lucerna::enterRoom(byte room, byte ped) { case r__outsidespludwicks: if ((_vm->_gyro->_dna._roomCount[r__outsidespludwicks] == 1) && (ped == 1)) { - _vm->_timer->addTimer(20, _vm->_timer->kProcBang, _vm->_timer->kReasonExplosion); + _vm->_timer->addTimer(20, Timer::kProcBang, Timer::kReasonExplosion); _vm->_gyro->_dna._spludwickAtHome = true; } break; @@ -512,14 +512,14 @@ void Lucerna::enterRoom(byte room, byte ped) { if (_vm->_gyro->_dna._geidaFollows) putGeidaAt(5, ped); if (_vm->_gyro->_dna._cwytalotGone) { - _vm->_gyro->_magics[kColorLightred - 1]._operation = _vm->_gyro->kMagicNothing; - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleCwytalot - 150] = r__nowhere; + _vm->_gyro->_magics[kColorLightred - 1]._operation = Gyro::kMagicNothing; + _vm->_gyro->_whereIs[Gyro::kPeopleCwytalot - 150] = r__nowhere; } else { if (ped > 0) { _vm->_animation->_sprites[1].init(4, false, _vm->_animation); // 4 = Cwytalot _vm->_animation->_sprites[1]._callEachStepFl = true; _vm->_animation->_sprites[1]._eachStepProc = _vm->_animation->kProcFollowAvvyY; - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleCwytalot - 150] = r__brummieroad; + _vm->_gyro->_whereIs[Gyro::kPeopleCwytalot - 150] = r__brummieroad; if (_vm->_gyro->_dna._roomCount[r__brummieroad] == 1) { // First time here... _vm->_animation->appearPed(2, 2); // He appears on the right of the screen... @@ -542,7 +542,7 @@ void Lucerna::enterRoom(byte room, byte ped) { _vm->_animation->_sprites[1]._vanishIfStill = true; _vm->_gyro->_dna._passedCwytalotInHerts = true; // _vm->_gyro->whereis[#157] = r__Nowhere; // can we fit this in? - _vm->_timer->addTimer(20, _vm->_timer->kProcCwytalotInHerts, _vm->_timer->kReasonCwytalotInHerts); + _vm->_timer->addTimer(20, Timer::kProcCwytalotInHerts, Timer::kReasonCwytalotInHerts); } break; @@ -550,7 +550,7 @@ void Lucerna::enterRoom(byte room, byte ped) { if (_vm->_gyro->_dna._drawbridgeOpen == 4) { // open _vm->_celer->drawBackgroundSprite(-1, -1, 3); // Position of drawbridge _vm->_graphics->refreshBackground(); - _vm->_gyro->_magics[kColorGreen - 1]._operation = _vm->_gyro->kMagicNothing; // You may enter the drawbridge. + _vm->_gyro->_magics[kColorGreen - 1]._operation = Gyro::kMagicNothing; // You may enter the drawbridge. } if (_vm->_gyro->_dna._geidaFollows) putGeidaAt(ped + 3, ped); // load Geida @@ -563,13 +563,13 @@ void Lucerna::enterRoom(byte room, byte ped) { _vm->_animation->_sprites[1].init(6, false, _vm->_animation); _vm->_animation->appearPed(2, 2); _vm->_animation->_sprites[1].walkTo(3); - _vm->_timer->addTimer(36, _vm->_timer->kProcGetTiedUp, _vm->_timer->kReasonGettingTiedUp); + _vm->_timer->addTimer(36, Timer::kProcGetTiedUp, Timer::kReasonGettingTiedUp); } } if (_vm->_gyro->_dna._beenTiedUp) { - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleRobinHood - 150] = 0; - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleFriarTuck - 150] = 0; + _vm->_gyro->_whereIs[Gyro::kPeopleRobinHood - 150] = 0; + _vm->_gyro->_whereIs[Gyro::kPeopleFriarTuck - 150] = 0; } if (_vm->_gyro->_dna._tiedUp) @@ -587,17 +587,17 @@ void Lucerna::enterRoom(byte room, byte ped) { _vm->_animation->_sprites[1].init(9, false, _vm->_animation); _vm->_animation->appearPed(2, 2); _vm->_animation->_sprites[1].walkTo(3); - _vm->_timer->addTimer(47, _vm->_timer->kProcCardiffSurvey, _vm->_timer->kReasonCardiffsurvey); + _vm->_timer->addTimer(47, Timer::kProcCardiffSurvey, Timer::kReasonCardiffsurvey); } break; case 5 : - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicNothing; + _vm->_gyro->_magics[1]._operation = Gyro::kMagicNothing; break; // You've answered ALL his questions. => nothing happens. default: { // You've answered SOME of his questions. _vm->_animation->_sprites[1].init(9, false, _vm->_animation); _vm->_animation->appearPed(2, 3); _vm->_animation->_sprites[1]._facingDir = Animation::kDirRight; - _vm->_timer->addTimer(3, _vm->_timer->kProcCardiffReturn, _vm->_timer->kReasonCardiffsurvey); + _vm->_timer->addTimer(3, Timer::kProcCardiffReturn, Timer::kReasonCardiffsurvey); } } if (_vm->_gyro->_dna._cardiffQuestionNum < 5) @@ -614,9 +614,9 @@ void Lucerna::enterRoom(byte room, byte ped) { //setactivepage(1 - cp); { - if ((_vm->_gyro->_dna._objects[_vm->_gyro->kObjectWine - 1]) && (_vm->_gyro->_dna._wineState != 3)) { + if ((_vm->_gyro->_dna._objects[Gyro::kObjectWine - 1]) && (_vm->_gyro->_dna._wineState != 3)) { _vm->_visa->displayScrollChain('q', 9); // Don't want to waste the wine! - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectWine - 1] = false; + _vm->_gyro->_dna._objects[Gyro::kObjectWine - 1] = false; refreshObjectList(); } } @@ -665,10 +665,10 @@ void Lucerna::enterRoom(byte room, byte ped) { case r__lustiesroom: _vm->_gyro->_dna._dogFoodPos = 1; // Actually, du Lustie pos. if (_vm->_animation->_sprites[0]._id == 0) // Avvy in his normal clothes - _vm->_timer->addTimer(3, _vm->_timer->kProcCallsGuards, _vm->_timer->kReasonDuLustieTalks); + _vm->_timer->addTimer(3, Timer::kProcCallsGuards, Timer::kReasonDuLustieTalks); else if (! _vm->_gyro->_dna._enteredLustiesRoomAsMonk) // already // Presumably, Avvy dressed as a monk. - _vm->_timer->addTimer(3, _vm->_timer->kProcGreetsMonk, _vm->_timer->kReasonDuLustieTalks); + _vm->_timer->addTimer(3, Timer::kProcGreetsMonk, Timer::kReasonDuLustieTalks); if (_vm->_gyro->_dna._geidaFollows) { putGeidaAt(5, ped); @@ -685,8 +685,8 @@ void Lucerna::enterRoom(byte room, byte ped) { _vm->_celer->drawBackgroundSprite(-1, -1, 2); _vm->_graphics->refreshBackground(); _vm->_celer->drawBackgroundSprite(-1, -1, 4); - _vm->_gyro->_magics[kColorBrown - 1]._operation = _vm->_gyro->kMagicNothing; - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleJacques - 150] = 0; + _vm->_gyro->_magics[kColorBrown - 1]._operation = Gyro::kMagicNothing; + _vm->_gyro->_whereIs[Gyro::kPeopleJacques - 150] = 0; } if (ped != 0) { _vm->_celer->drawBackgroundSprite(-1, -1, 6); @@ -1022,7 +1022,7 @@ void Lucerna::fxToggle() { void Lucerna::refreshObjectList() { _vm->_gyro->_dna._carryNum = 0; if (_vm->_gyro->_thinkThing && !_vm->_gyro->_dna._objects[_vm->_gyro->_thinks - 1]) - thinkAbout(_vm->_gyro->kObjectMoney, Gyro::kThing); // you always have money + thinkAbout(Gyro::kObjectMoney, Gyro::kThing); // you always have money for (byte i = 0; i < kObjectNum; i++) { if (_vm->_gyro->_dna._objects[i]) { @@ -1208,7 +1208,7 @@ void Lucerna::gameOver() { _vm->_animation->_sprites[0]._stepNum = 0; _vm->_animation->_sprites[0].appear(sx, sy, 0); - _vm->_timer->addTimer(3, _vm->_timer->kProcAvalotFalls, _vm->_timer->kReasonFallingOver); + _vm->_timer->addTimer(3, Timer::kProcAvalotFalls, Timer::kReasonFallingOver); _vm->_gyro->_alive = false; } diff --git a/engines/avalanche/scrolls2.cpp b/engines/avalanche/scrolls2.cpp index abc6ebdbf6..1fd2617865 100644 --- a/engines/avalanche/scrolls2.cpp +++ b/engines/avalanche/scrolls2.cpp @@ -220,7 +220,7 @@ void Scrolls::scrollModeMusic() { setReadyLight(0); _vm->_gyro->_seeScroll = false; - _vm->_timer->addTimer(8, _vm->_timer->kProcJacquesWakesUp, _vm->_timer->kReasonJacquesWakingUp); + _vm->_timer->addTimer(8, Timer::kProcJacquesWakesUp, Timer::kReasonJacquesWakingUp); warning("STUB: Scrolls::music_scroll()"); return; #if 0 diff --git a/engines/avalanche/sequence2.cpp b/engines/avalanche/sequence2.cpp index 600a3cae4d..b5eb6a4d15 100644 --- a/engines/avalanche/sequence2.cpp +++ b/engines/avalanche/sequence2.cpp @@ -69,8 +69,8 @@ void Sequence::thenFlip(byte where, byte ped) { } void Sequence::startToClose() { - _vm->_timer->loseTimer(_vm->_timer->kReasonSequencer); - _vm->_timer->addTimer(7, _vm->_timer->kProcSequence, _vm->_timer->kReasonSequencer); + _vm->_timer->loseTimer(Timer::kReasonSequencer); + _vm->_timer->addTimer(7, Timer::kProcSequence, Timer::kReasonSequencer); } void Sequence::startToOpen() { diff --git a/engines/avalanche/timer.cpp b/engines/avalanche/timer.cpp index 973b1d3210..c2fa073160 100644 --- a/engines/avalanche/timer.cpp +++ b/engines/avalanche/timer.cpp @@ -237,7 +237,7 @@ void Timer::openDrawbridge() { _vm->_celer->drawBackgroundSprite(-1, -1, _vm->_gyro->_dna._drawbridgeOpen - 1); if (_vm->_gyro->_dna._drawbridgeOpen == 4) - _vm->_gyro->_magics[1]._operation = _vm->_gyro->kMagicNothing; // You may enter the drawbridge. + _vm->_gyro->_magics[1]._operation = Gyro::kMagicNothing; // You may enter the drawbridge. else addTimer(7, kProcOpenDrawbridge, kReasonDrawbridgeFalls); } @@ -278,9 +278,9 @@ void Timer::stairs() { _vm->_animation->_sprites[0].walkTo(4); _vm->_celer->drawBackgroundSprite(-1, -1, 2); _vm->_gyro->_dna._brummieStairs = 2; - _vm->_gyro->_magics[10]._operation = _vm->_gyro->kMagicSpecial; + _vm->_gyro->_magics[10]._operation = Gyro::kMagicSpecial; _vm->_gyro->_magics[10]._data = 2; // Reached the bottom of the stairs. - _vm->_gyro->_magics[3]._operation = _vm->_gyro->kMagicNothing; // Stop them hitting the sides (or the game will hang.) + _vm->_gyro->_magics[3]._operation = Gyro::kMagicNothing; // Stop them hitting the sides (or the game will hang.) } void Timer::cardiffSurvey() { @@ -318,14 +318,14 @@ void Timer::getTiedUp() { void Timer::getTiedUp2() { _vm->_animation->_sprites[0].walkTo(4); _vm->_animation->_sprites[1].walkTo(5); - _vm->_gyro->_magics[3]._operation = _vm->_gyro->kMagicNothing; // No effect when you touch the boundaries. + _vm->_gyro->_magics[3]._operation = Gyro::kMagicNothing; // No effect when you touch the boundaries. _vm->_gyro->_dna._friarWillTieYouUp = true; } void Timer::hangAround() { _vm->_animation->_sprites[1]._doCheck = false; _vm->_animation->_sprites[0].init(7, true, _vm->_animation); // Robin Hood - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleRobinHood - 150] = r__robins; + _vm->_gyro->_whereIs[Gyro::kPeopleRobinHood - 150] = r__robins; _vm->_animation->appearPed(1, 2); _vm->_visa->displayScrollChain('q', 39); _vm->_animation->_sprites[0].walkTo(7); @@ -336,7 +336,7 @@ void Timer::hangAround2() { _vm->_visa->displayScrollChain('q', 40); _vm->_animation->_sprites[1]._vanishIfStill = false; _vm->_animation->_sprites[1].walkTo(4); - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleFriarTuck - 150] = r__robins; + _vm->_gyro->_whereIs[Gyro::kPeopleFriarTuck - 150] = r__robins; _vm->_visa->displayScrollChain('q', 41); _vm->_animation->_sprites[0].remove(); _vm->_animation->_sprites[1].remove(); // Get rid of Robin Hood and Friar Tuck. @@ -357,7 +357,7 @@ void Timer::afterTheShootemup() { _vm->_animation->_sprites[0].init(0, true, _vm->_animation); // Avalot. _vm->_animation->appearPed(1, 2); _vm->_gyro->_dna._userMovesAvvy = true; - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectCrossbow - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectCrossbow - 1] = true; _vm->_lucerna->refreshObjectList(); // Same as the added line above: TODO: Remove it later!!! @@ -396,12 +396,12 @@ void Timer::jacquesWakesUp() { case 2 : // Going through the door. _vm->_celer->drawBackgroundSprite(-1, -1, 2); // Not on the floor. _vm->_celer->drawBackgroundSprite(-1, -1, 3); // But going through the door. - _vm->_gyro->_magics[5]._operation = _vm->_gyro->kMagicNothing; // You can't wake him up now. + _vm->_gyro->_magics[5]._operation = Gyro::kMagicNothing; // You can't wake him up now. break; case 3 : // Gone through the door. _vm->_celer->drawBackgroundSprite(-1, -1, 2); // Not on the floor, either. _vm->_celer->drawBackgroundSprite(-1, -1, 4); // He's gone... so the door's open. - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleJacques - 150] = 0; // Gone! + _vm->_gyro->_whereIs[Gyro::kPeopleJacques - 150] = 0; // Gone! break; } @@ -488,7 +488,7 @@ void Timer::jump() { else { _vm->_celer->drawBackgroundSprite(-1, -1, 2); _vm->_gyro->_dna._arrowInTheDoor = false; // You've got it. - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectBolt - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectBolt - 1] = true; _vm->_lucerna->refreshObjectList(); _vm->_visa->displayScrollChain('q', 50); _vm->_lucerna->incScore(3); @@ -521,7 +521,7 @@ void Timer::buyWine() { _vm->_visa->displayScrollChain('D', 1); // It'll be thruppence. if (_vm->_gyro->decreaseMoney(3)) { _vm->_visa->displayScrollChain('D', 4); // You paid up. - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectWine - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectWine - 1] = true; _vm->_lucerna->refreshObjectList(); _vm->_gyro->_dna._wineState = 1; // OK Wine. } @@ -538,7 +538,7 @@ void Timer::greetsMonk() { } void Timer::fallDownOubliette() { - _vm->_gyro->_magics[8]._operation = _vm->_gyro->kMagicNothing; + _vm->_gyro->_magics[8]._operation = Gyro::kMagicNothing; _vm->_animation->_sprites[0]._moveY++; // Increments dx/dy! _vm->_animation->_sprites[0]._y += _vm->_animation->_sprites[0]._moveY; // Dowwwn we go... addTimer(3, kProcFallDownOubliette, kReasonFallingDownOubliette); diff --git a/engines/avalanche/visa2.cpp b/engines/avalanche/visa2.cpp index b356aef7c8..dfc99d4cd5 100644 --- a/engines/avalanche/visa2.cpp +++ b/engines/avalanche/visa2.cpp @@ -165,9 +165,9 @@ void Visa::talkTo(byte whom) { if (_vm->_gyro->_subjectNum == 0) { switch (whom) { case Gyro::kPeopleSpludwick: - if ((_vm->_gyro->_dna._lustieIsAsleep) & (!_vm->_gyro->_dna._objects[_vm->_gyro->kObjectPotion - 1])) { + if ((_vm->_gyro->_dna._lustieIsAsleep) & (!_vm->_gyro->_dna._objects[Gyro::kObjectPotion - 1])) { displayScrollChain('q', 68); - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectPotion - 1] = true; + _vm->_gyro->_dna._objects[Gyro::kObjectPotion - 1] = true; _vm->_lucerna->refreshObjectList(); _vm->_lucerna->incScore(3); return; @@ -241,7 +241,7 @@ void Visa::talkTo(byte whom) { break; } // On a subject. Is there any reason to block it? - } else if ((whom == _vm->_gyro->kPeopleAyles) && (!_vm->_gyro->_dna._aylesIsAwake)) { + } else if ((whom == Gyro::kPeopleAyles) && (!_vm->_gyro->_dna._aylesIsAwake)) { displayScrollChain('q', 43); // He's fast asleep! return; } @@ -269,12 +269,12 @@ void Visa::talkTo(byte whom) { if (!_noError) displayScrollChain('n', whom); // File not found! - if ((_vm->_gyro->_subjectNum == 0) && ((whom + 149) == _vm->_gyro->kPeopleCrapulus)) { // Crapulus: get the badge - first time only - _vm->_gyro->_dna._objects[_vm->_gyro->kObjectBadge - 1] = true; + if ((_vm->_gyro->_subjectNum == 0) && ((whom + 149) == Gyro::kPeopleCrapulus)) { // Crapulus: get the badge - first time only + _vm->_gyro->_dna._objects[Gyro::kObjectBadge - 1] = true; _vm->_lucerna->refreshObjectList(); displayScrollChain('q', 1); // Circular from Cardiff. _vm->_gyro->_dna._talkedToCrapulus = true; - _vm->_gyro->_whereIs[_vm->_gyro->kPeopleCrapulus - 150] = 177; // Crapulus walks off. + _vm->_gyro->_whereIs[Gyro::kPeopleCrapulus - 150] = 177; // Crapulus walks off. _vm->_animation->_sprites[1]._vanishIfStill = true; _vm->_animation->_sprites[1].walkTo(3); // Walks away. |