FULLPIPE: Implement sceneHandler06_mumsyBallTake()

This commit is contained in:
Eugene Sandulenko 2013-12-18 18:38:08 +02:00
parent 29773ef1c0
commit db7b6b3352
6 changed files with 111 additions and 12 deletions

View File

@ -176,6 +176,16 @@ namespace Fullpipe {
#define MV_MAN6_THROWBALL 2692
#define MV_MANHDL_HANDLEDOWN 630
#define MV_MANHDL_HANDLEUP 631
#define MV_MOM_CYCLEBK 3012
#define MV_MOM_JUMPBK 662
#define MV_MOM_JUMPFW 661
#define MV_MOM_STARTBK 3010
#define MV_MOM_STOPBK 3013
#define MV_MOM_TAKE1 2885
#define MV_MOM_TAKE2 2886
#define MV_MOM_TAKE3 2887
#define MV_MOM_TAKE4 2888
#define MV_MOM_TAKE5 2889
#define MV_OTM_BOXHANDLEDOWN 626
#define MV_OTM_BOXHANDLEUP 627
#define MV_OTM_HANDLEDOWN 620
@ -259,7 +269,9 @@ namespace Fullpipe {
#define QU_KOZAW_WALK 505
#define QU_MOM_JUMPBK 671
#define QU_MOM_JUMPFW 670
#define QU_MOM_SITDOWN 685
#define QU_MOM_STANDUP 2899
#define QU_MOM_TOLIFT 2902
#define QU_PNK_CLICK 550
#define QU_SC3_ENTERLIFT 2779
#define QU_SC3_EXITLIFT 2808

View File

@ -50,7 +50,7 @@ void FullpipeEngine::initObjectStates() {
setObjectState(sO_HareTheNooksiter, getObjectEnumState(sO_HareTheNooksiter, sO_WithHandle));
setObjectState(sO_Elephantine, getObjectEnumState(sO_Elephantine, sO_WithBoot));
setObjectState(sO_Fly_12, 0);
setObjectState(sO_ClockAxis, getObjectEnumState(sO_ClockAxis, sO_NotAvailable));
setObjectState(sO_ClockAxis, getObjectEnumState(sO_ClockAxis, sO_IsNotAvailable));
setObjectState(sO_ClockHandle, getObjectEnumState(sO_ClockHandle, sO_In_7));
setObjectState(sO_BigMumsy, getObjectEnumState(sO_BigMumsy, sO_IsSleeping));
setObjectState(sO_CoinSlot_1, getObjectEnumState(sO_CoinSlot_1, sO_Empty));

View File

@ -135,7 +135,7 @@ namespace Fullpipe {
#define sO_NotGrown "\xcd\xe5 \xe2\xfb\xf0\xee\xf1" // "Не вырос"
#define sO_DidNotCrackEgg "\xcd\xe5 \xea\xee\xeb\xee\xeb \xff\xe9\xf6\xee" // "Не колол яйцо"
#define sO_NotFallen "\xcd\xe5 \xef\xe0\xe4\xe0\xeb" // "Не падал"
#define sO_NotAvailable "\xcd\xe5\xe4\xee\xf1\xf2\xf3\xef\xed\xe0" // "Недоступна"
#define sO_IsNotAvailable "\xcd\xe5\xe4\xee\xf1\xf2\xf3\xef\xed\xe0" // "Недоступна"
#define sO_CannotTake "\xcd\xe5\xeb\xfc\xe7\xff \xe2\xe7\xff\xf2\xfc" // "Нельзя взять"
#define sO_No "\xcd\xe5\xf2" // "Нет"
#define sO_LowerHatch_23 "\xcd\xe8\xe6\xed\xe8\xe9 \xeb\xfe\xea_23" // "Нижний люк_23"
@ -222,7 +222,7 @@ namespace Fullpipe {
#define sO_NearPipe "\xd3 \xf2\xf0\xf3\xe1\xfb" // "У трубы"
#define sO_Janitors "\xd3\xe1\xee\xf0\xf9\xe8\xea\xe8" // "Уборщики"
#define sO_Janitress "\xd3\xe1\xee\xf0\xf9\xe8\xf6\xe0" // "Уборщица"
#define sO_Gone "\xd3\xe5\xf5\xe0\xeb\xe0" // "Уехала"
#define sO_IsGone "\xd3\xe5\xf5\xe0\xeb\xe0" // "Уехала"
#define sO_FallenOnce "\xd3\xef\xe0\xeb \xf0\xe0\xe7" // "Упал раз"
#define sO_FallenBrush "\xd3\xef\xe0\xeb\xe0 \xf9\xe5\xf2\xea\xe0" // "Упала щетка"
#define sO_NotBroken "\xd6\xe5\xeb\xe0" // "Цела"

View File

@ -152,7 +152,7 @@ public:
int scene06_var02;
int scene06_var03;
int scene06_var04;
int scene06_var06;
StaticANIObject *scene06_var06;
StaticANIObject *scene06_invHandle;
StaticANIObject *scene06_liftButton;
StaticANIObject *scene06_ballDrop;

View File

@ -182,7 +182,7 @@ void scene04_initScene(Scene *sc) {
g_vars->scene04_bigBallCounter = 0;
g_vars->scene04_bigBallFromLeft = true;
if (g_fullpipe->getObjectState(sO_BigMumsy) != g_fullpipe->getObjectEnumState(sO_BigMumsy, sO_Gone))
if (g_fullpipe->getObjectState(sO_BigMumsy) != g_fullpipe->getObjectEnumState(sO_BigMumsy, sO_IsGone))
g_vars->scene04_mamasha->hide();
g_vars->scene04_speaker = sc->getStaticANIObject1ById(ANI_SPEAKER_4, -1);

View File

@ -73,7 +73,6 @@ void sceneHandler06_setExits(Scene *sc) {
}
void sceneHandler06_winArcade() {
warning("STUB: sceneHandler06_winArcade()");
}
void sceneHandler06_enableDrops() {
@ -93,8 +92,96 @@ void sceneHandler06_enableDrops() {
sceneHandler06_setExits(g_fullpipe->_currentScene);
}
void sceneHandler06_sub01() {
warning("STUB: sceneHandler06_sub01()");
void sceneHandler06_mumsyBallTake() {
int momAni = 0;
switch (g_vars->scene06_var13) {
case 1:
momAni = MV_MOM_TAKE1;
break;
case 2:
momAni = MV_MOM_TAKE2;
break;
case 3:
momAni = MV_MOM_TAKE3;
break;
case 4:
momAni = MV_MOM_TAKE4;
break;
case 5:
momAni = MV_MOM_TAKE5;
break;
}
MessageQueue *mq = new MessageQueue(g_fullpipe->_globalMessageQueueList->compact());
ExCommand *ex = new ExCommand(ANI_MAMASHA, 2, 50, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags = 2u;
mq->addExCommandToEnd(ex);
if (g_vars->scene06_var13 >= 5) {
g_fullpipe->setObjectState(sO_BigMumsy, g_fullpipe->getObjectEnumState(sO_BigMumsy, sO_IsGone));
if (g_fullpipe->getObjectState(sO_ClockAxis) == g_fullpipe->getObjectEnumState(sO_ClockAxis, sO_IsNotAvailable))
g_fullpipe->setObjectState(sO_ClockAxis, g_fullpipe->getObjectEnumState(sO_ClockAxis, sO_WithoutHandle));
ex = new ExCommand(ANI_MAMASHA, 1, momAni, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 2;
mq->addExCommandToEnd(ex);
if (g_vars->scene06_mumsyPos + 3 >= 0) {
ex = new ExCommand(ANI_MAMASHA, 1, MV_MOM_STARTBK, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 2u;
mq->addExCommandToEnd(ex);
for (int i = 0; i < g_vars->scene06_mumsyPos + 3; i++) {
ex = new ExCommand(ANI_MAMASHA, 1, MV_MOM_CYCLEBK, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 2;
mq->addExCommandToEnd(ex);
}
ex = new ExCommand(ANI_MAMASHA, 1, MV_MOM_STOPBK, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 2;
mq->addExCommandToEnd(ex);
}
ex = new ExCommand(0, 18, QU_MOM_TOLIFT, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 3;
mq->addExCommandToEnd(ex);
} else {
if (momAni) {
ex = new ExCommand(ANI_MAMASHA, 1, momAni, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 2;
mq->addExCommandToEnd(ex);
}
if (g_vars->scene06_mumsyPos < 0) {
for (int i = 0; i > g_vars->scene06_mumsyPos; i--) {
ex = new ExCommand(ANI_MAMASHA, 1, MV_MOM_JUMPFW, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 2;
mq->addExCommandToEnd(ex);
}
} else if (g_vars->scene06_mumsyPos > 0) {
for (int i = 0; i < g_vars->scene06_mumsyPos; i++) {
ex = new ExCommand(ANI_MAMASHA, 1, MV_MOM_JUMPBK, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 2;
mq->addExCommandToEnd(ex);
}
}
ex = new ExCommand(0, 18, QU_MOM_SITDOWN, 0, 0, 0, 1, 0, 0, 0);
ex->_excFlags |= 3u;
mq->addExCommandToEnd(ex);
}
mq->setFlags(mq->getFlags() | 1);
mq->chain(0);
g_vars->scene06_var13 = 0;
g_vars->scene06_var07 = 0;
g_fullpipe->_aniMan2 = 0;
}
void sceneHandler06_spinHandle() {
@ -398,7 +485,7 @@ int sceneHandler06(ExCommand *ex) {
if (g_vars->scene06_var13 < 5 || !g_vars->scene06_var07)
return 0;
sceneHandler06_sub01();
sceneHandler06_mumsyBallTake();
break;
case MSG_SC6_JUMPFW:
@ -575,7 +662,7 @@ int sceneHandler06(ExCommand *ex) {
&& !g_vars->scene06_ballDrop->_movement
&& !g_vars->scene06_mumsy->_movement
&& !g_vars->scene06_var16)
sceneHandler06_sub01();
sceneHandler06_mumsyBallTake();
g_fullpipe->_behaviorManager->updateBehaviors();
g_fullpipe->startSceneTrack();