aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2006-09-21 12:14:29 +0000
committerEugene Sandulenko2006-09-21 12:14:29 +0000
commit25a6af2c93031b26d3a7c501b9546108f8aa0b43 (patch)
tree6bf6707478c02e028c5645b9f15043cd35093981
parent965cfe40086df3274e8228a526a624b96bfc5e03 (diff)
downloadscummvm-rg350-25a6af2c93031b26d3a7c501b9546108f8aa0b43.tar.gz
scummvm-rg350-25a6af2c93031b26d3a7c501b9546108f8aa0b43.tar.bz2
scummvm-rg350-25a6af2c93031b26d3a7c501b9546108f8aa0b43.zip
Fix bug #1536932: "MANIACNES: Crash on click in speechtext-area"
svn-id: r23962
-rw-r--r--NEWS1
-rw-r--r--engines/scumm/verbs.cpp5
2 files changed, 6 insertions, 0 deletions
diff --git a/NEWS b/NEWS
index 261fd3caf0..8759253fa8 100644
--- a/NEWS
+++ b/NEWS
@@ -30,6 +30,7 @@ For a more comprehensive changelog for the latest experimental SVN code, see:
- Fixed graphical glitches in HE80 version of Putt-Putt Travels Through
Time.
- Fixed FM-TOWNS version of Indy3 failing on Amiga port.
+ - Fixed crash in MM NES when clicking on top screen area
Simon:
- Improved support for international versions of the Feeble Files.
diff --git a/engines/scumm/verbs.cpp b/engines/scumm/verbs.cpp
index c9a3ecc253..14f72de6c0 100644
--- a/engines/scumm/verbs.cpp
+++ b/engines/scumm/verbs.cpp
@@ -518,6 +518,11 @@ void ScummEngine::checkExecVerbs() {
byte code = _mouseAndKeyboardStat & MBS_LEFT_CLICK ? 1 : 2;
int inventoryArea = (_game.platform == Common::kPlatformNES) ? 48: 32;
+ // This could be kUnkVirtScreen.
+ // Fixes bug #1536932: "MANIACNES: Crash on click in speechtext-area
+ if (!zone)
+ return;
+
if (_game.version <= 2 && zone->number == kVerbVirtScreen && _mouse.y <= zone->topline + 8) {
// Click into V2 sentence line
runInputScript(5, 0, 0);