aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStrangerke2014-05-22 18:39:59 +0200
committerStrangerke2014-05-22 18:39:59 +0200
commit542adf8ba441ccfbff621b303e2d4916f487d8af (patch)
tree9f011ce3292c068faaff17f8ff1300e2c48b3550
parent904796f3a5dfb965995082614d69542452387bbc (diff)
downloadscummvm-rg350-542adf8ba441ccfbff621b303e2d4916f487d8af.tar.gz
scummvm-rg350-542adf8ba441ccfbff621b303e2d4916f487d8af.tar.bz2
scummvm-rg350-542adf8ba441ccfbff621b303e2d4916f487d8af.zip
MADS: Move contructors out of the header in scene group 4
-rw-r--r--engines/mads/nebular/nebular_scenes4.cpp158
-rw-r--r--engines/mads/nebular/nebular_scenes4.h12
2 files changed, 119 insertions, 51 deletions
diff --git a/engines/mads/nebular/nebular_scenes4.cpp b/engines/mads/nebular/nebular_scenes4.cpp
index 4156842c0e..cb5363bd65 100644
--- a/engines/mads/nebular/nebular_scenes4.cpp
+++ b/engines/mads/nebular/nebular_scenes4.cpp
@@ -93,9 +93,9 @@ void Scene4xx::sceneEntrySound() {
/*------------------------------------------------------------------------*/
-void Scene401::setup() {
- setPlayerSpritesPrefix();
- setAAName();
+Scene401::Scene401(MADSEngine *vm) : Scene4xx(vm), _destPos(0, 0) {
+ _northFl = false;
+ _timer = 0;
}
void Scene401::synchronize(Common::Serializer &s) {
@@ -107,6 +107,11 @@ void Scene401::synchronize(Common::Serializer &s) {
s.syncAsUint32LE(_timer);
}
+void Scene401::setup() {
+ setPlayerSpritesPrefix();
+ setAAName();
+}
+
void Scene401::enter() {
if (_scene->_priorSceneId != -2)
_northFl = false;
@@ -231,19 +236,43 @@ void Scene401::actions() {
}
/*------------------------------------------------------------------------*/
-void Scene402::setup() {
- setPlayerSpritesPrefix();
- setAAName();
- _scene->addActiveVocab(NOUN_BARTENDER);
- _scene->addActiveVocab(NOUN_ALIEN_LIQUOR);
- _scene->addActiveVocab(VERB_DRINK);
- _scene->addActiveVocab(NOUN_BINOCULARS);
- _scene->addActiveVocab(VERB_WALKTO);
- _scene->addActiveVocab(NOUN_CREDIT_CHIP);
- _scene->addActiveVocab(VERB_TAKE);
- _scene->addActiveVocab(NOUN_REPAIR_LIST);
- _scene->addActiveVocab(VERB_LOOK_AT);
+Scene402::Scene402(MADSEngine *vm) : Scene4xx(vm) {
+ _lightOn = false;
+ _blowingSmoke = false;
+ _leftWomanMoving = false;
+ _rightWomanMoving = false;
+ _firstTalkToGirlInChair = false;
+ _waitingGinnyMove = false;
+ _ginnyLooking = false;
+ _bigBeatFl = false;
+ _roxOnStool = false;
+ _bartenderSteady = false;
+ _bartenderHandsHips = false;
+ _bartenderLooksLeft = false;
+ _bartenderReady = false;
+ _bartenderTalking = false;
+ _bartenderCalled = false;
+ _conversationFl = false;
+ _activeTeleporter = false;
+ _activeArrows = false;
+ _activeArrow1 = false;
+ _activeArrow2 = false;
+ _activeArrow3 = false;
+ _cutSceneReady = false;
+ _cutSceneNeeded = false;
+ _helgaReady = false;
+ _refuseAlienLiquor = false;
+
+ _drinkTimer = -1;
+ _beatCounter = -1;
+ _bartenderMode = -1;
+ _bartenderDialogNode = -1;
+ _bartenderCurrentQuestion = -1;
+ _helgaTalkMode = -1;
+ _roxMode = -1;
+ _rexMode = -1;
+ _talkTimer = -1;
}
void Scene402::synchronize(Common::Serializer &s) {
@@ -286,6 +315,21 @@ void Scene402::synchronize(Common::Serializer &s) {
s.syncAsSint16LE(_talkTimer);
}
+void Scene402::setup() {
+ setPlayerSpritesPrefix();
+ setAAName();
+
+ _scene->addActiveVocab(NOUN_BARTENDER);
+ _scene->addActiveVocab(NOUN_ALIEN_LIQUOR);
+ _scene->addActiveVocab(VERB_DRINK);
+ _scene->addActiveVocab(NOUN_BINOCULARS);
+ _scene->addActiveVocab(VERB_WALKTO);
+ _scene->addActiveVocab(NOUN_CREDIT_CHIP);
+ _scene->addActiveVocab(VERB_TAKE);
+ _scene->addActiveVocab(NOUN_REPAIR_LIST);
+ _scene->addActiveVocab(VERB_LOOK_AT);
+}
+
void Scene402::setDialogNode(int node) {
if (node > 0)
_bartenderDialogNode = node;
@@ -2514,6 +2558,16 @@ void Scene405::actions() {
/*------------------------------------------------------------------------*/
+Scene406::Scene406(MADSEngine *vm) : Scene4xx(vm) {
+ _hitStorageDoor = false;
+}
+
+void Scene406::synchronize(Common::Serializer &s) {
+ Scene4xx::synchronize(s);
+
+ s.syncAsByte(_hitStorageDoor);
+}
+
void Scene406::setup() {
setPlayerSpritesPrefix();
setAAName();
@@ -2717,13 +2771,19 @@ void Scene406::actions() {
_action._inProgress = false;
}
-void Scene406::synchronize(Common::Serializer &s) {
- Scene4xx::synchronize(s);
+/*------------------------------------------------------------------------*/
- s.syncAsByte(_hitStorageDoor);
+Scene407::Scene407(MADSEngine *vm) : Scene4xx(vm), _destPos(0, 0) {
+ _fromNorth = false;
}
-/*------------------------------------------------------------------------*/
+void Scene407::synchronize(Common::Serializer &s) {
+ Scene4xx::synchronize(s);
+
+ s.syncAsByte(_fromNorth);
+ s.syncAsSint16LE(_destPos.x);
+ s.syncAsSint16LE(_destPos.y);
+}
void Scene407::setup() {
setPlayerSpritesPrefix();
@@ -2831,14 +2891,6 @@ void Scene407::actions() {
_action._inProgress = false;
}
-void Scene407::synchronize(Common::Serializer &s) {
- Scene4xx::synchronize(s);
-
- s.syncAsByte(_fromNorth);
- s.syncAsSint16LE(_destPos.x);
- s.syncAsSint16LE(_destPos.y);
-}
-
/*------------------------------------------------------------------------*/
void Scene408::setup() {
@@ -3214,6 +3266,30 @@ void Scene410::actions() {
/*------------------------------------------------------------------------*/
+Scene411::Scene411(MADSEngine *vm) : Scene4xx(vm) {
+ _curAnimationFrame = -1;
+ _newIngredient = -1;
+ _newQuantity = -1;
+ _resetFrame = -1;
+ _badThreshold = -1;
+
+ _killRox = false;
+ _makeMushroomCloud = false;
+}
+
+void Scene411::synchronize(Common::Serializer &s) {
+ Scene4xx::synchronize(s);
+
+ s.syncAsSint32LE(_curAnimationFrame);
+ s.syncAsSint32LE(_newIngredient);
+ s.syncAsSint32LE(_newQuantity);
+ s.syncAsSint32LE(_resetFrame);
+ s.syncAsSint32LE(_badThreshold);
+
+ s.syncAsByte(_killRox);
+ s.syncAsByte(_makeMushroomCloud);
+}
+
bool Scene411::addIngredient() {
bool retVal = false;
@@ -3952,20 +4028,19 @@ void Scene411::actions() {
_action._inProgress = false;
}
-void Scene411::synchronize(Common::Serializer &s) {
- Scene4xx::synchronize(s);
-
- s.syncAsSint32LE(_curAnimationFrame);
- s.syncAsSint32LE(_newIngredient);
- s.syncAsSint32LE(_newQuantity);
- s.syncAsSint32LE(_resetFrame);
- s.syncAsSint32LE(_badThreshold);
+/*------------------------------------------------------------------------*/
- s.syncAsByte(_killRox);
- s.syncAsByte(_makeMushroomCloud);
+Scene413::Scene413(MADSEngine *vm) : Scene4xx(vm) {
+ _rexDeath = -1;
+ _canMove = -1;
}
-/*------------------------------------------------------------------------*/
+void Scene413::synchronize(Common::Serializer &s) {
+ Scene4xx::synchronize(s);
+
+ s.syncAsSint32LE(_rexDeath);
+ s.syncAsSint32LE(_canMove);
+}
void Scene413::setup() {
setPlayerSpritesPrefix();
@@ -4110,13 +4185,6 @@ void Scene413::actions() {
_action._inProgress = false;
}
-void Scene413::synchronize(Common::Serializer &s) {
- Scene4xx::synchronize(s);
-
- s.syncAsSint32LE(_rexDeath);
- s.syncAsSint32LE(_canMove);
-}
-
/*------------------------------------------------------------------------*/
} // End of namespace Nebular
diff --git a/engines/mads/nebular/nebular_scenes4.h b/engines/mads/nebular/nebular_scenes4.h
index bacab8a156..4544e0887f 100644
--- a/engines/mads/nebular/nebular_scenes4.h
+++ b/engines/mads/nebular/nebular_scenes4.h
@@ -57,7 +57,7 @@ private:
uint32 _timer;
public:
- Scene401(MADSEngine *vm) : Scene4xx(vm) {}
+ Scene401(MADSEngine *vm);
void synchronize(Common::Serializer &s);
virtual void setup();
@@ -118,7 +118,7 @@ private:
void handleDialogs();
public:
- Scene402(MADSEngine *vm) : Scene4xx(vm) {}
+ Scene402(MADSEngine *vm);
void synchronize(Common::Serializer &s);
virtual void setup();
@@ -144,7 +144,7 @@ private:
bool _hitStorageDoor;
public:
- Scene406(MADSEngine *vm) : Scene4xx(vm) {}
+ Scene406(MADSEngine *vm);
void synchronize(Common::Serializer &s);
virtual void setup();
@@ -160,7 +160,7 @@ private:
Common::Point _destPos;
public:
- Scene407(MADSEngine *vm) : Scene4xx(vm) {}
+ Scene407(MADSEngine *vm);
void synchronize(Common::Serializer &s);
virtual void setup();
@@ -227,7 +227,7 @@ private:
bool addIngredient();
public:
- Scene411(MADSEngine *vm) : Scene4xx(vm) {}
+ Scene411(MADSEngine *vm);
void synchronize(Common::Serializer &s);
virtual void setup();
@@ -243,7 +243,7 @@ private:
int _canMove;
public:
- Scene413(MADSEngine *vm) : Scene4xx(vm) {}
+ Scene413(MADSEngine *vm);
void synchronize(Common::Serializer &s);
virtual void setup();