diff options
author | Alyssa Milburn | 2011-01-22 17:33:44 +0000 |
---|---|---|
committer | Alyssa Milburn | 2011-01-22 17:33:44 +0000 |
commit | de4b5645324a9019344dd94877c7ecc2139b5cd0 (patch) | |
tree | ebb814c047067a92544ac7ebfb84b09638272b73 /engines/mohawk | |
parent | caccceb02b7de1812190114373f69e574e570308 (diff) | |
download | scummvm-rg350-de4b5645324a9019344dd94877c7ecc2139b5cd0.tar.gz scummvm-rg350-de4b5645324a9019344dd94877c7ecc2139b5cd0.tar.bz2 scummvm-rg350-de4b5645324a9019344dd94877c7ecc2139b5cd0.zip |
MOHAWK: Add/use visit count for scenes.
svn-id: r55440
Diffstat (limited to 'engines/mohawk')
-rw-r--r-- | engines/mohawk/cstime.cpp | 8 | ||||
-rw-r--r-- | engines/mohawk/cstime_game.cpp | 1 | ||||
-rw-r--r-- | engines/mohawk/cstime_game.h | 1 |
3 files changed, 8 insertions, 2 deletions
diff --git a/engines/mohawk/cstime.cpp b/engines/mohawk/cstime.cpp index 9959af86e6..4bca986d7f 100644 --- a/engines/mohawk/cstime.cpp +++ b/engines/mohawk/cstime.cpp @@ -200,6 +200,7 @@ void MohawkEngine_CSTime::nextScene() { _case->setCurrScene(_nextSceneId); CSTimeScene *scene = _case->getCurrScene(); // TODO: scene->setState(1); + scene->_visitCount++; scene->installGroup(); _interface->draw(); @@ -210,8 +211,11 @@ void MohawkEngine_CSTime::nextScene() { addEvent(CSTimeEvent(kCSTimeEventWait, 0xffff, 500)); scene->idleAmbientAnims(); // TODO: startEnvironmentSound(); - // TODO: queue one of the scene event queues, depending on whether a value is <= 1 or not - addEventList(scene->getEvents(false)); + if (scene->_visitCount == 1) { + addEventList(scene->getEvents(false)); + } else { + addEventList(scene->getEvents(true)); + } _view->idleView(); // TODO: maybe startMusic(); } diff --git a/engines/mohawk/cstime_game.cpp b/engines/mohawk/cstime_game.cpp index addddea3e8..05f2c36125 100644 --- a/engines/mohawk/cstime_game.cpp +++ b/engines/mohawk/cstime_game.cpp @@ -750,6 +750,7 @@ CSTimeScene *CSTimeCase::getCurrScene() { } CSTimeScene::CSTimeScene(MohawkEngine_CSTime *vm, CSTimeCase *case_, uint id) : _vm(vm), _case(case_), _id(id) { + _visitCount = 0; _activeChar = NULL; _currHotspot = 0xffff; _hoverHotspot = 0xffff; diff --git a/engines/mohawk/cstime_game.h b/engines/mohawk/cstime_game.h index d604f120ad..661fdbaa41 100644 --- a/engines/mohawk/cstime_game.h +++ b/engines/mohawk/cstime_game.h @@ -220,6 +220,7 @@ public: uint16 getHelperId() { return _helperId; } uint getId() { return _id; } + uint _visitCount; CSTimeChar *_activeChar; Common::Array<Feature *> _objectFeatures; |