diff options
-rw-r--r-- | engines/fullpipe/behavior.cpp | 2 | ||||
-rw-r--r-- | engines/fullpipe/fullpipe.cpp | 2 | ||||
-rw-r--r-- | engines/fullpipe/input.cpp | 2 | ||||
-rw-r--r-- | engines/fullpipe/scene.cpp | 5 | ||||
-rw-r--r-- | engines/fullpipe/scenes.cpp | 4 |
5 files changed, 6 insertions, 9 deletions
diff --git a/engines/fullpipe/behavior.cpp b/engines/fullpipe/behavior.cpp index 79ef86e8c5..6bfb400c24 100644 --- a/engines/fullpipe/behavior.cpp +++ b/engines/fullpipe/behavior.cpp @@ -153,7 +153,7 @@ void BehaviorManager::updateStaticAniBehavior(StaticANIObject *ani, int delay, B uint runPercent = 0; for (int i = 0; i < bhe->_itemsCount; i++) { if (!(bhe->_items[i]->_flags & 1) && bhe->_items[i]->_percent) { - if (rnd >= runPercent && rnd <= runPercent + bhe->_items[i]->_percent || i == bhe->_itemsCount - 1) { + if ((rnd >= runPercent && rnd <= runPercent + bhe->_items[i]->_percent) || i == bhe->_itemsCount - 1) { mq = new MessageQueue(bhe->_items[i]->_messageQueue, 0, 1); break; } diff --git a/engines/fullpipe/fullpipe.cpp b/engines/fullpipe/fullpipe.cpp index 49abbabd26..5c1d19ba7b 100644 --- a/engines/fullpipe/fullpipe.cpp +++ b/engines/fullpipe/fullpipe.cpp @@ -347,7 +347,7 @@ void FullpipeEngine::updateScreen() { //if (inputArFlag) // updateGame_inputArFlag(); - if (_modalObject || _flgGameIsRunning && (_gameLoader->updateSystems(42), _modalObject != 0)) { + if (_modalObject || (_flgGameIsRunning && (_gameLoader->updateSystems(42), _modalObject != 0))) { if (_flgGameIsRunning) { if (_modalObject->init(42)) { _modalObject->update(); diff --git a/engines/fullpipe/input.cpp b/engines/fullpipe/input.cpp index 76cb17b0dd..9a25dc669c 100644 --- a/engines/fullpipe/input.cpp +++ b/engines/fullpipe/input.cpp @@ -152,7 +152,7 @@ void FullpipeEngine::updateCursorsCommon() { GameObject *ani = _currentScene->getStaticANIObjectAtPos(_mouseVirtX, _mouseVirtY); GameObject *pic = _currentScene->getPictureObjectAtPos(_mouseVirtX, _mouseVirtY); - if (!ani || pic && pic->_priority < ani->_priority ) + if (!ani || (pic && pic->_priority < ani->_priority)) ani = pic; int selId = getGameLoaderInventory()->getSelectedItemId(); diff --git a/engines/fullpipe/scene.cpp b/engines/fullpipe/scene.cpp index 891b34f196..b92b66ded6 100644 --- a/engines/fullpipe/scene.cpp +++ b/engines/fullpipe/scene.cpp @@ -337,7 +337,7 @@ PictureObject *Scene::getPictureObjectById(int objId, int flags) { PictureObject *Scene::getPictureObjectByName(const char *objName, int flags) { for (uint i = 0; i < _picObjList.size(); i++) { - if (!strcmp(((PictureObject *)_picObjList[i])->_objectName, objName) && ((PictureObject *)_picObjList[i])->_okeyCode == flags || flags == -1) + if (!strcmp(((PictureObject *)_picObjList[i])->_objectName, objName) && (((PictureObject *)_picObjList[i])->_okeyCode == flags || flags == -1)) return (PictureObject *)_picObjList[i]; } @@ -587,8 +587,6 @@ void Scene::drawContent(int minPri, int maxPri, bool drawBg) { int bgPosX = g_fullpipe->_sceneRect.left - bgOffsetX; if (bgPosX < g_fullpipe->_sceneRect.right - 1) { - int v24 = height * bgNumY; - int v51 = height * bgNumY; while (1) { int v25 = bgNumY; for (int y = g_fullpipe->_sceneRect.top - bgOffsetY; y < g_fullpipe->_sceneRect.bottom - 1;) { @@ -615,7 +613,6 @@ void Scene::drawContent(int minPri, int maxPri, bool drawBg) { } if (v32 >= g_fullpipe->_sceneRect.right - 1) break; - v24 = v51; } } } diff --git a/engines/fullpipe/scenes.cpp b/engines/fullpipe/scenes.cpp index c3cf810345..9054c4c7a7 100644 --- a/engines/fullpipe/scenes.cpp +++ b/engines/fullpipe/scenes.cpp @@ -980,7 +980,7 @@ int global_messageHandler3(ExCommand *cmd) { return result; } if (ani2->canInteractAny(pic, cmd->_keyCode)) { - if (!ani2 || ani2->isIdle() && !(ani2->_flags & 0x80) && !(ani2->_flags & 0x100)) + if (!ani2 || (ani2->isIdle() && !(ani2->_flags & 0x80) && !(ani2->_flags & 0x100))) handleObjectInteraction(ani2, pic, cmd->_keyCode); return 1; } @@ -990,7 +990,7 @@ int global_messageHandler3(ExCommand *cmd) { if (getSc2MctlCompoundBySceneId(g_fullpipe->_currentScene->_sceneId)->_isEnabled && cmd->_keyCode <= 0) { if (g_fullpipe->_msgX != cmd->_sceneClickX || g_fullpipe->_msgY != cmd->_sceneClickY) { ani = g_fullpipe->_currentScene->getStaticANIObject1ById(g_fullpipe->_gameLoader->_field_FA, -1); - if (!ani || ani->isIdle() && !(ani->_flags & 0x80) && !(ani->_flags & 0x100)) { + if (!ani || (ani->isIdle() && !(ani->_flags & 0x80) && !(ani->_flags & 0x100))) { result = startWalkTo(g_fullpipe->_gameLoader->_field_FA, -1, cmd->_sceneClickX, cmd->_sceneClickY, 0); if (result) { ExCommand *ex = new ExCommand(g_fullpipe->_gameLoader->_field_FA, 17, 64, 0, 0, 0, 1, 0, 0, 0); |