diff options
author | Eugene Sandulenko | 2007-04-22 16:17:14 +0000 |
---|---|---|
committer | Eugene Sandulenko | 2007-04-22 16:17:14 +0000 |
commit | f01fbb846751797e4a897a0c203349273a0215e5 (patch) | |
tree | c2850bd50ef3085871ca6619d315a89e4cbe3553 | |
parent | 55152e40554003f965e8fa4bca76a720bbb61de7 (diff) | |
download | scummvm-rg350-f01fbb846751797e4a897a0c203349273a0215e5.tar.gz scummvm-rg350-f01fbb846751797e4a897a0c203349273a0215e5.tar.bz2 scummvm-rg350-f01fbb846751797e4a897a0c203349273a0215e5.zip |
Patch from bugreport #1678230: "AGI: Entering text while screen is shaking"
svn-id: r26568
-rw-r--r-- | engines/agi/op_cmd.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/engines/agi/op_cmd.cpp b/engines/agi/op_cmd.cpp index f9017da320..d55963f670 100644 --- a/engines/agi/op_cmd.cpp +++ b/engines/agi/op_cmd.cpp @@ -1233,8 +1233,14 @@ cmd(shake_screen) { if ((g_agi->getFeatures() & GF_AGIPAL) && p0 >= 101 && p0 < 110) { g_gfx->setAGIPal(p0); return; - } else - g_gfx->shakeStart(); + } + + // Disables input while shaking to prevent bug + // #1678230: AGI: Entering text while screen is shaking + int originalValue = game.inputEnabled; + game.inputEnabled = 0; + + g_gfx->shakeStart(); g_sprites->commitBoth(); /* Fixes SQ1 demo */ for (i = 4 * p0; i; i--) { @@ -1243,6 +1249,9 @@ cmd(shake_screen) { g_agi->mainCycle(); } g_gfx->shakeEnd(); + + //Sets input back to what it was + game.inputEnabled = originalValue; } static void (*agiCommand[183])(uint8 *) = { |