aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/fullpipe/scenes.cpp6
-rw-r--r--engines/fullpipe/scenes.h6
-rw-r--r--engines/fullpipe/scenes/scene20.cpp21
3 files changed, 10 insertions, 23 deletions
diff --git a/engines/fullpipe/scenes.cpp b/engines/fullpipe/scenes.cpp
index 2c67a47526..9e990b7117 100644
--- a/engines/fullpipe/scenes.cpp
+++ b/engines/fullpipe/scenes.cpp
@@ -247,11 +247,7 @@ Vars::Vars() {
scene17_handPhase = false;
scene17_sceneEdgeX = 0;
- scene20_var01 = 0;
- scene20_var02 = 0;
- scene20_var03 = 0;
- scene20_var04 = 0;
- scene20_var05 = 0;
+ scene20_fliesCountdown = 0;
scene20_grandma = 0;
scene21_giraffeBottom = 0;
diff --git a/engines/fullpipe/scenes.h b/engines/fullpipe/scenes.h
index 7e30c86025..c95688395c 100644
--- a/engines/fullpipe/scenes.h
+++ b/engines/fullpipe/scenes.h
@@ -348,11 +348,7 @@ public:
bool scene17_handPhase;
int scene17_sceneEdgeX;
- int scene20_var01;
- int scene20_var02;
- int scene20_var03;
- int scene20_var04;
- int scene20_var05;
+ int scene20_fliesCountdown;
StaticANIObject *scene20_grandma;
StaticANIObject *scene21_giraffeBottom;
diff --git a/engines/fullpipe/scenes/scene20.cpp b/engines/fullpipe/scenes/scene20.cpp
index 82fc5b6e04..5fed24aabd 100644
--- a/engines/fullpipe/scenes/scene20.cpp
+++ b/engines/fullpipe/scenes/scene20.cpp
@@ -59,11 +59,6 @@ void scene20_setExits(Scene *sc) {
}
void scene20_initScene(Scene *sc) {
- g_vars->scene20_var01 = 200;
- g_vars->scene20_var02 = 200;
- g_vars->scene20_var03 = 300;
- g_vars->scene20_var04 = 300;
-
Scene *oldsc = g_fp->_currentScene;
g_vars->scene20_grandma = sc->getStaticANIObject1ById(ANI_GRANDMA_20, -1);
@@ -95,7 +90,7 @@ void scene20_initScene(Scene *sc) {
g_fp->_currentScene = oldsc;
- g_vars->scene20_var05 = g_fp->_rnd->getRandomNumber(200) + 400;
+ g_vars->scene20_fliesCountdown = g_fp->_rnd->getRandomNumber(200) + 400;
}
void sceneHandler20_updateFlies() {
@@ -117,7 +112,7 @@ void sceneHandler20_updateFlies() {
g_fp->_floaters->_array2[idx]->ani->_priority = 200;
}
- g_vars->scene20_var05 = g_fp->_rnd->getRandomNumber(200) + 400;
+ g_vars->scene20_fliesCountdown = g_fp->_rnd->getRandomNumber(200) + 400;
}
int sceneHandler20(ExCommand *cmd) {
@@ -133,16 +128,16 @@ int sceneHandler20(ExCommand *cmd) {
if (g_fp->_aniMan2) {
int x = g_fp->_aniMan2->_ox;
- if (x < g_fp->_sceneRect.left + g_vars->scene20_var01)
- g_fp->_currentScene->_x = x - g_vars->scene20_var03 - g_fp->_sceneRect.left;
+ if (x < g_fp->_sceneRect.left + 200)
+ g_fp->_currentScene->_x = x - 300 - g_fp->_sceneRect.left;
- if (x > g_fp->_sceneRect.right - g_vars->scene20_var01)
- g_fp->_currentScene->_x = x + g_vars->scene20_var03 - g_fp->_sceneRect.right;
+ if (x > g_fp->_sceneRect.right - 200)
+ g_fp->_currentScene->_x = x + 300 - g_fp->_sceneRect.right;
}
- --g_vars->scene20_var05;
+ --g_vars->scene20_fliesCountdown;
- if (g_vars->scene20_var05 <= 0)
+ if (g_vars->scene20_fliesCountdown <= 0)
sceneHandler20_updateFlies();
g_fp->_floaters->update();