diff options
author | Strangerke | 2014-04-16 17:48:36 +0200 |
---|---|---|
committer | Strangerke | 2014-04-16 17:48:36 +0200 |
commit | 39088c0121dec470f31a4171336ac8bd525b6fde (patch) | |
tree | eb1dd0fee486376682a793644f7161ece89fa67e /engines/mads/nebular | |
parent | c7567a90ca248c8e422769c11a2e24c3129a4f13 (diff) | |
download | scummvm-rg350-39088c0121dec470f31a4171336ac8bd525b6fde.tar.gz scummvm-rg350-39088c0121dec470f31a4171336ac8bd525b6fde.tar.bz2 scummvm-rg350-39088c0121dec470f31a4171336ac8bd525b6fde.zip |
MADS: Implement scene 301
Diffstat (limited to 'engines/mads/nebular')
-rw-r--r-- | engines/mads/nebular/nebular_scenes.cpp | 5 | ||||
-rw-r--r-- | engines/mads/nebular/nebular_scenes3.cpp | 62 | ||||
-rw-r--r-- | engines/mads/nebular/nebular_scenes3.h | 11 |
3 files changed, 60 insertions, 18 deletions
diff --git a/engines/mads/nebular/nebular_scenes.cpp b/engines/mads/nebular/nebular_scenes.cpp index 562f31c3b2..fde69b653a 100644 --- a/engines/mads/nebular/nebular_scenes.cpp +++ b/engines/mads/nebular/nebular_scenes.cpp @@ -30,6 +30,7 @@ #include "mads/nebular/nebular_scenes.h" #include "mads/nebular/nebular_scenes1.h" #include "mads/nebular/nebular_scenes2.h" +#include "mads/nebular/nebular_scenes3.h" #include "mads/nebular/nebular_scenes8.h" namespace MADS { @@ -101,6 +102,10 @@ SceneLogic *SceneFactory::createScene(MADSEngine *vm) { case 216: return new Scene216(vm); + // Scene group #3 + case 301: + return new Scene301(vm); + // Scene group #8 case 804: return new Scene804(vm); diff --git a/engines/mads/nebular/nebular_scenes3.cpp b/engines/mads/nebular/nebular_scenes3.cpp index d74d275b22..2d9f2d3de7 100644 --- a/engines/mads/nebular/nebular_scenes3.cpp +++ b/engines/mads/nebular/nebular_scenes3.cpp @@ -59,8 +59,8 @@ void Scene3xx::setPlayerSpritesPrefix() { if (oldName != _game._player._spritesPrefix) _game._player._spritesChanged = true; - _vm->_palette->setEntry(16, 10, 63, 63); - _vm->_palette->setEntry(17, 10, 45, 45); + _vm->_palette->setEntry(16, 10, 63, 63); + _vm->_palette->setEntry(17, 10, 45, 45); } void Scene3xx::sceneEntrySound() { @@ -80,28 +80,28 @@ void Scene3xx::sceneEntrySound() { _vm->_sound->command(11); break; - case 311: + case 311: if (_scene->_priorSceneId == 304) _vm->_sound->command(11); else _vm->_sound->command(10); break; - case 313: - case 316: - case 320: - case 322: - case 357: - case 358: - case 359: - case 360: - case 361: - case 387: - case 388: - case 389: - case 390: - case 391: - case 399: + case 313: + case 316: + case 320: + case 322: + case 357: + case 358: + case 359: + case 360: + case 361: + case 387: + case 388: + case 389: + case 390: + case 391: + case 399: _vm->_sound->command(10); break; @@ -131,5 +131,31 @@ void Scene3xx::sceneEntrySound() { /*------------------------------------------------------------------------*/ +void Scene301::setup() { + setPlayerSpritesPrefix(); + setAAName(); +} + +void Scene301::enter() { + _globals._spriteIndexes[1] = _scene->_sprites.addSprites(formAnimName('x', 0)); + _globals._sequenceIndexes[1] = _scene->_sequences.addSpriteCycle(_globals._spriteIndexes[1], false, 9, 0, 0, 0); + + _globals[kMeteorologistStatus] = METEOROLOGIST_GONE; + _globals[kTeleporterCommand] = TELEPORTER_NONE; + + _game._player._stepEnabled = false; + _game._player._visible = false; + _scene->loadAnimation(formAnimName('a', -1), 60); + + sceneEntrySound(); +} + +void Scene301::step() { + if (_game._trigger == 60) + _scene->_nextSceneId = 302; +} + +/*------------------------------------------------------------------------*/ + } // 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 abba91d897..eb92de5b85 100644 --- a/engines/mads/nebular/nebular_scenes3.h +++ b/engines/mads/nebular/nebular_scenes3.h @@ -49,6 +49,17 @@ public: Scene3xx(MADSEngine *vm) : NebularScene(vm) {} }; +class Scene301: public Scene3xx { +public: + Scene301(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 |