[Scummvm-cvs-logs] CVS: scummvm/scumm intern.h,2.526,2.527 room.cpp,1.23,1.24 scumm.h,1.641,1.642 vars.cpp,1.145,1.146 verbs.cpp,1.141,1.142
kirben
kirben at users.sourceforge.net
Sat Sep 24 03:16:40 CEST 2005
Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv9013/scumm
Modified Files:
intern.h room.cpp scumm.h vars.cpp verbs.cpp
Log Message:
C64 maniac handles input and verbs manually.
Index: intern.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/intern.h,v
retrieving revision 2.526
retrieving revision 2.527
diff -u -d -r2.526 -r2.527
--- intern.h 24 Sep 2005 05:26:12 -0000 2.526
+++ intern.h 24 Sep 2005 10:15:17 -0000 2.527
@@ -408,6 +408,9 @@
virtual void setupScummVars();
virtual void decodeParseString();
+ virtual void redrawVerbs();
+ virtual void checkExecVerbs();
+
virtual int getVarOrDirectWord(byte mask);
virtual uint fetchScriptWord();
Index: room.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/room.cpp,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -d -r1.23 -r1.24
--- room.cpp 16 Sep 2005 13:03:59 -0000 1.23
+++ room.cpp 24 Sep 2005 10:15:17 -0000 1.24
@@ -689,7 +689,7 @@
res.nukeResource(rtMatrix, 1);
res.nukeResource(rtMatrix, 2);
- // TODO: Different box format used
+ // TODO: Convert older walkbox format
if (_gameId == GID_MANIAC && _platform == Common::kPlatformC64)
return;
Index: scumm.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scumm.h,v
retrieving revision 1.641
retrieving revision 1.642
diff -u -d -r1.641 -r1.642
--- scumm.h 17 Sep 2005 00:24:51 -0000 1.641
+++ scumm.h 24 Sep 2005 10:15:17 -0000 1.642
@@ -814,9 +814,9 @@
int _activeObject;
virtual void handleMouseOver(bool updateInventory);
+ virtual void redrawVerbs();
+ virtual void checkExecVerbs();
- void redrawVerbs();
- void checkExecVerbs();
void verbMouseOver(int verb);
int findVerbAtPos(int x, int y) const;
virtual void drawVerb(int verb, int mode);
Index: vars.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/vars.cpp,v
retrieving revision 1.145
retrieving revision 1.146
diff -u -d -r1.145 -r1.146
--- vars.cpp 24 Sep 2005 05:26:12 -0000 1.145
+++ vars.cpp 24 Sep 2005 10:15:17 -0000 1.146
@@ -523,6 +523,10 @@
void ScummEngine_v2::initScummVars() {
+ if (_platform == Common::kPlatformC64 && _gameId == GID_MANIAC) {
+ VAR(VAR_EGO) = 3;
+ }
+
// This needs to be at least greater than 40 to get the more
// elaborate version of the EGA Zak into. I don't know where
// else it makes any difference.
Index: verbs.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/verbs.cpp,v
retrieving revision 1.141
retrieving revision 1.142
diff -u -d -r1.141 -r1.142
--- verbs.cpp 14 Sep 2005 08:20:37 -0000 1.141
+++ verbs.cpp 24 Sep 2005 10:15:17 -0000 1.142
@@ -21,6 +21,7 @@
*/
#include "common/stdafx.h"
+#include "scumm/actor.h"
#include "scumm/charset.h"
#include "scumm/intern.h"
#include "scumm/object.h"
@@ -350,6 +351,10 @@
_verbMouseOver = verb;
}
+void ScummEngine_c64::redrawVerbs() {
+ // TODO
+}
+
void ScummEngine::handleMouseOver(bool updateInventory) {
if (_completeScreenRedraw) {
verbMouseOver(0);
@@ -385,20 +390,6 @@
if (VAR_MOUSE_STATE != 0xFF)
VAR(VAR_MOUSE_STATE) = _mouseAndKeyboardStat;
- if (_platform == Common::kPlatformC64 && _gameId == GID_MANIAC) {
- // TODO
-
- int object = findObject(_mouse.x, _mouse.y);
- if (object) {
- _activeObject = object;
- runObjectScript(object, 15, false, false, NULL);
- } else {
-
- }
-
- return;
- }
-
if (_mouseAndKeyboardStat < MBS_MAX_KEY) {
/* Check keypresses */
vs = &_verbs[1];
@@ -453,6 +444,26 @@
}
}
+void ScummEngine_c64::checkExecVerbs() {
+ if (_userPut <= 0 || _mouseAndKeyboardStat == 0)
+ return;
+
+ if (_platform == Common::kPlatformC64 && _gameId == GID_MANIAC) {
+ // TODO
+
+ int object = findObject(_mouse.x, _mouse.y);
+ if (object) {
+ _activeObject = object;
+ runObjectScript(object, 15, false, false, NULL);
+ } else {
+ Actor *a = derefActor(VAR(VAR_EGO), "checkExecVerbs");
+ int y = _mouse.y;
+ int x = _mouse.x;
+ a->startWalkActor(x, y, -1);
+ }
+ }
+}
+
void ScummEngine::verbMouseOver(int verb) {
// Don't do anything unless verbs are active
if (_version <= 2 && !(_userState & 128))
More information about the Scummvm-git-logs
mailing list