aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlyssa Milburn2011-01-22 21:22:12 +0000
committerAlyssa Milburn2011-01-22 21:22:12 +0000
commitbfe0307300a36042e7b82fcc3275d317126b3af4 (patch)
tree3e90f0e56508f318b473ef14a9259974227a70b1
parent00cabdad11ea7b2bac21eb0e06aa99d325be31b5 (diff)
downloadscummvm-rg350-bfe0307300a36042e7b82fcc3275d317126b3af4.tar.gz
scummvm-rg350-bfe0307300a36042e7b82fcc3275d317126b3af4.tar.bz2
scummvm-rg350-bfe0307300a36042e7b82fcc3275d317126b3af4.zip
MOHAWK: Implement kCSTimeEventCharSomeNIS55.
svn-id: r55445
-rw-r--r--engines/mohawk/cstime.cpp24
-rw-r--r--engines/mohawk/cstime.h1
2 files changed, 25 insertions, 0 deletions
diff --git a/engines/mohawk/cstime.cpp b/engines/mohawk/cstime.cpp
index 6d4b370a30..44c61176be 100644
--- a/engines/mohawk/cstime.cpp
+++ b/engines/mohawk/cstime.cpp
@@ -310,6 +310,24 @@ void MohawkEngine_CSTime::eventIdle() {
}
break;
+ case kCSTimeEventCharSomeNIS55:
+ // This is like kCSTimeEventCharPlayNIS, only using a different flag variable.
+ if (_processingNIS55) {
+ CSTimeChar *chr = _case->getCurrScene()->getChar(event.param1);
+ if (chr->NISIsDone()) {
+ chr->removeNIS();
+ _processingNIS55 = false;
+ chr->setupAmbientAnims(true);
+ _events.pop_front();
+ processEvent = false;
+ } else {
+ done = true;
+ }
+ } else {
+ advanceQueue = false;
+ }
+ break;
+
default:
break;
}
@@ -350,6 +368,7 @@ bool MohawkEngine_CSTime::NISIsRunning() {
void MohawkEngine_CSTime::reset() {
_NISRunning = false;
+ _processingNIS55 = false;
_lastTimeout = 0xffffffff;
_processingEvent = false;
}
@@ -531,6 +550,11 @@ void MohawkEngine_CSTime::triggerEvent(CSTimeEvent &event) {
// FIXME
break;
+ case kCSTimeEventCharSomeNIS55:
+ _processingNIS55 = true;
+ _case->getCurrScene()->getChar(event.param1)->playNIS(event.param2);
+ break;
+
case kCSTimeEventUpdateBubble:
switch (event.param2) {
case 0:
diff --git a/engines/mohawk/cstime.h b/engines/mohawk/cstime.h
index dca966f8b6..3b5be08c2c 100644
--- a/engines/mohawk/cstime.h
+++ b/engines/mohawk/cstime.h
@@ -178,6 +178,7 @@ private:
uint16 _nextSceneId;
bool _processingEvent;
+ bool _processingNIS55;
bool _NISRunning;
uint32 _lastTimeout;
void reset();