aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorStrangerke2015-09-22 10:39:43 +0200
committerStrangerke2015-09-22 10:39:43 +0200
commit7fbbf515932a32447fce1c2785936d3f2277bcaa (patch)
tree5611e9db505327e3623328bce68ca96348d8e956 /engines
parent63ad675abf7cc8585da30ef97bebe0c6cd502a58 (diff)
downloadscummvm-rg350-7fbbf515932a32447fce1c2785936d3f2277bcaa.tar.gz
scummvm-rg350-7fbbf515932a32447fce1c2785936d3f2277bcaa.tar.bz2
scummvm-rg350-7fbbf515932a32447fce1c2785936d3f2277bcaa.zip
MADS: Phantom - Implement Scene1xx functions
Diffstat (limited to 'engines')
-rw-r--r--engines/mads/phantom/phantom_scenes1.cpp85
-rw-r--r--engines/mads/player.cpp1
-rw-r--r--engines/mads/player.h1
3 files changed, 81 insertions, 6 deletions
diff --git a/engines/mads/phantom/phantom_scenes1.cpp b/engines/mads/phantom/phantom_scenes1.cpp
index 2d991fd3bc..97ff94ee94 100644
--- a/engines/mads/phantom/phantom_scenes1.cpp
+++ b/engines/mads/phantom/phantom_scenes1.cpp
@@ -31,15 +31,89 @@ namespace MADS {
namespace Phantom {
void Scene1xx::setAAName() {
- // TODO
- //int idx = 0;
- //_game._aaName = Resources::formatAAName(idx);
+ _game._aaName = Resources::formatAAName(_globals[kTempInterface]);
+ _vm->_palette->setEntry(254, 43, 47, 51);
}
void Scene1xx::sceneEntrySound() {
- // TODO
+ if (!_vm->_musicFlag)
+ return;
+
+ if (_globals[kDoneBrieConv203] == 3) {
+ _vm->_sound->command(39);
+ } else {
+ switch (_scene->_nextSceneId) {
+ case 101:
+ if (!_game._visitedScenes._sceneRevisited)
+ _vm->_sound->command(38);
+ else
+ _vm->_sound->command(16);
+ break;
+
+ case 102:
+ if (_scene->_priorSceneId == 104)
+ _vm->_sound->command(27);
+ else
+ _vm->_sound->command(16);
+ break;
+
+ case 103:
+ if ((_globals[kJacquesStatus] == 2)) {
+ _vm->_sound->command(32);
+ _globals[kJacquesStatus] = 3;
+ } else
+ _vm->_sound->command(16);
+ break;
+
+ case 104:
+ if (_scene->_priorSceneId == 301) {
+ warning("TODO: Add check on Conversation restore running == 7");
+ _vm->_sound->command(33);
+ } else if ((_globals[kRoom103104Transition] == 0) && !_globals[kObservedPhan104]) {
+ _vm->_sound->command(37);
+ _globals[kObservedPhan104] = true;
+ } else
+ _vm->_sound->command(16);
+ break;
+
+ case 111:
+ if (_scene->_priorSceneId == 150)
+ _vm->_sound->command(38);
+ else if (_globals[kLeaveAngelMusicOn])
+ _vm->_sound->command(34);
+ else
+ _vm->_sound->command(16);
+ break;
+ case 113:
+ if (_globals[kLeaveAngelMusicOn])
+ _vm->_sound->command(34);
+ else if (_globals[kCurrentYear] == 1993)
+ _vm->_sound->command(36);
+ else
+ _vm->_sound->command(35);
+ break;
+
+ default:
+ if ((_scene->_priorSceneId != 204) && (_scene->_nextSceneId != 150))
+ _vm->_sound->command(16);
+ break;
+ }
+ }
}
+void Scene1xx::setPlayerSpritesPrefix() {
+ _vm->_sound->command(5);
+
+ Common::String oldName = _game._player._spritesPrefix;
+
+ if (!_game._player._forcePrefix)
+ _game._player._spritesPrefix = "RAL";
+
+ if (oldName != _game._player._spritesPrefix)
+ _game._player._spritesChanged = true;
+
+ _game._player._scalingVelocity = true;}
+
/*------------------------------------------------------------------------*/
Scene101::Scene101(MADSEngine *vm) : Scene1xx(vm) {
@@ -48,11 +122,10 @@ Scene101::Scene101(MADSEngine *vm) : Scene1xx(vm) {
void Scene101::synchronize(Common::Serializer &s) {
Scene1xx::synchronize(s);
-
}
void Scene101::setup() {
- //setPlayerSpritesPrefix();
+ setPlayerSpritesPrefix();
setAAName();
}
diff --git a/engines/mads/player.cpp b/engines/mads/player.cpp
index bb747f4b52..10c93e55ab 100644
--- a/engines/mads/player.cpp
+++ b/engines/mads/player.cpp
@@ -80,6 +80,7 @@ Player::Player(MADSEngine *vm)
_moving = false;
_walkOffScreen = 0;
_walkOffScreenSceneId = -1;
+ _forcePrefix = false;
Common::fill(&_stopWalkerList[0], &_stopWalkerList[12], 0);
Common::fill(&_stopWalkerTrigger[0], &_stopWalkerTrigger[12], 0);
diff --git a/engines/mads/player.h b/engines/mads/player.h
index e5765a9bca..d2cdd47df0 100644
--- a/engines/mads/player.h
+++ b/engines/mads/player.h
@@ -131,6 +131,7 @@ public:
int _trigger;
bool _scalingVelocity;
bool _forceRefresh;
+ bool _forcePrefix;
bool _needToWalk;
bool _readyToWalk;
int _stopWalkerIndex;