aboutsummaryrefslogtreecommitdiff
path: root/engines/mads
diff options
context:
space:
mode:
authorStrangerke2014-04-28 21:23:43 +0200
committerStrangerke2014-04-28 21:23:43 +0200
commit396905d90512f265fd95a87208d2295265e500e3 (patch)
tree8068a7133b713442d7283b6a45360b8fe435673b /engines/mads
parentff7f30af9906500a53747770d0343d0d9fd4c072 (diff)
downloadscummvm-rg350-396905d90512f265fd95a87208d2295265e500e3.tar.gz
scummvm-rg350-396905d90512f265fd95a87208d2295265e500e3.tar.bz2
scummvm-rg350-396905d90512f265fd95a87208d2295265e500e3.zip
MADS: Implement scene 388
Diffstat (limited to 'engines/mads')
-rw-r--r--engines/mads/nebular/nebular_scenes.cpp2
-rw-r--r--engines/mads/nebular/nebular_scenes3.cpp63
-rw-r--r--engines/mads/nebular/nebular_scenes3.h12
3 files changed, 77 insertions, 0 deletions
diff --git a/engines/mads/nebular/nebular_scenes.cpp b/engines/mads/nebular/nebular_scenes.cpp
index 87a7a96d28..77a7a223c9 100644
--- a/engines/mads/nebular/nebular_scenes.cpp
+++ b/engines/mads/nebular/nebular_scenes.cpp
@@ -154,6 +154,8 @@ SceneLogic *SceneFactory::createScene(MADSEngine *vm) {
return new Scene366(vm);
case 387:
return new Scene387(vm);
+ case 388:
+ return new Scene388(vm);
// Scene group #8
case 804:
diff --git a/engines/mads/nebular/nebular_scenes3.cpp b/engines/mads/nebular/nebular_scenes3.cpp
index 9558edb980..4db80836e8 100644
--- a/engines/mads/nebular/nebular_scenes3.cpp
+++ b/engines/mads/nebular/nebular_scenes3.cpp
@@ -5244,5 +5244,68 @@ void Scene387::actions() {
/*------------------------------------------------------------------------*/
+void Scene388::setup() {
+ setPlayerSpritesPrefix();
+ setAAName();
+}
+
+void Scene388::enter() {
+ _scene->_userInterface.setup(kInputLimitedSentences);
+
+ if (_globals[kAfterHavoc])
+ _scene->_hotspots.activate(0x303, false);
+ else {
+ _globals._spriteIndexes[0] = _scene->_sprites.addSprites(formAnimName('b', 0));
+ _globals._sequenceIndexes[0] = _scene->_sequences.startCycle(_globals._spriteIndexes[0], false, 1);
+ }
+
+ _game._player._visible = false;
+ _vm->_palette->setEntry(252, 63, 30, 20);
+ _vm->_palette->setEntry(253, 45, 15, 12);
+ _game.loadQuoteSet(0x154, 0x155, 0x156, 0x157, 0x158, 0);
+
+ sceneEntrySound();
+}
+
+void Scene388::actions() {
+ if (_action.isAction(0x2D5, 0x2D4))
+ _scene->_nextSceneId = 313;
+ else if (_action.isAction(VERB_TALKTO, 0x303)) {
+ switch (_game._trigger) {
+ case 0:
+ _game._player._stepEnabled = false;
+ _scene->_kernelMessages.reset();
+ _scene->_kernelMessages.add(Common::Point(160, 136), 0x1110, 32, 1, 120, _game.getQuote(0x154));
+ break;
+
+ case 1:
+ _scene->_kernelMessages.add(Common::Point(82, 38), 0xFDFC, 0, 0, 300, _game.getQuote(0x156));
+ _scene->_kernelMessages.add(Common::Point(82, 52), 0xFDFC, 0, 0, 300, _game.getQuote(0x157));
+ _scene->_kernelMessages.add(Common::Point(82, 66), 0xFDFC, 0, 2, 300, _game.getQuote(0x158));
+ break;
+
+ case 2:
+ _game._player._stepEnabled = true;
+ _scene->_kernelMessages.add(Common::Point(160, 136), 0x1110, 32, 0, 120, _game.getQuote(0x155));
+ break;
+
+ default:
+ break;
+ }
+ } else if (_action.isAction(0xD3, 0x2D3)) {
+ if (_globals[kAfterHavoc])
+ _vm->_dialogs->show(0x979B);
+ else
+ _vm->_dialogs->show(0x979A);
+ } else if (_action.isAction(VERB_OPEN, 0x2D3))
+ _vm->_dialogs->show(0x979C);
+ 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 24b1aef82b..4de4fc1a2c 100644
--- a/engines/mads/nebular/nebular_scenes3.h
+++ b/engines/mads/nebular/nebular_scenes3.h
@@ -502,6 +502,18 @@ public:
virtual void postActions() {};
};
+class Scene388: public Scene3xx {
+public:
+ Scene388(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