diff options
author | Matthew Hoops | 2011-08-08 21:15:28 -0400 |
---|---|---|
committer | Matthew Hoops | 2011-08-08 21:15:28 -0400 |
commit | dbceb0a77d64d6e16b0186417ab92c425eddb173 (patch) | |
tree | bfedea3642ac67c0e735e2a1195dd25dd31f328e /engines | |
parent | 06b95b35439dca6a30afa9a823123343f4679feb (diff) | |
download | scummvm-rg350-dbceb0a77d64d6e16b0186417ab92c425eddb173.tar.gz scummvm-rg350-dbceb0a77d64d6e16b0186417ab92c425eddb173.tar.bz2 scummvm-rg350-dbceb0a77d64d6e16b0186417ab92c425eddb173.zip |
SCUMM: Add some HE72 differences to mouse click handling
Backyard Soccer at least requires this to have input during gameplay.
Diffstat (limited to 'engines')
-rw-r--r-- | engines/scumm/input.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/engines/scumm/input.cpp b/engines/scumm/input.cpp index 5eea7acc6b..6d9e1f3f72 100644 --- a/engines/scumm/input.cpp +++ b/engines/scumm/input.cpp @@ -324,7 +324,17 @@ void ScummEngine::processInput() { VAR(VAR_LEFTBTN_HOLD) = (_leftBtnPressed & msDown) != 0; VAR(VAR_RIGHTBTN_HOLD) = (_rightBtnPressed & msDown) != 0; - if (_game.version >= 7) { + if (_game.heversion >= 72) { + // HE72 introduced a flag for whether or not this is a click + // or the player is continuing to hold the button down. + // 0x80 signifies that the button is continuing to be held down + // Backyard Soccer needs this in order to function + if (VAR(VAR_LEFTBTN_HOLD) && !(_leftBtnPressed & msClicked)) + VAR(VAR_LEFTBTN_HOLD) |= 0x80; + + if (VAR(VAR_RIGHTBTN_HOLD) && !(_rightBtnPressed & msClicked)) + VAR(VAR_RIGHTBTN_HOLD) |= 0x80; + } else if (_game.version >= 7) { VAR(VAR_LEFTBTN_DOWN) = (_leftBtnPressed & msClicked) != 0; VAR(VAR_RIGHTBTN_DOWN) = (_rightBtnPressed & msClicked) != 0; } |