From 3f7ecb9db2031012f61832da58b937b5919e5f1c Mon Sep 17 00:00:00 2001 From: Travis Howell Date: Fri, 17 Sep 2004 02:59:38 +0000 Subject: Correct mouse vars, should be mouse hold in scumm6/HE. baloon works now. svn-id: r15143 --- scumm/scumm.cpp | 10 +++++----- scumm/vars.cpp | 8 +++++--- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/scumm/scumm.cpp b/scumm/scumm.cpp index 06525cc6cc..f90a9b2442 100644 --- a/scumm/scumm.cpp +++ b/scumm/scumm.cpp @@ -2118,13 +2118,13 @@ void ScummEngine::processKbd(bool smushMode) { VAR(VAR_RIGHTBTN_HOLD) = 1; VAR(VAR_MOUSE_HOLD) += 2; } - } else if (_version >= 6 && !(_features & GF_HUMONGOUS)) { - VAR(VAR_LEFTBTN_DOWN) = (_leftBtnPressed & msClicked) != 0; - VAR(VAR_RIGHTBTN_DOWN) = (_rightBtnPressed & msClicked) != 0; + } else if (_version >= 6) { + VAR(VAR_LEFTBTN_HOLD) = (_leftBtnPressed & msDown) != 0; + VAR(VAR_RIGHTBTN_HOLD) = (_rightBtnPressed & msDown) != 0; if (_version == 7) { - VAR(VAR_LEFTBTN_HOLD) = (_leftBtnPressed & msDown) != 0; - VAR(VAR_RIGHTBTN_HOLD) = (_rightBtnPressed & msDown) != 0; + VAR(VAR_LEFTBTN_DOWN) = (_leftBtnPressed & msClicked) != 0; + VAR(VAR_RIGHTBTN_DOWN) = (_rightBtnPressed & msClicked) != 0; } } diff --git a/scumm/vars.cpp b/scumm/vars.cpp index 068232fffd..1c051fcf19 100644 --- a/scumm/vars.cpp +++ b/scumm/vars.cpp @@ -155,12 +155,12 @@ void ScummEngine_v6::setupScummVars() { VAR_V6_SCREEN_WIDTH = 41; VAR_V6_SCREEN_HEIGHT = 54; + VAR_LEFTBTN_HOLD = 74; + VAR_RIGHTBTN_HOLD = 75; + if (!(_features & GF_HUMONGOUS)) { VAR_SAVELOAD_SCRIPT = 61; VAR_SAVELOAD_SCRIPT2 = 62; - VAR_LEFTBTN_DOWN = 74; - VAR_RIGHTBTN_DOWN = 75; - } VAR_V6_EMSSPACE = 76; @@ -202,6 +202,8 @@ void ScummEngine_v72he::setupScummVars() { VAR_VIRT_MOUSE_Y = 14; VAR_MOUSE_X = 15; VAR_MOUSE_Y = 16; + VAR_LEFTBTN_HOLD = 17; + VAR_RIGHTBTN_HOLD = 18; VAR_CURSORSTATE = 19; VAR_USERPUT = 20; -- cgit v1.2.3