aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlukaslw2014-07-30 20:50:23 +0200
committerlukaslw2014-07-30 20:50:23 +0200
commit464aea3c36ab7e7d12453cc732fc8042235744ac (patch)
treee059d6fdb2e54464ecc9984021f506bb6da5fad6
parent93a552c26d2323321356ddb9cdd3400769100617 (diff)
downloadscummvm-rg350-464aea3c36ab7e7d12453cc732fc8042235744ac.tar.gz
scummvm-rg350-464aea3c36ab7e7d12453cc732fc8042235744ac.tar.bz2
scummvm-rg350-464aea3c36ab7e7d12453cc732fc8042235744ac.zip
PRINCE: Inventory opening - mainLoop() update
-rw-r--r--engines/prince/prince.cpp30
1 files changed, 14 insertions, 16 deletions
diff --git a/engines/prince/prince.cpp b/engines/prince/prince.cpp
index 17517992be..7f51fb284e 100644
--- a/engines/prince/prince.cpp
+++ b/engines/prince/prince.cpp
@@ -4495,26 +4495,24 @@ void PrinceEngine::mainLoop() {
_frameNr++;
// inventory turning on:
- if (!_optionsFlag && _mouseFlag) {
- Common::Point mousePos = _system->getEventManager()->getMousePos();
- if (mousePos.y < 4 && !_showInventoryFlag) {
- _invCounter++;
- } else {
- _invCounter = 0;
- }
- if (_invCounter >= _invMaxCount) {
- if (_flags->getFlagValue(Flags::INVALLOWED) != 1) {
- // 29 - Basement, 50 - Map, 59 - Intro
- if (_locationNr != 29 && _locationNr != 50 && _locationNr != 59) {
- inventoryFlagChange(true);
+ if (!_optionsFlag && _mouseFlag == 1) {
+ if (_mainHero->_visible) {
+ if (!_flags->getFlagValue(Flags::INVALLOWED)) {
+ // 29 - Basement, 50 - Map
+ if (_locationNr != 29 && _locationNr != 50) {
+ Common::Point mousePos = _system->getEventManager()->getMousePos();
+ if (mousePos.y < 4 && !_showInventoryFlag) {
+ _invCounter++;
+ } else {
+ _invCounter = 0;
+ }
+ if (_invCounter >= _invMaxCount) {
+ inventoryFlagChange(true);
+ }
}
}
}
}
- if (_debugger->_locationNr != _locationNr)
- loadLocation(_debugger->_locationNr);
- if (_debugger->_cursorNr != _cursorNr)
- changeCursor(_debugger->_cursorNr);
}
}