aboutsummaryrefslogtreecommitdiff
path: root/engines/fullpipe/scenes
diff options
context:
space:
mode:
authorEugene Sandulenko2014-02-19 22:46:38 +0200
committerEugene Sandulenko2014-02-19 22:46:58 +0200
commit72cc9351912c17defd7b5a5d1de4e5e1ce523f71 (patch)
tree247e11162403174d9f9179cc5ba63128a90d151b /engines/fullpipe/scenes
parent6d2f3019c7bc42e7a72491e2d3c723c471cc7c96 (diff)
downloadscummvm-rg350-72cc9351912c17defd7b5a5d1de4e5e1ce523f71.tar.gz
scummvm-rg350-72cc9351912c17defd7b5a5d1de4e5e1ce523f71.tar.bz2
scummvm-rg350-72cc9351912c17defd7b5a5d1de4e5e1ce523f71.zip
FULLPIPE: Implement sceneHandler09_showBall()
Diffstat (limited to 'engines/fullpipe/scenes')
-rw-r--r--engines/fullpipe/scenes/scene09.cpp38
1 files changed, 37 insertions, 1 deletions
diff --git a/engines/fullpipe/scenes/scene09.cpp b/engines/fullpipe/scenes/scene09.cpp
index 0679a0c374..f8a78bedff 100644
--- a/engines/fullpipe/scenes/scene09.cpp
+++ b/engines/fullpipe/scenes/scene09.cpp
@@ -305,7 +305,43 @@ void sceneHandler09_eatBall() {
}
void sceneHandler09_showBall() {
- warning("STUB: sceneHandler09_showBall()");
+ if (g_vars->scene09_var07.numBalls) {
+ StaticANIObject *ani = g_vars->scene09_var07.pHead->ani;
+ Ball *ph = g_vars->scene09_var07.pHead;
+ g_vars->scene09_var07.pHead = ph->p0;
+
+ if (g_vars->scene09_var07.pHead)
+ ph->p0->p1 = 0;
+ else
+ g_vars->scene09_var07.field_8 = 0;
+
+ ph->p0 = g_vars->scene09_var07.pTail;
+
+ g_vars->scene09_var07.pTail = ph;
+ g_vars->scene09_var07.numBalls--;
+
+ if (!g_vars->scene09_var07.numBalls) {
+ g_vars->scene09_var07.numBalls = 0;
+ g_vars->scene09_var07.pTail = 0;
+ g_vars->scene09_var07.field_8 = 0;
+ g_vars->scene09_var07.pHead = 0;
+
+ free(g_vars->scene09_var07.cPlex);
+ g_vars->scene09_var07.cPlex = 0;
+ }
+
+ Ball *ball = g_vars->scene09_balls.sub04(g_vars->scene09_balls.field_8, 0);
+ ball->ani = ani;
+
+ if (g_vars->scene09_balls.field_8)
+ g_vars->scene09_balls.field_8->p0 = ball;
+ else
+ g_vars->scene09_balls.pHead = ball;
+
+ g_vars->scene09_balls.field_8 = ball;
+
+ ani->show1(g_fp->_aniMan->_ox + 94, g_fp->_aniMan->_oy - 162, MV_BALL9_EXPLODE, 0);
+ }
}
void sceneHandler09_cycleHangers() {