From e26fb921e9ab814b81ba5c496c626e49f03a47a3 Mon Sep 17 00:00:00 2001 From: Bastien Bouclet Date: Mon, 29 Nov 2010 20:52:33 +0000 Subject: MOHAWK; Post rebase fixes : - Restore invoking resource change - Update the screen after drawing a conditional image svn-id: r54604 --- engines/mohawk/myst.cpp | 6 +++--- engines/mohawk/myst_areas.cpp | 11 ++++++----- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/engines/mohawk/myst.cpp b/engines/mohawk/myst.cpp index 268d9bb501..448334492c 100644 --- a/engines/mohawk/myst.cpp +++ b/engines/mohawk/myst.cpp @@ -473,14 +473,14 @@ void MohawkEngine_Myst::changeToCard(uint16 card) { error("Unknown sound action %d", soundAction); } + // Run the entrance script (if present) + runInitScript(); + // Update the images of each area too drawResourceImages(); // TODO: Handle Script Resources - // Run the entrance script (if present) - runInitScript(); - // Make sure we have the right cursor showing _curResource = -1; checkCurrentResource(); diff --git a/engines/mohawk/myst_areas.cpp b/engines/mohawk/myst_areas.cpp index 39f443cf1b..665063403f 100644 --- a/engines/mohawk/myst_areas.cpp +++ b/engines/mohawk/myst_areas.cpp @@ -92,12 +92,12 @@ MystResourceType5::MystResourceType5(MohawkEngine_Myst *vm, Common::SeekableRead void MystResourceType5::handleMouseUp(Common::Point *mouse) { -// MystResource *invoking = this; -// while (invoking->_parent) { -// invoking = invoking->_parent; -// } + MystResource *invoking = this; + while (invoking->_parent) { + invoking = invoking->_parent; + } - _vm->_scriptParser->runScript(_script, this); + _vm->_scriptParser->runScript(_script, invoking); } // In Myst/Making of Myst, the paths are hardcoded ala Windows style without extension. Convert them. @@ -448,6 +448,7 @@ void MystResourceType8::drawConditionalDataToScreen(uint16 state) { imageToDraw = _subImages[subImageId].wdib; _vm->_gfx->copyImageSectionToScreen(imageToDraw, _subImages[subImageId].rect, _rect); + _vm->_gfx->updateScreen(); } } -- cgit v1.2.3