diff options
author | Travis Howell | 2005-03-16 04:23:52 +0000 |
---|---|---|
committer | Travis Howell | 2005-03-16 04:23:52 +0000 |
commit | a9aed6ec52aad1cfdfaa441be8af8577c469cf07 (patch) | |
tree | 6c63772551697be429a75be4002463f0aaa988cd /scumm/verbs.cpp | |
parent | 1febad7cc57b598299293fc5a99be5f17baeb65e (diff) | |
download | scummvm-rg350-a9aed6ec52aad1cfdfaa441be8af8577c469cf07.tar.gz scummvm-rg350-a9aed6ec52aad1cfdfaa441be8af8577c469cf07.tar.bz2 scummvm-rg350-a9aed6ec52aad1cfdfaa441be8af8577c469cf07.zip |
Last line of verbs work in NES maniac now.
svn-id: r17166
Diffstat (limited to 'scumm/verbs.cpp')
-rw-r--r-- | scumm/verbs.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/scumm/verbs.cpp b/scumm/verbs.cpp index dc514cf8c2..5eb3525a5a 100644 --- a/scumm/verbs.cpp +++ b/scumm/verbs.cpp @@ -193,11 +193,12 @@ void ScummEngine::checkV2MouseOver(Common::Point pos) { } void ScummEngine::checkV2Inventory(int x, int y) { + int inventoryArea = (_features & GF_NES) ? 48: 32; int object = 0; y -= virtscr[kVerbVirtScreen].topline; - if ((y < 34) || !(_mouseButStat & MBS_LEFT_CLICK)) + if ((y < inventoryArea) || !(_mouseButStat & MBS_LEFT_CLICK)) return; if (v2_mouseover_boxes[kInventoryUpArrow].rect.contains(x, y)) { @@ -232,6 +233,7 @@ void ScummEngine::redrawV2Inventory() { int i; int max_inv; Common::Rect inventoryBox; + int inventoryArea = (_features & GF_NES) ? 48: 32; v2_mouseover_box = -1; @@ -239,7 +241,7 @@ void ScummEngine::redrawV2Inventory() { return; // Clear on all invocations - inventoryBox.top = vs->topline + 32; + inventoryBox.top = vs->topline + inventoryArea; inventoryBox.bottom = vs->topline + virtscr[2].h; inventoryBox.left = 0; inventoryBox.right = vs->w; @@ -346,10 +348,12 @@ void ScummEngine::checkExecVerbs() { } else if (_mouseButStat & MBS_MOUSE_MASK) { VirtScreen *zone = findVirtScreen(_mouse.y); byte code = _mouseButStat & MBS_LEFT_CLICK ? 1 : 2; + int inventoryArea = (_features & GF_NES) ? 48: 32; + if (_version <= 2 && zone->number == 2 && _mouse.y <= zone->topline + 8) { // Click into V2 sentence line runInputScript(5, 0, 0); - } else if (_version <= 2 && zone->number == 2 && _mouse.y > zone->topline + 32) { + } else if (_version <= 2 && zone->number == 2 && _mouse.y > zone->topline + inventoryArea) { // Click into V2 inventory checkV2Inventory(_mouse.x, _mouse.y); } else { |