aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
Diffstat (limited to 'engines')
-rw-r--r--engines/fullpipe/fullpipe.h1
-rw-r--r--engines/fullpipe/lift.cpp9
-rw-r--r--engines/fullpipe/scenes.cpp12
3 files changed, 12 insertions, 10 deletions
diff --git a/engines/fullpipe/fullpipe.h b/engines/fullpipe/fullpipe.h
index db6be8082b..e542599458 100644
--- a/engines/fullpipe/fullpipe.h
+++ b/engines/fullpipe/fullpipe.h
@@ -234,6 +234,7 @@ public:
void getAllInventory();
int lift_getButtonIdP(int objid);
+ void lift_setButton(const char *name, int state);
void lift_sub5(Scene *sc, int qu1, int qu2);
void lift_exitSeq(ExCommand *ex);
void lift_closedoorSeq();
diff --git a/engines/fullpipe/lift.cpp b/engines/fullpipe/lift.cpp
index 0e38c4f948..1d6d986977 100644
--- a/engines/fullpipe/lift.cpp
+++ b/engines/fullpipe/lift.cpp
@@ -22,6 +22,8 @@
#include "fullpipe/fullpipe.h"
+#include "fullpipe/objects.h"
+#include "fullpipe/objectnames.h"
#include "fullpipe/constants.h"
namespace Fullpipe {
@@ -64,6 +66,13 @@ int FullpipeEngine::lift_getButtonIdP(int objid) {
}
}
+void FullpipeEngine::lift_setButton(const char *name, int state) {
+ GameVar *var = g_fullpipe->getGameLoaderGameVar()->getSubVarByName("OBJSTATES")->getSubVarByName(sO_LiftButtons);
+
+ if (var)
+ var->setSubVarAsInt(name, state);
+}
+
void FullpipeEngine::lift_sub5(Scene *sc, int qu1, int qu2) {
warning("STUB: FullpipeEngine::lift_sub5()");
}
diff --git a/engines/fullpipe/scenes.cpp b/engines/fullpipe/scenes.cpp
index 97445f80c5..4d804e5c63 100644
--- a/engines/fullpipe/scenes.cpp
+++ b/engines/fullpipe/scenes.cpp
@@ -44,7 +44,6 @@
namespace Fullpipe {
int defaultUpdateCursor();
-void setElevatorButton(const char *name, int state);
int sceneIntro_updateCursor();
void sceneIntro_initScene(Scene *sc);
@@ -685,13 +684,6 @@ bool FullpipeEngine::sceneSwitcher(EntranceInfo *entrance) {
return true;
}
-void setElevatorButton(const char *name, int state) {
- GameVar *var = g_fullpipe->getGameLoaderGameVar()->getSubVarByName("OBJSTATES")->getSubVarByName(sO_LiftButtons);
-
- if (var)
- var->setSubVarAsInt(name, state);
-}
-
void global_messageHandler_KickStucco() {
warning("STUB: global_messageHandler_KickStucco()");
}
@@ -1518,7 +1510,7 @@ void scene01_initScene(Scene *sc, int entrance) {
bootAnim->_flags &= ~0x04;
}
- setElevatorButton(sO_Level2, ST_LBN_2N);
+ g_fullpipe->lift_setButton(sO_Level2, ST_LBN_2N);
}
int sceneHandler01(ExCommand *cmd) {
@@ -1680,7 +1672,7 @@ void scene03_initScene(Scene *sc) {
g_vars->swallowedEgg2 = v->getSubVarByName(sO_Egg2);
g_vars->swallowedEgg3 = v->getSubVarByName(sO_Egg3);
- setElevatorButton(sO_Level2, ST_LBN_2N);
+ g_fullpipe->lift_setButton(sO_Level2, ST_LBN_2N);
g_fullpipe->lift_sub5(sc, QU_SC3_ENTERLIFT, QU_SC3_EXITLIFT);
}