diff options
Diffstat (limited to 'engines')
41 files changed, 248 insertions, 248 deletions
diff --git a/engines/fullpipe/anihandler.cpp b/engines/fullpipe/anihandler.cpp index 9fc586d46b..dc1e15238c 100644 --- a/engines/fullpipe/anihandler.cpp +++ b/engines/fullpipe/anihandler.cpp @@ -94,7 +94,7 @@ MessageQueue *AniHandler::makeQueue(StaticANIObject *ani, int staticsIndex, int ex = new ExCommand(ani->_id, 1, _items[idx]->subItems[subidx]->movement->_id, 0, 0, 0, 1, 0, 0, 0); } - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; ex->_field_3C = 1; ex->_field_24 = 1; @@ -350,7 +350,7 @@ MessageQueue *AniHandler::makeRunQueue(MakeQueueStruct *mkQueue) { ex2 = createCommand(s->movement, mkQueue->ani->_id, x1, y1, &x2, &y2, -1); ex2->_parId = mq->_id; - ex2->_keyCode = mkQueue->ani->_okeyCode; + ex2->_param = mkQueue->ani->_okeyCode; mq->addExCommandToEnd(ex2); @@ -367,7 +367,7 @@ MessageQueue *AniHandler::makeRunQueue(MakeQueueStruct *mkQueue) { ex2 = createCommand(mov, mkQueue->ani->_id, x1, y1, &x2, &y2, plen); ex2->_parId = mq->_id; - ex2->_keyCode = mkQueue->ani->_okeyCode; + ex2->_param = mkQueue->ani->_okeyCode; mq->addExCommandToEnd(ex2); } @@ -377,7 +377,7 @@ MessageQueue *AniHandler::makeRunQueue(MakeQueueStruct *mkQueue) { ex2 = createCommand(s->movement, mkQueue->ani->_id, x1, y1, &x2, &y2, -1); ex2->_parId = mq->_id; - ex2->_keyCode = mkQueue->ani->_okeyCode; + ex2->_param = mkQueue->ani->_okeyCode; mq->addExCommandToEnd(ex2); @@ -387,7 +387,7 @@ MessageQueue *AniHandler::makeRunQueue(MakeQueueStruct *mkQueue) { ExCommand *ex = new ExCommand(mkQueue->ani->_id, 5, -1, mkQueue->x1, mkQueue->y1, 0, 1, 0, 0, 0); ex->_field_14 = mkQueue->field_1C; - ex->_keyCode = mkQueue->ani->_okeyCode; + ex->_param = mkQueue->ani->_okeyCode; ex->_field_24 = 0; ex->_excFlags |= 3; @@ -750,7 +750,7 @@ ExCommand2 *AniHandler::createCommand(Movement *mov, int objId, int x1, int y1, ex->_messageNum = mov->_id; ex->_field_14 = len; ex->_field_24 = 1; - ex->_keyCode = -1; + ex->_param = -1; for (uint i = 0; i < cnt; i++) delete points[i]; diff --git a/engines/fullpipe/behavior.cpp b/engines/fullpipe/behavior.cpp index 92fb952605..1afa583120 100644 --- a/engines/fullpipe/behavior.cpp +++ b/engines/fullpipe/behavior.cpp @@ -181,7 +181,7 @@ void BehaviorManager::updateStaticAniBehavior(StaticANIObject *ani, int delay, B } if (mq) { - mq->replaceKeyCode(-1, ani->_okeyCode); + mq->setParamInt(-1, ani->_okeyCode); mq->chain(ani); } } diff --git a/engines/fullpipe/fullpipe.cpp b/engines/fullpipe/fullpipe.cpp index 54a77938c9..855ece1495 100644 --- a/engines/fullpipe/fullpipe.cpp +++ b/engines/fullpipe/fullpipe.cpp @@ -347,7 +347,7 @@ void FullpipeEngine::updateEvents() { } ex = new ExCommand(0, 17, 36, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = 32; + ex->_param = 32; ex->_excFlags |= 3; ex->handle(); break; @@ -359,7 +359,7 @@ void FullpipeEngine::updateEvents() { } ex = new ExCommand(0, 17, 36, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = event.kbd.keycode; + ex->_param = event.kbd.keycode; ex->_excFlags |= 3; ex->handle(); break; @@ -373,7 +373,7 @@ void FullpipeEngine::updateEvents() { getDebugger()->onFrame(); } ex = new ExCommand(0, 17, 36, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = event.kbd.keycode; + ex->_param = event.kbd.keycode; ex->_excFlags |= 3; ex->handle(); break; @@ -414,7 +414,7 @@ void FullpipeEngine::updateEvents() { ex->_sceneClickX = _sceneRect.left + ex->_x; ex->_sceneClickY = _sceneRect.top + ex->_y; - ex->_keyCode = getGameLoaderInventory()->getSelectedItemId(); + ex->_param = getGameLoaderInventory()->getSelectedItemId(); ex->_excFlags |= 3; _lastInputTicks = _updateTicks; ex->handle(); diff --git a/engines/fullpipe/gameloader.cpp b/engines/fullpipe/gameloader.cpp index ee9a7cd9a3..a013b1d302 100644 --- a/engines/fullpipe/gameloader.cpp +++ b/engines/fullpipe/gameloader.cpp @@ -398,7 +398,7 @@ bool GameLoader::preloadScene(int sceneId, int entranceId) { ExCommand *ex = new ExCommand(_preloadItems[idx]->sceneId, 17, 62, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags = 2; - ex->_keyCode = _preloadItems[idx]->keyCode; + ex->_param = _preloadItems[idx]->keyCode; _preloadSceneId = 0; _preloadEntranceId = 0; diff --git a/engines/fullpipe/interaction.cpp b/engines/fullpipe/interaction.cpp index 641d6e129e..7620f926fe 100644 --- a/engines/fullpipe/interaction.cpp +++ b/engines/fullpipe/interaction.cpp @@ -189,7 +189,7 @@ bool InteractionController::handleInteraction(StaticANIObject *subj, GameObject ex = new ExCommand((subj ? subj->_id : 0), 55, 0, 0, 0, 0, 1, 0, 0, 0); ex->_x = obj->_id; ex->_y = obj->_okeyCode; - ex->_keyCode = subj ? subj->_okeyCode : 0; + ex->_param = subj ? subj->_okeyCode : 0; ex->_excFlags = 3; ex->_field_14 = (obj->_objtype != kObjTypePictureObject); ex->_field_20 = invId; @@ -258,7 +258,7 @@ LABEL_38: if (!(inter->_flags & 0x10000)) { ex = new ExCommand(obj->_id, 34, 0x80, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = obj->_okeyCode; + ex->_param = obj->_okeyCode; ex->_field_14 = 0x100; ex->_messageNum = 0; ex->_excFlags = 3; @@ -266,14 +266,14 @@ LABEL_38: } ex = new ExCommand(obj->_id, 34, 0x100, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = obj->_okeyCode; + ex->_param = obj->_okeyCode; ex->_field_14 = 0x100; ex->_messageNum = 0; ex->_excFlags = 3; mq->addExCommandToEnd(ex); ex = new ExCommand(subj->_id, 34, 0x100, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = subj->_okeyCode; + ex->_param = subj->_okeyCode; ex->_field_14 = 0x100; ex->_messageNum = 0; ex->_excFlags = 3; @@ -281,7 +281,7 @@ LABEL_38: ex = new ExCommand(subj->_id, 17, 0x40, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3; - ex->_keyCode = 0; + ex->_param = 0; mq->addExCommandToEnd(ex); if (!mq->chain(subj)) { @@ -320,7 +320,7 @@ LABEL_38: ex = new ExCommand(subj->_id, 55, 0, 0, 0, 0, 1, 0, 0, 0); ex->_x = obj->_id; ex->_y = obj->_okeyCode; - ex->_keyCode = subj->_okeyCode; + ex->_param = subj->_okeyCode; ex->_excFlags = 3; ex->_field_20 = invId; ex->_field_14 = (obj->_objtype != kObjTypePictureObject); @@ -332,7 +332,7 @@ LABEL_38: ex->_x = xpos; ex->_y = ypos; ex->_excFlags |= 3; - ex->_keyCode = 6; + ex->_param = 6; ex->_field_14 = obj->_id; ex->_field_20 = obj->_okeyCode; ex->postMessage(); @@ -362,13 +362,13 @@ LABEL_38: } else { ex = new ExCommand(ani->_id, 34, 0x80, 0, 0, 0, 1, 0, 0, 0); ex->_field_14 = 0x80; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; ex->_excFlags = 3; mq->addExCommandToEnd(ex); } } ex = new ExCommand(ani->_id, 34, 0x100, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; ex->_field_14 = 0x100; ex->_excFlags = 3; mq->addExCommandToEnd(ex); @@ -376,7 +376,7 @@ LABEL_38: ex = new ExCommand(subj->_id, 55, 0, 0, 0, 0, 1, 0, 0, 0); ex->_x = ani->_id; ex->_y = ani->_okeyCode; - ex->_keyCode = subj->_okeyCode; + ex->_param = subj->_okeyCode; ex->_excFlags = 2; ex->_field_14 = (obj->_objtype != kObjTypePictureObject); ex->_field_20 = invId; diff --git a/engines/fullpipe/lift.cpp b/engines/fullpipe/lift.cpp index 93bfbaaa24..32a4532e36 100644 --- a/engines/fullpipe/lift.cpp +++ b/engines/fullpipe/lift.cpp @@ -240,23 +240,23 @@ void FullpipeEngine::lift_exitSeq(ExCommand *cmd) { if (!cmd) { ex = new ExCommand(_aniMan->_id, 2, 40, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = _aniMan->_okeyCode; + ex->_param = _aniMan->_okeyCode; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); } ex = new ExCommand(_lift->_id, 1, MV_LFT_OPEN, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = _lift->_okeyCode; + ex->_param = _lift->_okeyCode; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); ex = new ExCommand(_aniMan->_id, 1, MV_MAN_STARTD, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = _aniMan->_okeyCode; + ex->_param = _aniMan->_okeyCode; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); ex = new ExCommand(_aniMan->_id, 5, -1, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = _aniMan->_okeyCode; + ex->_param = _aniMan->_okeyCode; ex->_field_14 = 10; ex->_x = -1; ex->_y = -1; @@ -274,7 +274,7 @@ void FullpipeEngine::lift_exitSeq(ExCommand *cmd) { mq->addExCommandToEnd(ex); ex = new ExCommand(_lift->_id, 1, MV_LFT_CLOSE, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = _lift->_okeyCode; + ex->_param = _lift->_okeyCode; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); @@ -340,12 +340,12 @@ void FullpipeEngine::lift_walkAndGo() { mq->setFlags(mq->getFlags() | 1); ex = new ExCommand(_aniMan->_id, 2, 15, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = _aniMan->_okeyCode; + ex->_param = _aniMan->_okeyCode; ex->_excFlags |= 2; mq->addExCommand(ex); ex = new ExCommand(_aniMan->_id, 5, -1, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = _aniMan->_okeyCode; + ex->_param = _aniMan->_okeyCode; ex->_field_14 = _lift->_priority + 1; ex->_x = -1; ex->_y = -1; @@ -410,7 +410,7 @@ void FullpipeEngine::lift_goAnimation() { ExCommand *ex = new ExCommand(ANI_MAN, 1, (pre->keyCode != LiftDown ? MV_MAN_LIFTDOWN : MV_MAN_LIFTUP), 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = -1; + ex->_param = -1; ex->_field_24 = 1; ex->_excFlags |= 2; @@ -418,7 +418,7 @@ void FullpipeEngine::lift_goAnimation() { ex = new ExCommand(parentId, 17, 61, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = buttonId; + ex->_param = buttonId; ex->_excFlags |= 3; mq->addExCommandToEnd(ex); @@ -488,7 +488,7 @@ void FullpipeEngine::lift_startExitQueue() { void FullpipeEngine::lift_hoverButton(ExCommand *cmd) { if (_lastLiftButton) { - if (!(cmd->_keyCode & 2) || _liftX != cmd->_x || _liftY != cmd->_y) { + if (!(cmd->_param & 2) || _liftX != cmd->_x || _liftY != cmd->_y) { _lastLiftButton->_statics = _lastLiftButton->getStaticsById(lift_getButtonIdN(_lastLiftButton->_statics->_staticsId)); _lastLiftButton = 0; } diff --git a/engines/fullpipe/messagehandlers.cpp b/engines/fullpipe/messagehandlers.cpp index 8067b679f7..dcc7919a98 100644 --- a/engines/fullpipe/messagehandlers.cpp +++ b/engines/fullpipe/messagehandlers.cpp @@ -159,9 +159,9 @@ int global_messageHandler1(ExCommand *cmd) { } break; case 36: // keydown - g_fp->defHandleKeyDown(cmd->_keyCode); + g_fp->defHandleKeyDown(cmd->_param); - switch (cmd->_keyCode) { + switch (cmd->_param) { case '\x1B': // ESC if (g_fp->_currentScene) { getGameLoaderInventory()->unselectItem(0); @@ -221,7 +221,7 @@ int global_messageHandler1(ExCommand *cmd) { } if (newex) { - newex->_keyCode = g_fp->_aniMan->_okeyCode; + newex->_param = g_fp->_aniMan->_okeyCode; newex->_excFlags |= 3; newex->postMessage(); } @@ -286,13 +286,13 @@ int global_messageHandler2(ExCommand *cmd) { break; case 28: - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (ani) ani->_priority = cmd->_field_14; break; case 25: - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (ani) { if (cmd->_field_14) { ani->setFlags40(true); @@ -305,7 +305,7 @@ int global_messageHandler2(ExCommand *cmd) { break; case 26: - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (ani) { Movement *mov = ani->_movement; if (mov) @@ -364,13 +364,13 @@ int global_messageHandler3(ExCommand *cmd) { case 17: switch (cmd->_messageNum) { case 61: - debugC(0, kDebugEvents, "preload: { %d, %d },", cmd->_parentId, cmd->_keyCode); - return g_fp->_gameLoader->preloadScene(cmd->_parentId, cmd->_keyCode); + debugC(0, kDebugEvents, "preload: { %d, %d },", cmd->_parentId, cmd->_param); + return g_fp->_gameLoader->preloadScene(cmd->_parentId, cmd->_param); case 62: - return g_fp->_gameLoader->gotoScene(cmd->_parentId, cmd->_keyCode); + return g_fp->_gameLoader->gotoScene(cmd->_parentId, cmd->_param); case 64: if (g_fp->_currentScene && g_fp->_msgObjectId2 - && (!(cmd->_keyCode & 4) || g_fp->_msgObjectId2 != cmd->_field_14 || g_fp->_msgId != cmd->_field_20)) { + && (!(cmd->_param & 4) || g_fp->_msgObjectId2 != cmd->_field_14 || g_fp->_msgId != cmd->_field_20)) { ani = g_fp->_currentScene->getStaticANIObject1ById(g_fp->_msgObjectId2, g_fp->_msgId); if (ani) { ani->_flags &= 0xFF7F; @@ -382,11 +382,11 @@ int global_messageHandler3(ExCommand *cmd) { g_fp->_msgY = 0; g_fp->_msgObjectId2 = 0; g_fp->_msgId = 0; - if ((cmd->_keyCode & 1) || (cmd->_keyCode & 2)) { + if ((cmd->_param & 1) || (cmd->_param & 2)) { g_fp->_msgX = cmd->_x; g_fp->_msgY = cmd->_y; } - if (cmd->_keyCode & 4) { + if (cmd->_param & 4) { g_fp->_msgObjectId2 = cmd->_field_14; g_fp->_msgId = cmd->_field_20; } @@ -401,8 +401,8 @@ int global_messageHandler3(ExCommand *cmd) { cmd->_messageKind = 0; return result; } - if (canInteractAny(ani2, ani, cmd->_keyCode)) { - handleObjectInteraction(ani2, ani, cmd->_keyCode); + if (canInteractAny(ani2, ani, cmd->_param)) { + handleObjectInteraction(ani2, ani, cmd->_param); return 1; } } else { @@ -413,15 +413,15 @@ int global_messageHandler3(ExCommand *cmd) { cmd->_messageKind = 0; return result; } - if (!ani2 || canInteractAny(ani2, pic, cmd->_keyCode)) { + if (!ani2 || canInteractAny(ani2, pic, cmd->_param)) { if (!ani2 || (ani2->isIdle() && !(ani2->_flags & 0x80) && !(ani2->_flags & 0x100))) - handleObjectInteraction(ani2, pic, cmd->_keyCode); + handleObjectInteraction(ani2, pic, cmd->_param); return 1; } } } } - if (getSc2MctlCompoundBySceneId(g_fp->_currentScene->_sceneId)->_isEnabled && cmd->_keyCode <= 0) { + if (getSc2MctlCompoundBySceneId(g_fp->_currentScene->_sceneId)->_isEnabled && cmd->_param <= 0) { if (g_fp->_msgX != cmd->_sceneClickX || g_fp->_msgY != cmd->_sceneClickY) { ani = g_fp->_currentScene->getStaticANIObject1ById(g_fp->_gameLoader->_field_FA, -1); if (!ani || (ani->isIdle() && !(ani->_flags & 0x80) && !(ani->_flags & 0x100))) { @@ -430,7 +430,7 @@ int global_messageHandler3(ExCommand *cmd) { if (result) { ExCommand *ex = new ExCommand(g_fp->_gameLoader->_field_FA, 17, 64, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = 1; + ex->_param = 1; ex->_excFlags |= 3; ex->_x = cmd->_sceneClickX; ex->_y = cmd->_sceneClickY; @@ -446,7 +446,7 @@ int global_messageHandler3(ExCommand *cmd) { return result; } case 58: - g_fp->setCursor(cmd->_keyCode); + g_fp->setCursor(cmd->_param); return result; case 59: setInputDisabled(1); @@ -456,7 +456,7 @@ int global_messageHandler3(ExCommand *cmd) { return result; case 56: if (cmd->_field_2C) { - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (ani) { getGameLoaderInventory()->addItem2(ani); result = 1; @@ -492,16 +492,16 @@ int global_messageHandler3(ExCommand *cmd) { obj = g_fp->_currentScene->getStaticANIObject1ById(cmd->_x, cmd->_y); else obj = g_fp->_currentScene->getPictureObjectById(cmd->_x, cmd->_y); - handleObjectInteraction(g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode), obj, cmd->_field_20); + handleObjectInteraction(g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param), obj, cmd->_field_20); result = 1; } return result; case 51: - return startWalkTo(cmd->_parentId, cmd->_keyCode, cmd->_x, cmd->_y, cmd->_field_20); + return startWalkTo(cmd->_parentId, cmd->_param, cmd->_x, cmd->_y, cmd->_field_20); case 52: - return doSomeAnimation(cmd->_parentId, cmd->_keyCode, cmd->_field_20); + return doSomeAnimation(cmd->_parentId, cmd->_param, cmd->_field_20); case 53: - return doSomeAnimation2(cmd->_parentId, cmd->_keyCode); + return doSomeAnimation2(cmd->_parentId, cmd->_param); case 63: if (cmd->_objtype == kObjTypeObjstateCommand) { ObjstateCommand *c = (ObjstateCommand *)cmd; @@ -533,7 +533,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -544,7 +544,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -563,7 +563,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -574,7 +574,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -595,7 +595,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -616,7 +616,7 @@ int global_messageHandler4(ExCommand *cmd) { case 19: { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -634,7 +634,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -646,7 +646,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -654,7 +654,7 @@ int global_messageHandler4(ExCommand *cmd) { break; case 27: - if (!g_fp->_currentScene || g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode) == 0) { + if (!g_fp->_currentScene || g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param) == 0) { ani = g_fp->accessScene(cmd->_field_20)->getStaticANIObject1ById(cmd->_parentId, -1); if (ani) { ani = new StaticANIObject(ani); @@ -665,7 +665,7 @@ int global_messageHandler4(ExCommand *cmd) { // fall through case 5: if (g_fp->_currentScene) - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -680,7 +680,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; @@ -718,7 +718,7 @@ int global_messageHandler4(ExCommand *cmd) { if (!g_fp->_currentScene) break; - ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_keyCode); + ani = g_fp->_currentScene->getStaticANIObject1ById(cmd->_parentId, cmd->_param); if (!ani) break; diff --git a/engines/fullpipe/messages.cpp b/engines/fullpipe/messages.cpp index e9b2c40299..68ceae353b 100644 --- a/engines/fullpipe/messages.cpp +++ b/engines/fullpipe/messages.cpp @@ -68,7 +68,7 @@ bool ExCommand::load(MfcArchive &file) { _sceneClickY = file.readUint32LE(); _field_20 = file.readUint32LE(); _field_24 = file.readUint32LE(); - _keyCode = file.readUint32LE(); + _param = file.readUint32LE(); _field_2C = file.readUint32LE(); _field_30 = file.readUint32LE(); _field_34 = file.readUint32LE(); @@ -135,7 +135,7 @@ void ExCommand::setf3c(int val) { void ExCommand::firef34() { if (_field_34) { - if (_field_3C >= _keyCode) { + if (_field_3C >= _param) { _field_34 = 0; sendMessage(); @@ -192,7 +192,7 @@ Message::Message() { _sceneClickY = 0; _field_20 = 0; _field_24 = 0; - _keyCode = 0; + _param = 0; _field_2C = 0; _field_30 = 0; _field_34 = 0; @@ -208,7 +208,7 @@ Message::Message(Message *src) { _sceneClickY = src->_sceneClickY; _field_20 = src->_field_20; _field_24 = src->_field_24; - _keyCode = src->_keyCode; + _param = src->_param; _field_2C = src->_field_2C; _field_30 = src->_field_30; _field_34 = src->_field_34; @@ -224,7 +224,7 @@ Message::Message(int16 parentId, int messageKind, int x, int y, int a6, int a7, _sceneClickY = sceneClickY; _field_24 = a7; _field_20 = a10; - _keyCode = 0; + _param = 0; _field_2C = 0; _field_30 = 0; _field_34 = 0; @@ -502,7 +502,7 @@ bool MessageQueue::checkGlobalExCommandList1() { if (ex1->_messageKind != 1 && ex1->_messageKind != 20 && ex1->_messageKind != 5 && ex1->_messageKind != 27) continue; - if (ex1->_keyCode != ex->_keyCode && ex1->_keyCode != -1 && ex->_keyCode != -1) + if (ex1->_param != ex->_param && ex1->_param != -1 && ex->_param != -1) continue; MessageQueue *mq = g_fp->_globalMessageQueueList->getMessageQueueById(ex1->_parId); @@ -533,7 +533,7 @@ bool MessageQueue::checkGlobalExCommandList2() { continue; } - if (ex1->_keyCode != ex->_keyCode && ex1->_keyCode != -1 && ex->_keyCode != -1) { + if (ex1->_param != ex->_param && ex1->_param != -1 && ex->_param != -1) { it++; continue; } @@ -579,13 +579,13 @@ void MessageQueue::finish() { mq->update(); } -void MessageQueue::replaceKeyCode(int key1, int key2) { +void MessageQueue::setParamInt(int key1, int key2) { for (uint i = 0; i < getCount(); i++) { ExCommand *ex = getExCommandByIndex(i); int k = ex->_messageKind; if ((k == 1 || k == 20 || k == 5 || k == 6 || k == 2 || k == 18 || k == 19 || k == 22 || k == 55) - && ex->_keyCode == key1) - ex->_keyCode = key2; + && ex->_param == key1) + ex->_param = key2; } } @@ -617,9 +617,9 @@ void MessageQueue::changeParam28ForObjectId(int objId, int oldParam28, int newPa int k = ex->_messageKind; if ((k == 1 || k == 20 || k == 5 || k == 6 || k == 2 || k == 18 || k == 19 || k == 22 || k == 55) - && ex->_keyCode == oldParam28 + && ex->_param == oldParam28 && ex->_parentId == objId) - ex->_keyCode = newParam28; + ex->_param = newParam28; } } @@ -964,7 +964,7 @@ bool chainObjQueue(StaticANIObject *obj, int queueId, int flags) { void postExCommand(int parentId, int keyCode, int x, int y, int f20, int f14) { ExCommand *ex = new ExCommand(parentId, 17, 64, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = keyCode; + ex->_param = keyCode; ex->_excFlags |= 3; ex->_x = x; ex->_y = y; diff --git a/engines/fullpipe/messages.h b/engines/fullpipe/messages.h index 67fbb2a6cd..b99b842bf9 100644 --- a/engines/fullpipe/messages.h +++ b/engines/fullpipe/messages.h @@ -42,7 +42,7 @@ class Message : public CObject { int _sceneClickY; int _field_20; int _field_24; - int _keyCode; + int _param; int _field_2C; int _field_30; int _field_34; @@ -144,7 +144,7 @@ class MessageQueue : public CObject { void mergeQueue(MessageQueue *mq); - void replaceKeyCode(int key1, int key2); + void setParamInt(int key1, int key2); bool chain(StaticANIObject *ani); void update(); diff --git a/engines/fullpipe/modal.cpp b/engines/fullpipe/modal.cpp index 898f4c53ae..27503d4cbe 100644 --- a/engines/fullpipe/modal.cpp +++ b/engines/fullpipe/modal.cpp @@ -69,7 +69,7 @@ bool ModalIntro::handleMessage(ExCommand *message) { if (message->_messageNum != 36) return false; - if (message->_keyCode != 13 && message->_keyCode != 27 && message->_keyCode != 32) + if (message->_param != 13 && message->_param != 27 && message->_param != 32) return false; if (_stillRunning) { @@ -356,7 +356,7 @@ bool ModalMap::handleMessage(ExCommand *cmd) { return false; case 36: - if (cmd->_keyCode != 9 && cmd->_keyCode != 27) + if (cmd->_param != 9 && cmd->_param != 27) return false; break; @@ -618,7 +618,7 @@ void ModalFinal::unloadScenes() { } bool ModalFinal::handleMessage(ExCommand *cmd) { - if (cmd->_messageKind == 17 && cmd->_messageNum == 36 && cmd->_keyCode == 27) { + if (cmd->_messageKind == 17 && cmd->_messageNum == 36 && cmd->_param == 27) { g_fp->_modalObject = new ModalMainMenu(); g_fp->_modalObject->_parentObj = this; @@ -691,7 +691,7 @@ ModalCredits::~ModalCredits() { } bool ModalCredits::handleMessage(ExCommand *cmd) { - if (cmd->_messageKind == 17 && cmd->_messageNum == 36 && cmd->_keyCode == 27) { + if (cmd->_messageKind == 17 && cmd->_messageNum == 36 && cmd->_param == 27) { _fadeIn = false; return true; @@ -892,10 +892,10 @@ bool ModalMainMenu::handleMessage(ExCommand *message) { if (message->_messageNum != 36) return false; - if (message->_keyCode == 27) + if (message->_param == 27) _hoverAreaId = PIC_MNU_CONTINUE_L; else - enableDebugMenu(message->_keyCode); + enableDebugMenu(message->_param); return false; } @@ -1397,7 +1397,7 @@ bool ModalQuery::handleMessage(ExCommand *cmd) { if (_cancelBtn->isPointInside(g_fp->_mouseScreenPos.x, g_fp->_mouseScreenPos.y)) _queryResult = 0; - } else if (cmd->_messageNum == 36 && cmd->_keyCode == 27) { + } else if (cmd->_messageNum == 36 && cmd->_param == 27) { _queryResult = 0; return false; @@ -1738,7 +1738,7 @@ bool ModalSaveGame::handleMessage(ExCommand *cmd) { if (cmd->_messageNum == 29) processMouse(cmd->_x, cmd->_y); else if (cmd->_messageNum == 36) - processKey(cmd->_keyCode); + processKey(cmd->_param); return false; } diff --git a/engines/fullpipe/motion.cpp b/engines/fullpipe/motion.cpp index 6f41e94cee..a84baa64b6 100644 --- a/engines/fullpipe/motion.cpp +++ b/engines/fullpipe/motion.cpp @@ -225,7 +225,7 @@ MessageQueue *MctlCompound::startMove(StaticANIObject *ani, int sourceX, int sou ex->_excFlags |= 2; ex->_field_20 = fuzzyMatch; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); @@ -293,7 +293,7 @@ MessageQueue *MctlCompound::makeQueue(StaticANIObject *subj, int xpos, int ypos, ex = new ExCommand(subj->_id, 51, 0, xpos, ypos, 0, 1, 0, 0, 0); ex->_field_20 = fuzzyMatch; - ex->_keyCode = subj->_okeyCode; + ex->_param = subj->_okeyCode; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); @@ -542,7 +542,7 @@ MessageQueue *MctlLadder::makeQueue(StaticANIObject *ani, int xpos, int ypos, in mq = _aniHandler.makeRunQueue(&mkQueue); ex = new ExCommand(ani->_id, 1, _ladmovements[pos]->movVars->varUpStop, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; ex->_excFlags |= 2; mq->insertExCommandAt(0, ex); @@ -608,7 +608,7 @@ MessageQueue *MctlLadder::makeQueue(StaticANIObject *ani, int xpos, int ypos, in mq = _aniHandler.makeRunQueue(&mkQueue); ex = new ExCommand(ani->_id, 1, _ladmovements[pos]->movVars->varDownStop, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; ex->_excFlags |= 2; mq->insertExCommandAt(0, ex); @@ -950,13 +950,13 @@ MessageQueue *MovGraph::startMove(StaticANIObject *ani, int xpos, int ypos, int mq = new MessageQueue(g_fp->_globalMessageQueueList->compact()); ex = new ExCommand(ani->_id, 21, 0, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; ex->_field_3C = 1; ex->_field_24 = 0; mq->addExCommandToEnd(ex); ex = new ExCommand(ani->_id, 51, 0, xpos, ypos, 0, 1, 0, 0, 0); - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; ex->_field_3C = 1; ex->_field_24 = 0; ex->_field_20 = fuzzyMatch; @@ -1998,7 +1998,7 @@ MessageQueue *MctlGraph::makeWholeQueue(MctlMQ *mctlMQ) { ExCommand *ex = new ExCommand(_items2[mctlMQ->index]->_objectId, 1, mg2i->_movementId, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = _items2[mctlMQ->index]->_obj->_okeyCode; + ex->_param = _items2[mctlMQ->index]->_obj->_okeyCode; ex->_field_24 = 1; ex->_field_14 = -1; mq->addExCommandToEnd(ex); @@ -2241,21 +2241,21 @@ MessageQueue *MctlGraph::makeQueue(StaticANIObject *obj, int xpos, int ypos, int ExCommand *ex = new ExCommand(picAniInfo.objectId, 1, _items2[idx]->_subItems[idxsub]._walk[idxwalk]._movementId, 0, 0, 0, 1, 0, 0, 0); ex->_field_24 = 1; - ex->_keyCode = picAniInfo.field_8; + ex->_param = picAniInfo.field_8; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); } else { ExCommand *ex = new ExCommand(picAniInfo.objectId, 22, obj->_statics->_staticsId, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = picAniInfo.field_8; + ex->_param = picAniInfo.field_8; ex->_excFlags |= 3; mq->addExCommandToEnd(ex); ex = new ExCommand(picAniInfo.objectId, 5, -1, obj->_ox, obj->_oy, 0, 1, 0, 0, 0); ex->_field_14 = -1; - ex->_keyCode = picAniInfo.field_8; + ex->_param = picAniInfo.field_8; ex->_excFlags |= 3; mq->addExCommandToEnd(ex); } @@ -2378,13 +2378,13 @@ MessageQueue *MctlGraph::makeQueue(StaticANIObject *obj, int xpos, int ypos, int } else { ex = new ExCommand(picAniInfo.objectId, 5, ex->_messageNum, obj->_ox, obj->_oy, 0, 1, 0, 0, 0); ex->_field_14 = -1; - ex->_keyCode = picAniInfo.field_8; + ex->_param = picAniInfo.field_8; ex->_excFlags |= 2; mq->addExCommand(ex); ex = new ExCommand(picAniInfo.objectId, 22, _items2[idx]->_subItems[idxsub]._staticsId1, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = picAniInfo.field_8; + ex->_param = picAniInfo.field_8; ex->_excFlags |= 3; mq->addExCommand(ex); } @@ -2599,7 +2599,7 @@ MessageQueue *MctlGraph::makeLineQueue(MctlMQ *info) { ex->_field_14 = info->distance1; - ex->_keyCode = _items2[info->index]->_obj->_okeyCode; + ex->_param = _items2[info->index]->_obj->_okeyCode; ex->_field_24 = 1; ex->_excFlags |= 2; } else { @@ -2617,7 +2617,7 @@ MessageQueue *MctlGraph::makeLineQueue(MctlMQ *info) { ex->_field_14 = info->distance1; - ex->_keyCode = _items2[info->index]->_obj->_okeyCode; + ex->_param = _items2[info->index]->_obj->_okeyCode; ex->_field_24 = 1; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); @@ -2631,7 +2631,7 @@ MessageQueue *MctlGraph::makeLineQueue(MctlMQ *info) { &y2, -1); ex->_parId = mq->_id; - ex->_keyCode = _items2[info->index]->_obj->_okeyCode; + ex->_param = _items2[info->index]->_obj->_okeyCode; } mq->addExCommandToEnd(ex); @@ -2653,7 +2653,7 @@ MessageQueue *MctlGraph::makeLineQueue(MctlMQ *info) { &y2, par); ex->_parId = mq->_id; - ex->_keyCode = _items2[info->index]->_obj->_okeyCode; + ex->_param = _items2[info->index]->_obj->_okeyCode; mq->addExCommandToEnd(ex); } @@ -2667,7 +2667,7 @@ MessageQueue *MctlGraph::makeLineQueue(MctlMQ *info) { &y2, -1); ex->_parId = mq->_id; - ex->_keyCode = _items2[info->index]->_obj->_okeyCode; + ex->_param = _items2[info->index]->_obj->_okeyCode; mq->addExCommandToEnd(ex); } @@ -2675,7 +2675,7 @@ MessageQueue *MctlGraph::makeLineQueue(MctlMQ *info) { ex = new ExCommand(_items2[info->index]->_objectId, 5, -1, info->pt2.x, info->pt2.y, 0, 1, 0, 0, 0); ex->_field_14 = info->distance2; - ex->_keyCode = _items2[info->index]->_obj->_okeyCode; + ex->_param = _items2[info->index]->_obj->_okeyCode; ex->_field_24 = 0; ex->_excFlags |= 2; diff --git a/engines/fullpipe/scenes/scene03.cpp b/engines/fullpipe/scenes/scene03.cpp index 9c2d5e75cc..25b48dea3c 100644 --- a/engines/fullpipe/scenes/scene03.cpp +++ b/engines/fullpipe/scenes/scene03.cpp @@ -292,7 +292,7 @@ int sceneHandler03(ExCommand *ex) { if (g_vars->scene03_domino->_flags & 4) if (g_fp->_aniMan->isIdle()) if (!(g_fp->_aniMan->_flags & 0x100) && g_fp->_msgObjectId2 != g_vars->scene03_domino->_id) { - handleObjectInteraction(g_fp->_aniMan, g_vars->scene03_domino, ex->_keyCode); + handleObjectInteraction(g_fp->_aniMan, g_vars->scene03_domino, ex->_param); ex->_messageKind = 0; return 0; diff --git a/engines/fullpipe/scenes/scene04.cpp b/engines/fullpipe/scenes/scene04.cpp index cb590f1c6e..dcb737ac1c 100644 --- a/engines/fullpipe/scenes/scene04.cpp +++ b/engines/fullpipe/scenes/scene04.cpp @@ -303,14 +303,14 @@ void sceneHandler04_walkClimbLadder(ExCommand *ex) { ExCommand *ex1 = new ExCommand(ANI_MAN, 1, MV_MAN_TOLADDER, 0, 0, 0, 1, 0, 0, 0); - ex1->_keyCode = g_fp->_aniMan->_okeyCode; + ex1->_param = g_fp->_aniMan->_okeyCode; ex1->_excFlags |= 2; mq->addExCommandToEnd(ex1); ExCommand *ex2 = new ExCommand(ANI_MAN, 1, MV_MAN_STOPLADDER, 0, 0, 0, 1, 0, 0, 0); - ex2->_keyCode = g_fp->_aniMan->_okeyCode; + ex2->_param = g_fp->_aniMan->_okeyCode; ex2->_excFlags |= 2; mq->addExCommandToEnd(ex2); @@ -502,13 +502,13 @@ void sceneHandler04_gotoLadder(ExCommand *ex) { ExCommand *ex1 = new ExCommand(ANI_MAN, 1, MV_MAN_TOLADDER, 0, 0, 0, 1, 0, 0, 0); ex1->_excFlags = 2; ex1->_field_24 = 1; - ex1->_keyCode = -1; + ex1->_param = -1; mq->addExCommandToEnd(ex1); ExCommand *ex2 = new ExCommand(ANI_MAN, 1, MV_MAN_STOPLADDER, 0, 0, 0, 1, 0, 0, 0); ex2->_excFlags = 2; ex2->_field_24 = 1; - ex2->_keyCode = -1; + ex2->_param = -1; mq->addExCommandToEnd(ex2); ExCommand *ex3 = new ExCommand(g_fp->_aniMan->_id, 34, 256, 0, 0, 0, 1, 0, 0, 0); @@ -589,29 +589,29 @@ MessageQueue *sceneHandler04_kozFly3(StaticANIObject *ani, double phase) { if (mq) { ExCommand *ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_STANDUP, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_TURN, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); for (int i = 0; i < 5; i++) { ex = new ExCommand(ANI_KOZAWKA, 1, rMV_KZW_GOR, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); } ex = new ExCommand(ANI_KOZAWKA, 6, 0, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_KOZAWKA, 17, MSG_KOZAWRESTART, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); } @@ -657,29 +657,29 @@ MessageQueue *sceneHandler04_kozFly5(StaticANIObject *ani, double phase) { ExCommand *ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_STANDUP, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq1->addExCommandToEnd(ex); ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_TURN, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq1->addExCommandToEnd(ex); for (int i = 0; i < 5; i++) { ex = new ExCommand(ANI_KOZAWKA, 1, rMV_KZW_GOR, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq1->addExCommandToEnd(ex); } ex = new ExCommand(ANI_KOZAWKA, 6, 0, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq1->addExCommandToEnd(ex); ex = new ExCommand(ANI_KOZAWKA, 17, MSG_KOZAWRESTART, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq1->addExCommandToEnd(ex); } @@ -711,17 +711,17 @@ MessageQueue *sceneHandler04_kozFly6(StaticANIObject *ani) { ExCommand *ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_STANDUP, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_GOR, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_RAISEHEAD, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); g_vars->scene04_kozHeadRaised = true; @@ -771,29 +771,29 @@ MessageQueue *sceneHandler04_kozFly7(StaticANIObject *ani, double phase) { ExCommand *ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_STANDUP, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_KOZAWKA, 1, MV_KZW_TURN, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); for (int i = 0; i < 2; i++) { ex = new ExCommand(ANI_KOZAWKA, 1, rMV_KZW_GOR, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); } ex = new ExCommand(ANI_KOZAWKA, 6, 0, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_KOZAWKA, 17, MSG_KOZAWRESTART, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); } @@ -936,7 +936,7 @@ void sceneHandler04_walkKozyawka() { g_vars->scene04_kozyawkiObjList.pop_front(); MessageQueue *mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_KOZAW_WALK), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene04_walkingKozyawka->_okeyCode); + mq->setParamInt(-1, g_vars->scene04_walkingKozyawka->_okeyCode); mq->chain(0); } } @@ -1116,18 +1116,18 @@ void sceneHandler04_leaveLadder(ExCommand *ex) { if (g_fp->_aniMan->_statics->_staticsId == ST_MAN_LADDERDOWN) { ex1 = new ExCommand(ANI_MAN, 1, MV_MAN_LOOKLADDERRV, 0, 0, 0, 1, 0, 0, 0); - ex1->_keyCode = g_fp->_aniMan->_okeyCode; + ex1->_param = g_fp->_aniMan->_okeyCode; ex1->_excFlags |= 2; mq->addExCommandToEnd(ex1); } ex1 = new ExCommand(ANI_MAN, 1, MV_MAN_STARTLADDERD, 0, 0, 0, 1, 0, 0, 0); - ex1->_keyCode = g_fp->_aniMan->_okeyCode; + ex1->_param = g_fp->_aniMan->_okeyCode; ex1->_excFlags |= 2; mq->addExCommandToEnd(ex1); ex1 = new ExCommand(ANI_MAN, 1, MV_MAN_FROMLADDER, 0, 0, 0, 1, 0, 0, 0); - ex1->_keyCode = g_fp->_aniMan->_okeyCode; + ex1->_param = g_fp->_aniMan->_okeyCode; ex1->_excFlags |= 2; mq->addExCommandToEnd(ex1); @@ -1491,10 +1491,10 @@ int sceneHandler04(ExCommand *ex) { ex->_messageKind = 0; } else if (g_vars->scene04_dudeOnLadder) { sceneHandler04_leaveLadder(ex); - } else if (!ani || !canInteractAny(g_fp->_aniMan, ani, ex->_keyCode)) { + } else if (!ani || !canInteractAny(g_fp->_aniMan, ani, ex->_param)) { PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picid, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic,ex->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic,ex->_param)) { if ((g_fp->_sceneRect.right - ex->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (ex->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) g_fp->processArcade(ex); diff --git a/engines/fullpipe/scenes/scene05.cpp b/engines/fullpipe/scenes/scene05.cpp index 0135c94ecf..99a485cf15 100644 --- a/engines/fullpipe/scenes/scene05.cpp +++ b/engines/fullpipe/scenes/scene05.cpp @@ -200,7 +200,7 @@ void sceneHandler05_testHatch(ExCommand *inex) { if (g_fp->_currentScene->getStaticANIObject1ById(ANI_BIGLUK, -1)->_statics->_staticsId == ST_BLK_CLOSED) { ex = new ExCommand(SC_5, 17, 61, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = TrubaLeft; + ex->_param = TrubaLeft; ex->_excFlags |= 2; ex->postMessage(); @@ -233,7 +233,7 @@ void sceneHandler05_testHatch(ExCommand *inex) { mq->addExCommandToEnd(ex); ex = new ExCommand(SC_5, 17, 61, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = TrubaLeft; + ex->_param = TrubaLeft; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); @@ -249,7 +249,7 @@ void sceneHandler05_testHatch(ExCommand *inex) { mq->addExCommandToEnd(ex); ex = new ExCommand(SC_5, 17, 61, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = TrubaLeft; + ex->_param = TrubaLeft; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); @@ -275,7 +275,7 @@ void sceneHandler05_testHatch(ExCommand *inex) { mq->addExCommandToEnd(ex); ex = new ExCommand(SC_5, 17, 61, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = TrubaLeft; + ex->_param = TrubaLeft; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); @@ -292,7 +292,7 @@ void sceneHandler05_testHatch(ExCommand *inex) { mq->addExCommandToEnd(ex); ex = new ExCommand(SC_5, 17, 61, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = TrubaLeft; + ex->_param = TrubaLeft; ex->_excFlags |= 2; mq->addExCommandToEnd(ex); @@ -302,7 +302,7 @@ void sceneHandler05_testHatch(ExCommand *inex) { return; } else { ex = new ExCommand(SC_5, 17, 61, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = TrubaLeft; + ex->_param = TrubaLeft; ex->_excFlags |= 2; ex->postMessage(); diff --git a/engines/fullpipe/scenes/scene06.cpp b/engines/fullpipe/scenes/scene06.cpp index ac2adcdb8c..388c1d1b2c 100644 --- a/engines/fullpipe/scenes/scene06.cpp +++ b/engines/fullpipe/scenes/scene06.cpp @@ -266,7 +266,7 @@ void sceneHandler06_showNextBall() { MessageQueue *mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC6_SHOWNEXTBALL), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene06_currentBall->_okeyCode); + mq->setParamInt(-1, g_vars->scene06_currentBall->_okeyCode); mq->chain(0); ++g_vars->scene06_numBallsGiven; @@ -412,7 +412,7 @@ void sceneHandler06_fallBall() { MessageQueue *mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC6_FALLBALL), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene06_flyingBall->_okeyCode); + mq->setParamInt(-1, g_vars->scene06_flyingBall->_okeyCode); mq->chain(0); g_vars->scene06_balls.push_back(g_vars->scene06_flyingBall); @@ -665,11 +665,11 @@ int sceneHandler06(ExCommand *ex) { } } - if (!st || !canInteractAny(g_fp->_aniMan, st, ex->_keyCode)) { + if (!st || !canInteractAny(g_fp->_aniMan, st, ex->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(ex->_sceneClickX, ex->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, ex->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, ex->_param)) { if ((g_fp->_sceneRect.right - ex->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (ex->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { diff --git a/engines/fullpipe/scenes/scene08.cpp b/engines/fullpipe/scenes/scene08.cpp index 419705164c..313bf9d012 100644 --- a/engines/fullpipe/scenes/scene08.cpp +++ b/engines/fullpipe/scenes/scene08.cpp @@ -318,7 +318,7 @@ void sceneHandler08_badLuck() { ExCommand *ex = new ExCommand(g_fp->_aniMan->_id, 1, MV_MAN8_BADLUCK, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 2; - ex->_keyCode = g_fp->_aniMan->_okeyCode; + ex->_param = g_fp->_aniMan->_okeyCode; mq->addExCommandToEnd(ex); mq->setFlags(mq->getFlags() | 1); @@ -408,7 +408,7 @@ void sceneHandler08_checkEndArcade() { ExCommand *ex = new ExCommand(SC_8, 17, 0, 0, 0, 0, 1, 0, 0, 0); ex->_messageNum = 61; ex->_excFlags |= 2; - ex->_keyCode = TrubaUp; + ex->_param = TrubaUp; ex->postMessage(); } diff --git a/engines/fullpipe/scenes/scene09.cpp b/engines/fullpipe/scenes/scene09.cpp index 613149930d..3086cf0cfc 100644 --- a/engines/fullpipe/scenes/scene09.cpp +++ b/engines/fullpipe/scenes/scene09.cpp @@ -486,7 +486,7 @@ void sceneHandler09_ballExplode(Ball *ball) { MessageQueue *mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC9_BALLEXPLODE), 0, 1); - mq->replaceKeyCode(-1, ball->ani->_okeyCode); + mq->setParamInt(-1, ball->ani->_okeyCode); if (!mq->chain(ball->ani)) delete mq; @@ -723,15 +723,15 @@ int sceneHandler09(ExCommand *cmd) { } if (g_vars->scene09_dudeIsOnLadder && g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY) == PIC_SC9_LADDER_R - && !cmd->_keyCode && !g_fp->_aniMan->_movement) { + && !cmd->_param && !g_fp->_aniMan->_movement) { handleObjectInteraction(g_fp->_aniMan, g_fp->_currentScene->getPictureObjectById(PIC_SC9_LADDER_R, 0), 0); } - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) g_fp->processArcade(cmd); } diff --git a/engines/fullpipe/scenes/scene10.cpp b/engines/fullpipe/scenes/scene10.cpp index 527c942f5f..47328967d0 100644 --- a/engines/fullpipe/scenes/scene10.cpp +++ b/engines/fullpipe/scenes/scene10.cpp @@ -176,7 +176,7 @@ int sceneHandler10(ExCommand *ex) { case 29: { if (g_fp->_currentScene->getPictureObjectIdAtPos(ex->_sceneClickX, ex->_sceneClickY) == PIC_SC10_LADDER) { - handleObjectInteraction(g_fp->_aniMan, g_fp->_currentScene->getPictureObjectById(PIC_SC10_DTRUBA, 0), ex->_keyCode); + handleObjectInteraction(g_fp->_aniMan, g_fp->_currentScene->getPictureObjectById(PIC_SC10_DTRUBA, 0), ex->_param); ex->_messageKind = 0; return 0; diff --git a/engines/fullpipe/scenes/scene11.cpp b/engines/fullpipe/scenes/scene11.cpp index cdd8e5f0a0..6866dcf821 100644 --- a/engines/fullpipe/scenes/scene11.cpp +++ b/engines/fullpipe/scenes/scene11.cpp @@ -407,13 +407,13 @@ void sceneHandler11_jumpHitAndWin() { if (mq) { g_vars->scene11_crySound = SND_11_024; ExCommand *ex = new ExCommand(ANI_MAN, 2, 36, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = -1; + ex->_param = -1; ex->_excFlags = 2; mq->addExCommandToEnd(ex); ex = new ExCommand(SC_11, 17, 61, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = TrubaRight; + ex->_param = TrubaRight; ex->_excFlags = 3; mq->addExCommandToEnd(ex); @@ -750,7 +750,7 @@ int sceneHandler11(ExCommand *cmd) { case 29: if (g_vars->scene11_swingIsSwinging) { if (g_fp->_currentScene->getStaticANIObjectAtPos(g_fp->_sceneRect.left + cmd->_x, g_fp->_sceneRect.top + cmd->_y) == g_vars->scene11_swingie - && cmd->_keyCode == ANI_INV_BOOT) + && cmd->_param == ANI_INV_BOOT) sceneHandler11_putBoot(); } else { if (g_vars->scene11_arcadeIsOn) { @@ -763,11 +763,11 @@ int sceneHandler11(ExCommand *cmd) { if (!g_vars->scene11_arcadeIsOn) { StaticANIObject *ani = g_fp->_currentScene->getStaticANIObjectAtPos(cmd->_sceneClickX, cmd->_sceneClickY); - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { g_fp->processArcade(cmd); diff --git a/engines/fullpipe/scenes/scene13.cpp b/engines/fullpipe/scenes/scene13.cpp index 59be7a5e85..9908b9a7c9 100644 --- a/engines/fullpipe/scenes/scene13.cpp +++ b/engines/fullpipe/scenes/scene13.cpp @@ -313,11 +313,11 @@ int sceneHandler13(ExCommand *cmd) { { StaticANIObject *ani = g_fp->_currentScene->getStaticANIObjectAtPos(cmd->_sceneClickX, cmd->_sceneClickY); - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { diff --git a/engines/fullpipe/scenes/scene14.cpp b/engines/fullpipe/scenes/scene14.cpp index 859d832b93..adcc0b7984 100644 --- a/engines/fullpipe/scenes/scene14.cpp +++ b/engines/fullpipe/scenes/scene14.cpp @@ -143,13 +143,13 @@ void sceneHandler14_showBallGrandmaHit() { MessageQueue *mq = new MessageQueue(g_fp->_globalMessageQueueList->compact()); ExCommand *ex = new ExCommand(ANI_BALL14, 1, MV_BAL14_TOGMA, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = g_vars->scene14_flyingBall->_okeyCode; + ex->_param = g_vars->scene14_flyingBall->_okeyCode; ex->_excFlags |= 2; ex->_field_24 = 1; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_BALL14, 6, 0, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = g_vars->scene14_flyingBall->_okeyCode; + ex->_param = g_vars->scene14_flyingBall->_okeyCode; ex->_excFlags |= 3; mq->addExCommandToEnd(ex); mq->chain(0); @@ -185,13 +185,13 @@ void sceneHandler14_showBallMan() { MessageQueue *mq = new MessageQueue(g_fp->_globalMessageQueueList->compact()); ExCommand *ex = new ExCommand(ANI_BALL14, 1, MV_BAL14_TOGMA, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = g_vars->scene14_flyingBall->_okeyCode; + ex->_param = g_vars->scene14_flyingBall->_okeyCode; ex->_excFlags |= 2; ex->_field_24 = 1; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_BALL14, 6, 0, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = g_vars->scene14_flyingBall->_okeyCode; + ex->_param = g_vars->scene14_flyingBall->_okeyCode; ex->_excFlags |= 3; mq->addExCommandToEnd(ex); mq->chain(0); @@ -435,7 +435,7 @@ bool sceneHandler14_arcadeProcessClick(ExCommand *cmd) { return 0; if (!g_vars->scene14_grandmaIsHere) { - if (!cmd->_keyCode) { + if (!cmd->_param) { if (g_vars->scene14_pink) { if (g_vars->scene14_pink->_flags & 4) { if (cmd->_sceneClickX < g_vars->scene14_pink->_ox + 40) { @@ -501,13 +501,13 @@ void sceneHandler14_passToGrandma() { MessageQueue *mq = new MessageQueue(g_fp->_globalMessageQueueList->compact()); ExCommand *ex = new ExCommand(ANI_BALL14, 1, MV_BAL14_FALL, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = g_vars->scene14_flyingBall->_okeyCode; + ex->_param = g_vars->scene14_flyingBall->_okeyCode; ex->_excFlags |= 2; ex->_field_24 = 1; mq->addExCommandToEnd(ex); ex = new ExCommand(ANI_BALL14, 6, 0, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = g_vars->scene14_flyingBall->_okeyCode; + ex->_param = g_vars->scene14_flyingBall->_okeyCode; ex->_excFlags |= 3; mq->addExCommandToEnd(ex); mq->chain(0); @@ -825,12 +825,12 @@ int sceneHandler14(ExCommand *cmd) { break; } - if (!sceneHandler14_arcadeProcessClick(cmd) && (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode))) { + if (!sceneHandler14_arcadeProcessClick(cmd) && (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param))) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { g_fp->processArcade(cmd); diff --git a/engines/fullpipe/scenes/scene15.cpp b/engines/fullpipe/scenes/scene15.cpp index efc69a5fa6..436a04376d 100644 --- a/engines/fullpipe/scenes/scene15.cpp +++ b/engines/fullpipe/scenes/scene15.cpp @@ -162,7 +162,7 @@ int sceneHandler15(ExCommand *cmd) { case 29: { if (g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY) == PIC_SC15_LADDER) { - handleObjectInteraction(g_fp->_aniMan, g_fp->_currentScene->getPictureObjectById(PIC_SC15_DTRUBA, 0), cmd->_keyCode); + handleObjectInteraction(g_fp->_aniMan, g_fp->_currentScene->getPictureObjectById(PIC_SC15_DTRUBA, 0), cmd->_param); cmd->_messageKind = 0; return 0; diff --git a/engines/fullpipe/scenes/scene16.cpp b/engines/fullpipe/scenes/scene16.cpp index 5079863b4e..cb21f28103 100644 --- a/engines/fullpipe/scenes/scene16.cpp +++ b/engines/fullpipe/scenes/scene16.cpp @@ -181,7 +181,7 @@ void sceneHandler16_fillMug() { if (g_vars->scene16_walkingBoy) { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC16_BOYOUT), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene16_walkingBoy->_okeyCode); + mq->setParamInt(-1, g_vars->scene16_walkingBoy->_okeyCode); if (mq->chain(g_vars->scene16_walkingBoy)) return; } else { @@ -190,7 +190,7 @@ void sceneHandler16_fillMug() { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC16_GIRLOUT), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene16_walkingGirl->_okeyCode); + mq->setParamInt(-1, g_vars->scene16_walkingGirl->_okeyCode); if (mq->chain(g_vars->scene16_walkingGirl)) return; } @@ -208,7 +208,7 @@ void sceneHandler16_fillMug() { if (g_vars->scene16_walkingBoy) { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC16_BOYOUT), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene16_walkingBoy->_okeyCode); + mq->setParamInt(-1, g_vars->scene16_walkingBoy->_okeyCode); ani = g_vars->scene16_walkingBoy; } else { @@ -217,7 +217,7 @@ void sceneHandler16_fillMug() { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC16_GIRLOUT), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene16_walkingGirl->_okeyCode); + mq->setParamInt(-1, g_vars->scene16_walkingGirl->_okeyCode); ani = g_vars->scene16_walkingGirl; } @@ -232,7 +232,7 @@ void sceneHandler16_startLaugh() { MessageQueue *mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC16_GIRLLAUGH), 0, 1); - mq->replaceKeyCode(-1, girl->_okeyCode); + mq->setParamInt(-1, girl->_okeyCode); mq->setFlags(mq->getFlags() | 1); mq->chain(0); @@ -258,7 +258,7 @@ void sceneHandler16_drink() { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC16_BOYKICK), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene16_walkingBoy->_okeyCode); + mq->setParamInt(-1, g_vars->scene16_walkingBoy->_okeyCode); ex = new ExCommand(ANI_MAN, 34, 384, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3u; @@ -361,7 +361,7 @@ void sceneHandler16_putOnWheel() { if (ani->_id == ANI_BOY) { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC16_GOBOY), 0, 1); - mq->replaceKeyCode(-1, ani->_okeyCode); + mq->setParamInt(-1, ani->_okeyCode); mq->chain(0); g_vars->scene16_walkingBoy = ani; @@ -370,7 +370,7 @@ void sceneHandler16_putOnWheel() { if (g_fp->getObjectState(sO_Girl) == g_fp->getObjectEnumState(sO_Girl, sO_IsSwinging)) { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC16_GOGIRL), 0, 1); - mq->replaceKeyCode(-1, ani->_okeyCode); + mq->setParamInt(-1, ani->_okeyCode); mq->chain(0); g_vars->scene16_walkingBoy = 0; diff --git a/engines/fullpipe/scenes/scene17.cpp b/engines/fullpipe/scenes/scene17.cpp index f19fd030e0..3ea35b7024 100644 --- a/engines/fullpipe/scenes/scene17.cpp +++ b/engines/fullpipe/scenes/scene17.cpp @@ -211,11 +211,11 @@ int sceneHandler17(ExCommand *cmd) { int pic = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); if (pic == PIC_SC17_RTRUBA2 || pic == PIC_SC17_RTRUBA) { - if (cmd->_keyCode == ANI_INV_COIN || cmd->_keyCode == ANI_INV_BOOT || cmd->_keyCode == ANI_INV_HAMMER) { + if (cmd->_param == ANI_INV_COIN || cmd->_param == ANI_INV_BOOT || cmd->_param == ANI_INV_HAMMER) { if (g_vars->scene17_handPhase) { if (g_fp->_aniMan->isIdle()) { if (!(g_fp->_aniMan->_flags & 0x100)) { - handleObjectInteraction(g_fp->_aniMan, g_vars->scene17_hand, cmd->_keyCode); + handleObjectInteraction(g_fp->_aniMan, g_vars->scene17_hand, cmd->_param); break; } } diff --git a/engines/fullpipe/scenes/scene18and19.cpp b/engines/fullpipe/scenes/scene18and19.cpp index 5abb5a037e..e6754e4ba4 100644 --- a/engines/fullpipe/scenes/scene18and19.cpp +++ b/engines/fullpipe/scenes/scene18and19.cpp @@ -735,21 +735,21 @@ int sceneHandler18(ExCommand *cmd) { StaticANIObject *ani = g_fp->_currentScene->getStaticANIObjectAtPos(cmd->_sceneClickX, cmd->_sceneClickY); - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); if (pic && pic->_id == PIC_SC18_DOMIN && g_vars->scene18_domino && (g_vars->scene18_domino->_flags & 4) && g_fp->_aniMan->isIdle()) { if (!(g_fp->_aniMan->_flags & 0x100) && g_fp->_msgObjectId2 != g_vars->scene18_domino->_id) { - handleObjectInteraction(g_fp->_aniMan, g_vars->scene18_domino, cmd->_keyCode); + handleObjectInteraction(g_fp->_aniMan, g_vars->scene18_domino, cmd->_param); cmd->_messageKind = 0; break; } } - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { g_fp->processArcade(cmd); @@ -883,7 +883,7 @@ int sceneHandler19(ExCommand *cmd) { if (!(g_fp->_aniMan->_flags & 0x100)) { PictureObject *pic = g_fp->_currentScene->getPictureObjectById(PIC_SC19_RTRUBA31, 0); - handleObjectInteraction(g_fp->_aniMan, pic, cmd->_keyCode); + handleObjectInteraction(g_fp->_aniMan, pic, cmd->_param); break; } } diff --git a/engines/fullpipe/scenes/scene21.cpp b/engines/fullpipe/scenes/scene21.cpp index 8918515431..1b232e1aee 100644 --- a/engines/fullpipe/scenes/scene21.cpp +++ b/engines/fullpipe/scenes/scene21.cpp @@ -101,12 +101,12 @@ int sceneHandler21(ExCommand *cmd) { case 29: { StaticANIObject *ani = g_fp->_currentScene->getStaticANIObjectAtPos(cmd->_sceneClickX, cmd->_sceneClickY); - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode) ) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param) ) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) g_fp->processArcade(cmd); diff --git a/engines/fullpipe/scenes/scene22.cpp b/engines/fullpipe/scenes/scene22.cpp index 4e7c438cba..3af8bad456 100644 --- a/engines/fullpipe/scenes/scene22.cpp +++ b/engines/fullpipe/scenes/scene22.cpp @@ -166,7 +166,7 @@ void sceneHandler22_stoolLogic(ExCommand *cmd) { int manId; if (g_fp->_aniMan->isIdle() && !(g_fp->_aniMan->_flags & 0x100)) { - if (cmd->_keyCode == ANI_INV_STOOL) { + if (cmd->_param == ANI_INV_STOOL) { if (abs(841 - g_fp->_aniMan->_ox) <= 1) { if (abs(449 - g_fp->_aniMan->_oy) <= 1) { chainQueue(QU_SC22_PUTSTOOL, 1); @@ -178,7 +178,7 @@ void sceneHandler22_stoolLogic(ExCommand *cmd) { goto LABEL_13; } - if (cmd->_keyCode == ANI_INV_BOX) { + if (cmd->_param == ANI_INV_BOX) { ani = g_fp->_currentScene->getStaticANIObject1ById(ANI_TABURETTE, -1); if (!ani || !(ani->_flags & 4)) { if (abs(841 - g_fp->_aniMan->_ox) <= 1) { @@ -202,7 +202,7 @@ void sceneHandler22_stoolLogic(ExCommand *cmd) { return; } } else { - if (cmd->_keyCode) + if (cmd->_param) return; if (g_vars->scene22_dudeIsOnStool) { @@ -342,11 +342,11 @@ int sceneHandler22(ExCommand *cmd) { } if (!g_vars->scene22_dudeIsOnStool) { - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { g_fp->processArcade(cmd); diff --git a/engines/fullpipe/scenes/scene23.cpp b/engines/fullpipe/scenes/scene23.cpp index 7f7715bc65..2bb928f007 100644 --- a/engines/fullpipe/scenes/scene23.cpp +++ b/engines/fullpipe/scenes/scene23.cpp @@ -537,7 +537,7 @@ int sceneHandler23(ExCommand *cmd) { } if (ani && ani->_id == ANI_HANDLE23) { - handleObjectInteraction(g_fp->_aniMan, ani, cmd->_keyCode); + handleObjectInteraction(g_fp->_aniMan, ani, cmd->_param); cmd->_messageKind = 0; } else { sceneHandler23_fromStool(cmd); diff --git a/engines/fullpipe/scenes/scene25.cpp b/engines/fullpipe/scenes/scene25.cpp index a5fd53a819..bb05e2f197 100644 --- a/engines/fullpipe/scenes/scene25.cpp +++ b/engines/fullpipe/scenes/scene25.cpp @@ -234,7 +234,7 @@ void sceneHandler25_animateBearders() { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC25_BEARDED), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene25_bearders[0]->_okeyCode); + mq->setParamInt(-1, g_vars->scene25_bearders[0]->_okeyCode); mq->getExCommandByIndex(0)->_x = g_fp->_rnd->getRandomNumber(650) + 100; mq->chain(0); @@ -243,14 +243,14 @@ void sceneHandler25_animateBearders() { if (g_fp->_rnd->getRandomNumber(32767) < 0x1FFF) { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC25_BEARDED2), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene25_bearders[1]->_okeyCode); + mq->setParamInt(-1, g_vars->scene25_bearders[1]->_okeyCode); mq->getExCommandByIndex(0)->_x = g_fp->_rnd->getRandomNumber(650) + 100; mq->chain(0); if (g_fp->_rnd->getRandomNumber(32767) < 8191) { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC25_BEARDED3), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene25_bearders[2]->_okeyCode); + mq->setParamInt(-1, g_vars->scene25_bearders[2]->_okeyCode); mq->getExCommandByIndex(0)->_x = g_fp->_rnd->getRandomNumber(650) + 100; mq->chain(0); } @@ -522,7 +522,7 @@ void sceneHandler25_walkOnLadder(StaticANIObject *ani, Common::Point *pnt, Messa bool sceneHandler25_isOnLadder(ExCommand *cmd) { if ((g_fp->_aniMan->_movement && g_fp->_aniMan->_movement->_id == MV_MAN_GOLADDERDOWN) || g_fp->_aniMan->_statics->_staticsId == ST_MAN_GOLADDERD) { - Interaction *inter = getGameLoaderInteractionController()->getInteractionByObjectIds(PIC_SC25_LADDERDOWN, ANI_MAN, cmd->_keyCode); + Interaction *inter = getGameLoaderInteractionController()->getInteractionByObjectIds(PIC_SC25_LADDERDOWN, ANI_MAN, cmd->_param); if (!inter) return 0; @@ -656,20 +656,20 @@ int sceneHandler25(ExCommand *cmd) { if (!(g_fp->_aniMan->_flags & 0x100)) { if (ani->_id == ANI_WATER25) { if (g_vars->scene25_dudeIsOnBoard) { - if (cmd->_keyCode == ANI_INV_LOPAT) + if (cmd->_param == ANI_INV_LOPAT) sceneHandler25_rowShovel(); - if (!cmd->_keyCode) + if (!cmd->_param) sceneHandler25_rowHand(); } else { - if (cmd->_keyCode == ANI_INV_BOARD) + if (cmd->_param == ANI_INV_BOARD) sceneHandler25_putBoard(); - if (!cmd->_keyCode) + if (!cmd->_param) sceneHandler25_tryWater(); } } else if (ani->_id == ANI_BOARD25) { - sceneHandler25_tryRow(cmd->_keyCode); + sceneHandler25_tryRow(cmd->_param); break; } break; @@ -685,31 +685,31 @@ int sceneHandler25(ExCommand *cmd) { break; if (g_vars->scene25_dudeIsOnBoard) { - if (picId == PIC_SC25_RTRUBA && !cmd->_keyCode) { + if (picId == PIC_SC25_RTRUBA && !cmd->_param) { sceneHandler25_enterTruba(); break; } } else { if (picId != PIC_SC25_RTRUBA) { - if (picId == PIC_SC25_LADDERUP && !cmd->_keyCode) + if (picId == PIC_SC25_LADDERUP && !cmd->_param) sceneHandler25_ladderUp(); break; } - if (!cmd->_keyCode) { + if (!cmd->_param) { sceneHandler25_backToPipe(); break; } } if (g_vars->scene25_dudeIsOnBoard) { - if (picId != PIC_SC25_LADDERUP || cmd->_keyCode) + if (picId != PIC_SC25_LADDERUP || cmd->_param) break; sceneHandler25_toLadder(); break; } - if (picId == PIC_SC25_LADDERUP && !cmd->_keyCode) + if (picId == PIC_SC25_LADDERUP && !cmd->_param) sceneHandler25_ladderUp(); break; diff --git a/engines/fullpipe/scenes/scene26.cpp b/engines/fullpipe/scenes/scene26.cpp index e8a0261524..df7accc959 100644 --- a/engines/fullpipe/scenes/scene26.cpp +++ b/engines/fullpipe/scenes/scene26.cpp @@ -263,7 +263,7 @@ void sceneHandler26_clickVent(StaticANIObject *ani, ExCommand *cmd) { ExCommand *ex = new ExCommand(0, 17, MSG_SC26_CLICKVENT, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags |= 3; - ex->_keyCode = ani->_okeyCode; + ex->_param = ani->_okeyCode; mq->addExCommandToEnd(ex); @@ -309,7 +309,7 @@ int sceneHandler26(ExCommand *cmd) { case MSG_SC26_CLICKVENT: { - StaticANIObject *ani = g_fp->_currentScene->getStaticANIObject1ById(ANI_VENT, cmd->_keyCode); + StaticANIObject *ani = g_fp->_currentScene->getStaticANIObject1ById(ANI_VENT, cmd->_param); if (ani && ani->_id == ANI_VENT) sceneHandler26_clickVent(ani, cmd); diff --git a/engines/fullpipe/scenes/scene27.cpp b/engines/fullpipe/scenes/scene27.cpp index 420629cf9c..c8a7bae4c7 100644 --- a/engines/fullpipe/scenes/scene27.cpp +++ b/engines/fullpipe/scenes/scene27.cpp @@ -191,7 +191,7 @@ void sceneHandler27_showNextBat() { if (g_vars->scene27_bat) { MessageQueue *mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC27_SHOWBET), 0, 1); - mq->replaceKeyCode(-1, g_vars->scene27_bat->_okeyCode); + mq->setParamInt(-1, g_vars->scene27_bat->_okeyCode); mq->chain(0); } diff --git a/engines/fullpipe/scenes/scene28.cpp b/engines/fullpipe/scenes/scene28.cpp index 75ba2567b2..f096e6964b 100644 --- a/engines/fullpipe/scenes/scene28.cpp +++ b/engines/fullpipe/scenes/scene28.cpp @@ -105,16 +105,16 @@ void sceneHandler28_trySecondaryPers() { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_BRD28_GOR), 0, 1); mq->getExCommandByIndex(0)->_x = g_fp->_sceneRect.left - 20; - mq->getExCommandByIndex(0)->_keyCode = 1; - mq->replaceKeyCode(-1, 1); + mq->getExCommandByIndex(0)->_param = 1; + mq->setParamInt(-1, 1); mq->chain(0); mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_BRD28_GOR), 0, 1); mq->getExCommandByIndex(0)->_x = g_fp->_sceneRect.left - 40; mq->getExCommandByIndex(0)->_y += 20; - mq->getExCommandByIndex(0)->_keyCode = 2; - mq->replaceKeyCode(-1, 2); + mq->getExCommandByIndex(0)->_param = 2; + mq->setParamInt(-1, 2); mq->chain(0); mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_BRD28_GOR), 0, 1); @@ -124,16 +124,16 @@ void sceneHandler28_trySecondaryPers() { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_BRD28_GOL), 0, 1); mq->getExCommandByIndex(0)->_x = g_fp->_sceneRect.right + 20; - mq->getExCommandByIndex(0)->_keyCode = 1; - mq->replaceKeyCode(-1, 1); + mq->getExCommandByIndex(0)->_param = 1; + mq->setParamInt(-1, 1); mq->chain(0); mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_BRD28_GOL), 0, 1); mq->getExCommandByIndex(0)->_x = g_fp->_sceneRect.right + 40; mq->getExCommandByIndex(0)->_y += 20; - mq->getExCommandByIndex(0)->_keyCode = 2; - mq->replaceKeyCode(-1, 2); + mq->getExCommandByIndex(0)->_param = 2; + mq->setParamInt(-1, 2); mq->chain(0); mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_BRD28_GOL), 0, 1); @@ -143,8 +143,8 @@ void sceneHandler28_trySecondaryPers() { mq->getExCommandByIndex(0)->_x = x; mq->getExCommandByIndex(0)->_y += 40; - mq->getExCommandByIndex(0)->_keyCode = 3; - mq->replaceKeyCode(-1, 3); + mq->getExCommandByIndex(0)->_param = 3; + mq->setParamInt(-1, 3); mq->chain( 0); g_vars->scene28_beardedDirection = !g_vars->scene28_beardedDirection; @@ -381,7 +381,7 @@ int sceneHandler28(ExCommand *cmd) { break; case MSG_SC28_CLICKLIFT: - sceneHandler28_clickLift(cmd->_keyCode); + sceneHandler28_clickLift(cmd->_param); break; case MSG_SC28_ENDLIFT1: @@ -411,11 +411,11 @@ int sceneHandler28(ExCommand *cmd) { break; } - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) g_fp->processArcade(cmd); diff --git a/engines/fullpipe/scenes/scene29.cpp b/engines/fullpipe/scenes/scene29.cpp index 28d06964a9..80f82e09cd 100644 --- a/engines/fullpipe/scenes/scene29.cpp +++ b/engines/fullpipe/scenes/scene29.cpp @@ -510,7 +510,7 @@ void sceneHandler29_manHit() { if (g_vars->scene29_manX <= 638) { ex = new ExCommand(ANI_MAN, 1, MV_MAN29_STANDUP_NORM, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags = 2; - ex->_keyCode = g_fp->_aniMan->_okeyCode; + ex->_param = g_fp->_aniMan->_okeyCode; mq->addExCommandToEnd(ex); ex = new ExCommand(0, 17, MSG_SC29_STOPRIDE, 0, 0, 0, 1, 0, 0, 0); @@ -524,7 +524,7 @@ void sceneHandler29_manHit() { } else { ex = new ExCommand(ANI_MAN, 1, MV_MAN29_STANDUP, 0, 0, 0, 1, 0, 0, 0); ex->_excFlags = 2; - ex->_keyCode = g_fp->_aniMan->_okeyCode; + ex->_param = g_fp->_aniMan->_okeyCode; mq->addExCommandToEnd(ex); } @@ -878,7 +878,7 @@ void sceneHandler29_animBearded() { if (x - g_vars->scene29_manX < 100 || !g_vars->scene29_arcadeIsOn) { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC29_BRDOUT1), 0, 1); - mq->replaceKeyCode(-1, ani->_okeyCode); + mq->setParamInt(-1, ani->_okeyCode); mq->chain(0); g_vars->scene29_bearders[i]->wbflag = 0; @@ -898,7 +898,7 @@ void sceneHandler29_animBearded() { mq = new MessageQueue(g_fp->_currentScene->getMessageQueueById(QU_SC29_BRDOUT2), 0, 1); - mq->replaceKeyCode(-1, ani->_okeyCode); + mq->setParamInt(-1, ani->_okeyCode); mq->chain(0); g_vars->scene29_bearders[i]->wbflag = 0; @@ -939,7 +939,7 @@ void sceneHandler29_animBearded() { } mq->getExCommandByIndex(0)->_x = newx; - mq->replaceKeyCode(-1, ani->_okeyCode); + mq->setParamInt(-1, ani->_okeyCode); mq->chain(0); g_vars->scene29_bearders[i]->wbflag = 1; diff --git a/engines/fullpipe/scenes/scene32.cpp b/engines/fullpipe/scenes/scene32.cpp index 05b78efb3d..1766d790b8 100644 --- a/engines/fullpipe/scenes/scene32.cpp +++ b/engines/fullpipe/scenes/scene32.cpp @@ -185,7 +185,7 @@ void sceneHandler32_trySit(ExCommand *cmd) { ex->_parentId = ANI_MAN; ex->_messageKind = 1; ex->_messageNum = MV_MAN32_SITDOWN; - ex->_keyCode = g_fp->_aniMan->_okeyCode; + ex->_param = g_fp->_aniMan->_okeyCode; g_vars->scene32_dudeIsSitting = true; diff --git a/engines/fullpipe/scenes/scene33.cpp b/engines/fullpipe/scenes/scene33.cpp index 90ea0a4f3f..f9fdcdf9cc 100644 --- a/engines/fullpipe/scenes/scene33.cpp +++ b/engines/fullpipe/scenes/scene33.cpp @@ -270,7 +270,7 @@ int sceneHandler33(ExCommand *cmd) { { StaticANIObject *ani = g_fp->_currentScene->getStaticANIObjectAtPos(g_fp->_sceneRect.left + cmd->_x, g_fp->_sceneRect.top + cmd->_y); - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); @@ -279,7 +279,7 @@ int sceneHandler33(ExCommand *cmd) { break; } - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) g_fp->processArcade(cmd); } diff --git a/engines/fullpipe/scenes/scene34.cpp b/engines/fullpipe/scenes/scene34.cpp index 32fb192756..6b74551e49 100644 --- a/engines/fullpipe/scenes/scene34.cpp +++ b/engines/fullpipe/scenes/scene34.cpp @@ -337,7 +337,7 @@ int sceneHandler34(ExCommand *cmd) { g_fp->_aniMan->changeStatics2(ST_MAN_RIGHT); g_fp->_aniMan->_flags &= 0xFEFF; - getGameLoaderInteractionController()->handleInteraction(g_fp->_aniMan, g_vars->scene34_vent, cmd->_keyCode); + getGameLoaderInteractionController()->handleInteraction(g_fp->_aniMan, g_vars->scene34_vent, cmd->_param); break; @@ -419,8 +419,8 @@ int sceneHandler34(ExCommand *cmd) { StaticANIObject *ani = g_fp->_currentScene->getStaticANIObjectAtPos(g_fp->_sceneRect.left + cmd->_x, g_fp->_sceneRect.top + cmd->_y); if (ani) { - if ((ani->_id == ANI_STOOL_34 && cmd->_keyCode == ANI_INV_BOX) || (ani->_id == ANI_BOX_34 && cmd->_keyCode == ANI_INV_STOOL)) { - getGameLoaderInteractionController()->handleInteraction(g_fp->_aniMan, g_vars->scene34_vent, cmd->_keyCode); + if ((ani->_id == ANI_STOOL_34 && cmd->_param == ANI_INV_BOX) || (ani->_id == ANI_BOX_34 && cmd->_param == ANI_INV_STOOL)) { + getGameLoaderInteractionController()->handleInteraction(g_fp->_aniMan, g_vars->scene34_vent, cmd->_param); cmd->_messageKind = 0; } @@ -434,11 +434,11 @@ int sceneHandler34(ExCommand *cmd) { } } - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { g_fp->processArcade(cmd); break; diff --git a/engines/fullpipe/scenes/scene35.cpp b/engines/fullpipe/scenes/scene35.cpp index 53381fd555..7a290ade3b 100644 --- a/engines/fullpipe/scenes/scene35.cpp +++ b/engines/fullpipe/scenes/scene35.cpp @@ -213,11 +213,11 @@ int sceneHandler35(ExCommand *cmd) { break; } - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { g_fp->processArcade(cmd); break; diff --git a/engines/fullpipe/scenes/scene36.cpp b/engines/fullpipe/scenes/scene36.cpp index 44099faba0..c93fca2cac 100644 --- a/engines/fullpipe/scenes/scene36.cpp +++ b/engines/fullpipe/scenes/scene36.cpp @@ -64,7 +64,7 @@ int sceneHandler36(ExCommand *cmd) { if (g_vars->scene36_scissors->_flags & 4) if (g_fp->_aniMan->isIdle()) if (!(g_fp->_aniMan->_flags & 0x100) && g_fp->_msgObjectId2 != g_vars->scene36_scissors->_id ) { - handleObjectInteraction(g_fp->_aniMan, g_vars->scene36_scissors, cmd->_keyCode); + handleObjectInteraction(g_fp->_aniMan, g_vars->scene36_scissors, cmd->_param); cmd->_messageKind = 0; } diff --git a/engines/fullpipe/scenes/scene37.cpp b/engines/fullpipe/scenes/scene37.cpp index 324d3ac92d..0e5685f4a9 100644 --- a/engines/fullpipe/scenes/scene37.cpp +++ b/engines/fullpipe/scenes/scene37.cpp @@ -234,11 +234,11 @@ int sceneHandler37(ExCommand *cmd) { { StaticANIObject *ani = g_fp->_currentScene->getStaticANIObjectAtPos(cmd->_sceneClickX, cmd->_sceneClickY); - if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_keyCode)) { + if (!ani || !canInteractAny(g_fp->_aniMan, ani, cmd->_param)) { int picId = g_fp->_currentScene->getPictureObjectIdAtPos(cmd->_sceneClickX, cmd->_sceneClickY); PictureObject *pic = g_fp->_currentScene->getPictureObjectById(picId, 0); - if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_keyCode)) { + if (!pic || !canInteractAny(g_fp->_aniMan, pic, cmd->_param)) { if ((g_fp->_sceneRect.right - cmd->_sceneClickX < 47 && g_fp->_sceneRect.right < g_fp->_sceneWidth - 1) || (cmd->_sceneClickX - g_fp->_sceneRect.left < 47 && g_fp->_sceneRect.left > 0)) { g_fp->processArcade(cmd); diff --git a/engines/fullpipe/sound.cpp b/engines/fullpipe/sound.cpp index 635ac0acbd..15427c6644 100644 --- a/engines/fullpipe/sound.cpp +++ b/engines/fullpipe/sound.cpp @@ -489,7 +489,7 @@ void global_messageHandler_handleSound(ExCommand *cmd) { snd->setPanAndVolume(g_fp->_sfxVolume, 0); if (snd->getVolume() > -3500) - snd->play(cmd->_keyCode); + snd->play(cmd->_param); } else if (cmd->_field_14 & 2) { snd->stop(); } diff --git a/engines/fullpipe/statics.cpp b/engines/fullpipe/statics.cpp index ec834a9631..39bd2965d0 100644 --- a/engines/fullpipe/statics.cpp +++ b/engines/fullpipe/statics.cpp @@ -824,7 +824,7 @@ void StaticANIObject::update(int counterdiff) { newex->_excFlags |= 2; if (newex->_messageKind == 17) { newex->_parentId = _id; - newex->_keyCode = _okeyCode; + newex->_param = _okeyCode; } newex->sendMessage(); @@ -836,7 +836,7 @@ void StaticANIObject::update(int counterdiff) { if (dyn->_initialCountdown == dyn->_countdown && dyn->_field_68 != 0) { newex = new ExCommand(_id, 17, dyn->_field_68, 0, 0, 0, 1, 0, 0, 0); newex->_excFlags = 2; - newex->_keyCode = _okeyCode; + newex->_param = _okeyCode; newex->sendMessage(); if (!_movement) @@ -1006,7 +1006,7 @@ L12: _movement = 0; ExCommand *ex = new ExCommand(_id, 17, 24, 0, 0, 0, 1, 0, 0, 0); - ex->_keyCode = _okeyCode; + ex->_param = _okeyCode; ex->_excFlags = 2; ex->postMessage(); } @@ -1274,7 +1274,7 @@ void StaticANIObject::startAnimSteps(int movementId, int messageQueueId, int x, ExCommand *ex = new ExCommand(_id, 17, 23, 0, 0, movementId, 1, 0, 0, 0); - ex->_keyCode = _okeyCode; + ex->_param = _okeyCode; ex->_excFlags = 2; ex->postMessage(); } @@ -1386,7 +1386,7 @@ bool StaticANIObject::startAnim(int movementId, int messageQueueId, int dynPhase ExCommand *newex = new ExCommand(_id, 17, 23, 0, 0, movementId, 1, 0, 0, 0); - newex->_keyCode = _okeyCode; + newex->_param = _okeyCode; newex->_excFlags = 2; newex->postMessage(); |