aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2014-01-07 16:57:06 +0200
committerEugene Sandulenko2014-01-07 16:57:06 +0200
commitd821719c47cc8fae2e52f9a673ac5662344794c8 (patch)
treef01af04707d9e2b6ec2da5e25217263df5f5a8e1
parentae5389af8bd3b248b3bbbcbf8fd62284586b0d22 (diff)
downloadscummvm-rg350-d821719c47cc8fae2e52f9a673ac5662344794c8.tar.gz
scummvm-rg350-d821719c47cc8fae2e52f9a673ac5662344794c8.tar.bz2
scummvm-rg350-d821719c47cc8fae2e52f9a673ac5662344794c8.zip
FULLPIPE: Implement sceneHandler32_potLogic()
-rw-r--r--engines/fullpipe/constants.h2
-rw-r--r--engines/fullpipe/scenes/scene32.cpp23
2 files changed, 24 insertions, 1 deletions
diff --git a/engines/fullpipe/constants.h b/engines/fullpipe/constants.h
index 21ae1d927d..f0d978be9d 100644
--- a/engines/fullpipe/constants.h
+++ b/engines/fullpipe/constants.h
@@ -1058,6 +1058,7 @@ namespace Fullpipe {
#define ANI_BUTTON_32 5347
#define ANI_CACTUS 2267
#define ANI_FLAG 2257
+#define ANI_KADKA 2670
#define ANI_TESTO_BLUE 2659
#define ANI_TESTO_GREEN 2662
#define ANI_TESTO_ORANGE 2656
@@ -1076,6 +1077,7 @@ namespace Fullpipe {
#define MV_FLG_STARTR 2263
#define MV_FLG_STOPL 2261
#define MV_FLG_STOPR 2265
+#define MV_MAN32_STANDUP 2313
#define MV_TSTG_FLOW 2663
#define MV_TSTO_FLOW 2657
#define PIC_SC32_LADDER 4296
diff --git a/engines/fullpipe/scenes/scene32.cpp b/engines/fullpipe/scenes/scene32.cpp
index ac26cf452c..4f2b78feff 100644
--- a/engines/fullpipe/scenes/scene32.cpp
+++ b/engines/fullpipe/scenes/scene32.cpp
@@ -190,7 +190,28 @@ void sceneHandler32_ladderLogic(ExCommand *cmd) {
}
void sceneHandler32_potLogic(ExCommand *cmd) {
- warning("STUB: sceneHandler32_potLogic(cmd)");
+ if (g_vars->scene32_var08 < 0 || g_vars->scene32_var08 > 20) {
+ MessageQueue *mq = new MessageQueue(g_fp->_globalMessageQueueList->compact());
+
+ ExCommand *ex = new ExCommand(ANI_MAN, 1, MV_MAN32_STANDUP, 0, 0, 0, 1, 0, 0, 0);
+
+ ex->_excFlags |= 2;
+
+ mq->addExCommandToEnd(ex);
+
+ StaticANIObject *ani = g_fp->_currentScene->getStaticANIObjectAtPos(cmd->_sceneClickX, cmd->_sceneClickY);
+
+ if (!ani || ani->_id != ANI_KADKA)
+ mq->addExCommandToEnd(cmd->createClone());
+
+ mq->setFlags(mq->getFlags() | 1);
+ mq->chain(0);
+
+ getCurrSceneSc2MotionController()->setEnabled();
+ getGameLoaderInteractionController()->enableFlag24();
+
+ g_vars->scene32_var07 = 0;
+ }
}
int sceneHandler32(ExCommand *cmd) {