diff options
-rw-r--r-- | engines/mads/nebular/nebular_scenes.cpp | 2 | ||||
-rw-r--r-- | engines/mads/nebular/nebular_scenes3.cpp | 52 | ||||
-rw-r--r-- | engines/mads/nebular/nebular_scenes3.h | 12 |
3 files changed, 66 insertions, 0 deletions
diff --git a/engines/mads/nebular/nebular_scenes.cpp b/engines/mads/nebular/nebular_scenes.cpp index 00b49d014f..46a5e89bdf 100644 --- a/engines/mads/nebular/nebular_scenes.cpp +++ b/engines/mads/nebular/nebular_scenes.cpp @@ -142,6 +142,8 @@ SceneLogic *SceneFactory::createScene(MADSEngine *vm) { return new Scene354(vm); case 357: return new Scene357(vm); + case 358: + return new Scene358(vm); // Scene group #8 case 804: diff --git a/engines/mads/nebular/nebular_scenes3.cpp b/engines/mads/nebular/nebular_scenes3.cpp index e7f1dda703..647ea67f06 100644 --- a/engines/mads/nebular/nebular_scenes3.cpp +++ b/engines/mads/nebular/nebular_scenes3.cpp @@ -4557,5 +4557,57 @@ void Scene357::actions() { /*------------------------------------------------------------------------*/ +void Scene358::setup() { + setPlayerSpritesPrefix(); + setAAName(); +} + +void Scene358::enter() { + _globals._spriteIndexes[1] = _scene->_sprites.addSprites(Resources::formatName(307, 'X', 0, EXT_SS, "")); + _globals._sequenceIndexes[1] = _scene->_sequences.startCycle(_globals._spriteIndexes[1], false, 1); + _scene->_sequences.setMsgPosition(_globals._sequenceIndexes[1], Common::Point(127, 78)); + _scene->_sequences.setDepth (_globals._sequenceIndexes[1], 15); + + if (_scene->_priorSceneId == 357) + _game._player._playerPos = Common::Point(305, 142); + else if (_scene->_priorSceneId != -2) + _game._player._playerPos = Common::Point(12, 141); + + sceneEntrySound(); +} + +void Scene358::preActions() { + if (_action.isAction(0x1AD, 0x2B9)) + _game._player._walkOffScreenSceneId = 357; + + if (_action.isAction(0x1AD, 0x2BA)) + _game._player._walkOffScreenSceneId = 359; +} + +void Scene358::actions() { + if (_action._lookFlag) + _vm->_dialogs->show(0x8BE7); + else if (_action.isAction(VERB_LOOK, 0x2BA)) + _vm->_dialogs->show(0x8BE2); + else if (_action.isAction(VERB_LOOK, 0x2B9)) + _vm->_dialogs->show(0x8BE3); + else if (_action.isAction(VERB_LOOK, 0x1CB)) + _vm->_dialogs->show(0x8BE4); + else if (_action.isAction(VERB_LOOK, 0x216)) + _vm->_dialogs->show(0x8BE5); + else if (_action.isAction(VERB_LOOK, 0x21B)) + _vm->_dialogs->show(0x8BE6); + else if (_action.isAction(VERB_LOOK, 0x204) || _action.isAction(VERB_LOOK, 0x18D)) + _vm->_dialogs->show(0x8BE8); + else if (_action.isAction(VERB_LOOK, 0x11)) + _vm->_dialogs->show(0x8BE9); + else + return; + + _action._inProgress = false; +} + +/*------------------------------------------------------------------------*/ + } // End of namespace Nebular } // End of namespace MADS diff --git a/engines/mads/nebular/nebular_scenes3.h b/engines/mads/nebular/nebular_scenes3.h index e27806b182..60b3bc1869 100644 --- a/engines/mads/nebular/nebular_scenes3.h +++ b/engines/mads/nebular/nebular_scenes3.h @@ -422,6 +422,18 @@ public: virtual void actions(); virtual void postActions() {}; }; + +class Scene358: public Scene3xx { +public: + Scene358(MADSEngine *vm) : Scene3xx(vm) {} + + virtual void setup(); + virtual void enter(); + virtual void step() {}; + virtual void preActions(); + virtual void actions(); + virtual void postActions() {}; +}; } // End of namespace Nebular } // End of namespace MADS |