diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/mads/nebular/nebular_scenes.cpp | 4 | ||||
-rw-r--r-- | engines/mads/nebular/nebular_scenes7.cpp | 51 | ||||
-rw-r--r-- | engines/mads/nebular/nebular_scenes7.h | 12 |
3 files changed, 65 insertions, 2 deletions
diff --git a/engines/mads/nebular/nebular_scenes.cpp b/engines/mads/nebular/nebular_scenes.cpp index 6ae9fef8ab..6ee696bb6f 100644 --- a/engines/mads/nebular/nebular_scenes.cpp +++ b/engines/mads/nebular/nebular_scenes.cpp @@ -253,6 +253,8 @@ SceneLogic *SceneFactory::createScene(MADSEngine *vm) { error("Invalid scene %d called", scene._nextSceneId); // Scene group #7 + case 707: + return new Scene707(vm); case 701: // TODO case 702: @@ -265,8 +267,6 @@ SceneLogic *SceneFactory::createScene(MADSEngine *vm) { // TODO case 706: // TODO - case 707: - // TODO case 708: // TODO case 710: diff --git a/engines/mads/nebular/nebular_scenes7.cpp b/engines/mads/nebular/nebular_scenes7.cpp index ca9685a1b0..6692362ba3 100644 --- a/engines/mads/nebular/nebular_scenes7.cpp +++ b/engines/mads/nebular/nebular_scenes7.cpp @@ -90,5 +90,56 @@ void Scene7xx::sceneEntrySound() { /*------------------------------------------------------------------------*/ +void Scene707::setup() { + _game._player._spritesPrefix = ""; + // The original calls Scene7xx::setAAName() + _game._aaName = Resources::formatAAName(5); +} + +void Scene707::enter() { + _handSpriteId = _scene->_sprites.addSprites("*REXHAND"); + teleporterEnter(); + + // The original uses Scene7xx_sceneEntrySound + if (!_vm->_musicFlag) + _vm->_sound->command(2); + else + _vm->_sound->command(25); +} + +void Scene707::step() { + teleporterStep(); +} + +void Scene707::actions() { + if (teleporterActions()) { + _action._inProgress = false; + return; + } + + if (_action.isAction(VERB_LOOK, 0x181) || _action.isAction(0x103, 0x181)) + _vm->_dialogs->show(70710); + else if (_action.isAction(VERB_LOOK, 0xC4)) + _vm->_dialogs->show(70711); + else if (_action.isAction(VERB_LOOK, 0x1CC)) + _vm->_dialogs->show(70712); + else if (_action.isAction(VERB_LOOK, 0x1D0) || _action.isAction(VERB_LOOK, 0x1D1) + || _action.isAction(VERB_LOOK, 0x1D2) || _action.isAction(VERB_LOOK, 0x1D3) + || _action.isAction(VERB_LOOK, 0x1D4) || _action.isAction(VERB_LOOK, 0x1D5) + || _action.isAction(VERB_LOOK, 0x1D6) || _action.isAction(VERB_LOOK, 0x1D7) + || _action.isAction(VERB_LOOK, 0x1D8) || _action.isAction(VERB_LOOK, 0x1D9) + || _action.isAction(VERB_LOOK, 0x1DB) || _action.isAction(VERB_LOOK, 0x7A) + || _action.isAction(VERB_LOOK, 0x1DA)) + _vm->_dialogs->show(70713); + else if (_action.isAction(VERB_LOOK, 0x1CF) || _action._lookFlag) + _vm->_dialogs->show(70714); + else + return; + + _action._inProgress = false; +} + +/*------------------------------------------------------------------------*/ + } // End of namespace Nebular } // End of namespace MADS diff --git a/engines/mads/nebular/nebular_scenes7.h b/engines/mads/nebular/nebular_scenes7.h index 2816af35e6..1d6c26d41e 100644 --- a/engines/mads/nebular/nebular_scenes7.h +++ b/engines/mads/nebular/nebular_scenes7.h @@ -50,6 +50,18 @@ public: Scene7xx(MADSEngine *vm) : NebularScene(vm) {} }; +class Scene707: public SceneTeleporter { +public: + Scene707(MADSEngine *vm) : SceneTeleporter(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 |