diff options
author | Paul Gilbert | 2018-04-05 19:48:15 -0400 |
---|---|---|
committer | Paul Gilbert | 2018-04-05 19:48:15 -0400 |
commit | a54850cae0e84089a07188f3ef264a0ab3c412c8 (patch) | |
tree | e71200a1e68891169fa2335312927430c589aff4 /engines/xeen/scripts.cpp | |
parent | 37dbd365e2cb40699a065b416db3b1cd638f63b8 (diff) | |
download | scummvm-rg350-a54850cae0e84089a07188f3ef264a0ab3c412c8.tar.gz scummvm-rg350-a54850cae0e84089a07188f3ef264a0ab3c412c8.tar.bz2 scummvm-rg350-a54850cae0e84089a07188f3ef264a0ab3c412c8.zip |
XEEN: Fix getting multiple Northern Sphinx keys
Diffstat (limited to 'engines/xeen/scripts.cpp')
-rw-r--r-- | engines/xeen/scripts.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/engines/xeen/scripts.cpp b/engines/xeen/scripts.cpp index 05b03e3a46..202bbd0a82 100644 --- a/engines/xeen/scripts.cpp +++ b/engines/xeen/scripts.cpp @@ -711,7 +711,7 @@ bool Scripts::cmdTakeOrGive(ParamsIterator ¶ms) { if (_charIndex == 0 || _charIndex == 8) { for (uint idx = 0; idx < party._activeParty.size(); ++idx) { if (_charIndex == 0 || (_charIndex == 8 && (int)idx != combat._combatTarget)) { - party.giveTake(mode1, val1, mode2, val2, idx); + bool flag = party.giveTake(mode1, val1, mode2, val2, idx); switch (mode1) { case 8: @@ -719,7 +719,7 @@ bool Scripts::cmdTakeOrGive(ParamsIterator ¶ms) { // fall through case 21: case 66: - if (param2) { + if (flag) { switch (mode2) { case 82: mode1 = 0; @@ -732,7 +732,7 @@ bool Scripts::cmdTakeOrGive(ParamsIterator ¶ms) { case 100: case 101: case 106: - if (param2) + if (flag) continue; // Break out of character loop @@ -748,7 +748,7 @@ bool Scripts::cmdTakeOrGive(ParamsIterator ¶ms) { case 100: case 101: case 106: - if (param2) { + if (flag) { _lineNum = -1; return false; } @@ -770,7 +770,7 @@ bool Scripts::cmdTakeOrGive(ParamsIterator ¶ms) { case 100: case 101: case 106: - if (param2) + if (flag) continue; // Break out of character loop |