[Scummvm-cvs-logs] CVS: scummvm/scumm debugger.cpp,1.3,1.4 debugger.h,1.3,1.4

James Brown ender at users.sourceforge.net
Fri Dec 20 05:51:03 CET 2002


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1:/tmp/cvs-serv1466/scumm

Modified Files:
	debugger.cpp debugger.h 
Log Message:
Add room command to debugger


Index: debugger.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/debugger.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- debugger.cpp	16 Dec 2002 22:46:15 -0000	1.3
+++ debugger.cpp	20 Dec 2002 13:50:23 -0000	1.4
@@ -53,6 +53,7 @@
 	if (_dcmd_count < 1) {	// We need to register our commands
 		DCmd_Register("exit", &ScummDebugger::Cmd_Exit);
 		DCmd_Register("quit", &ScummDebugger::Cmd_Exit);
+		DCmd_Register("room", &ScummDebugger::Cmd_Room);
 	}
 }
 
@@ -160,7 +161,7 @@
 			DebugProc cmd;
 
 			cmd = _dcmds[i].function;
-			return (this->*cmd)();
+			return (this->*cmd)(parm);
 		}
 	}
 
@@ -245,7 +246,16 @@
 }
 
 // Commands
-bool ScummDebugger::Cmd_Exit() {
+bool ScummDebugger::Cmd_Exit(char _parameter[255][255]) {
 	_detach_now = true;
 	return false;
+}
+
+bool ScummDebugger::Cmd_Room(char _parameter[255][255]) {
+        int room = atoi(_parameter[1]);
+        _s->_actors[_s->_vars[_s->VAR_EGO]].room = room;
+        _s->startScene(room, 0, 0);
+        _s->_fullRedraw = 1;
+
+	return true;
 }

Index: debugger.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/debugger.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- debugger.h	16 Dec 2002 22:46:17 -0000	1.3
+++ debugger.h	20 Dec 2002 13:50:24 -0000	1.4
@@ -26,7 +26,7 @@
 class Scumm;
 class ScummDebugger;
 
-typedef bool (ScummDebugger::*DebugProc)();
+typedef bool (ScummDebugger::*DebugProc)(char parm[255][255]);
 
 enum {
 	DVAR_INT,
@@ -68,7 +68,8 @@
 	bool RunCommand(char *input);
 
 	// Commands
-	bool Cmd_Exit();
+	bool Cmd_Exit(char _parameter[255][255]);
+	bool Cmd_Room(char _parameter[255][255]);
 	
 #ifdef USE_CONSOLE
 	static bool ScummDebugger::debuggerInputCallback(ConsoleDialog *console, const char *input, void *refCon);





More information about the Scummvm-git-logs mailing list