aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorPaul Gilbert2018-05-05 19:31:19 -0400
committerPaul Gilbert2018-05-05 19:31:19 -0400
commit488c22631b867c7265e901333cd087f3ddf2069a (patch)
treed3ca5c3093bcd600dcda83ec9b8484e791ab76c4 /engines
parentdfbf6b7287eacdc41948a6c7b0648f4ecdaa0cbf (diff)
downloadscummvm-rg350-488c22631b867c7265e901333cd087f3ddf2069a.tar.gz
scummvm-rg350-488c22631b867c7265e901333cd087f3ddf2069a.tar.bz2
scummvm-rg350-488c22631b867c7265e901333cd087f3ddf2069a.zip
XEEN: Fix checks for whether Hp/Sp fountains can be used
Diffstat (limited to 'engines')
-rw-r--r--engines/xeen/scripts.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/engines/xeen/scripts.cpp b/engines/xeen/scripts.cpp
index 4a2e5ccb86..a243951f16 100644
--- a/engines/xeen/scripts.cpp
+++ b/engines/xeen/scripts.cpp
@@ -1814,16 +1814,16 @@ bool Scripts::ifProc(int action, uint32 val, int mode, int charIndex) {
v = ps->_ACTemp;
break;
case 78:
- // Test whether current Hp is equal to or exceeds the max HP
- v = ps->_currentHp >= ps->getMaxHP() ? 1 : 0;
+ // Test whether current Hp exceeds max HP or not
+ v = ps->_currentHp <= ps->getMaxHP() ? 1 : 0;
break;
case 79:
// Test for Wizard Eye being active
v = party._wizardEyeActive ? 1 : 0;
break;
case 81:
- // Test whether current Sp is equal to or exceeds the max SP
- v = ps->_currentSp >= ps->getMaxSP() ? 1 : 0;
+ // Test whether current Sp exceeds the max SP or not
+ v = ps->_currentSp <= ps->getMaxSP() ? 1 : 0;
break;
case 84:
// Current facing direction