[Scummvm-cvs-logs] CVS: scummvm/queen command.cpp,1.48,1.49 cutaway.cpp,1.92,1.93 display.cpp,1.39,1.40 display.h,1.29,1.30 input.cpp,1.17,1.18 logic.cpp,1.145,1.146 talk.cpp,1.63,1.64

Joost Peters joostp at users.sourceforge.net
Mon Dec 29 13:06:03 CET 2003


Update of /cvsroot/scummvm/scummvm/queen
In directory sc8-pr-cvs1:/tmp/cvs-serv10828/queen

Modified Files:
	command.cpp cutaway.cpp display.cpp display.h input.cpp 
	logic.cpp talk.cpp 
Log Message:
mass debuglevel change for less verbosity (0 -> 6)
importance/relevance has to be decided on an individual basis, if needed, later on


Index: command.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/command.cpp,v
retrieving revision 1.48
retrieving revision 1.49
diff -u -d -r1.48 -r1.49
--- command.cpp	29 Dec 2003 20:18:31 -0000	1.48
+++ command.cpp	29 Dec 2003 21:05:33 -0000	1.49
@@ -163,7 +163,7 @@
 		}
 	}
 
-	debug(0, "Command::executeCurrentAction() - comMax=%d subj1=%X subj2=%X", comMax, _state.subject[0], _state.subject[1]);
+	debug(6, "Command::executeCurrentAction() - comMax=%d subj1=%X subj2=%X", comMax, _state.subject[0], _state.subject[1]);
 
 	if (comMax == 0) {
 		sayInvalidAction(_state.selAction, _state.subject[0], _state.subject[1]);
@@ -317,7 +317,7 @@
 
 int16 Command::executeCommand(uint16 comId, int16 condResult) {
 	// execute.c l.313-452
-	debug(0, "Command::executeCommand() - cond = %X, com = %X", condResult, comId);
+	debug(6, "Command::executeCommand() - cond = %X, com = %X", condResult, comId);
 
 	CmdListData *com = &_cmdList[comId];
 
@@ -462,7 +462,7 @@
 		_vm->logic()->newRoom(0);
 	}
 
-	debug(0, "Command::makeJoeWalkTo() - x=%d y=%d newRoom=%d", x, y, _vm->logic()->newRoom());
+	debug(6, "Command::makeJoeWalkTo() - x=%d y=%d newRoom=%d", x, y, _vm->logic()->newRoom());
 
 	int16 p = 0;
 	if (mustWalk) {
@@ -966,7 +966,7 @@
 		}
 	}
 
-	debug(0, "Command::openOrCloseAssociatedObject() - com=%X", com);
+	debug(6, "Command::openOrCloseAssociatedObject() - com=%X", com);
 
 	if (com != 0) {
 
@@ -1011,7 +1011,7 @@
 		if (cmdGs->id == command) {
 			if (cmdGs->gameStateSlot > 0) {
 				if (_vm->logic()->gameState(cmdGs->gameStateSlot) != cmdGs->gameStateValue) {
-					debug(0, "Command::setConditions() - GS[%d] == %d (should be %d)", cmdGs->gameStateSlot, _vm->logic()->gameState(cmdGs->gameStateSlot), cmdGs->gameStateValue);
+					debug(6, "Command::setConditions() - GS[%d] == %d (should be %d)", cmdGs->gameStateSlot, _vm->logic()->gameState(cmdGs->gameStateSlot), cmdGs->gameStateValue);
 					// failed test
 					ret = i;
 					break;
@@ -1083,7 +1083,7 @@
 			uint16 dstObj = ABS(cmdObj->dstObj);
 			ObjectData *objData = _vm->logic()->objectData(dstObj);
 
-			debug(0, "Command::setObjects() - dstObj=%X srcObj=%X _state.subject[0]=%X", cmdObj->dstObj, cmdObj->srcObj, _state.subject[0]);
+			debug(6, "Command::setObjects() - dstObj=%X srcObj=%X _state.subject[0]=%X", cmdObj->dstObj, cmdObj->srcObj, _state.subject[0]);
 
 			if (cmdObj->dstObj > 0) {
 				// show the object
@@ -1182,7 +1182,7 @@
 	// l.69-103 select.c
 	uint16 i;
 	uint16 diff = objDesc->lastDescription - firstDesc;
-	debug(0, "Command::nextObjectDescription() - diff = %d, type = %d", diff, objDesc->type);
+	debug(6, "Command::nextObjectDescription() - diff = %d, type = %d", diff, objDesc->type);
 	switch (objDesc->type) {
 	case 0:
 		// random type, start with first description
@@ -1239,7 +1239,7 @@
 		desc = objData->description;
 	}
 
-	debug(0, "Command::lookAtSelectedObject() - desc = %X, _state.subject[0] = %X", desc, _state.subject[0]);
+	debug(6, "Command::lookAtSelectedObject() - desc = %X, _state.subject[0] = %X", desc, _state.subject[0]);
 
 	// check to see if the object/item has a series of description
 	ObjectDescription *objDesc = _vm->logic()->objectDescription(1);

Index: cutaway.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/cutaway.cpp,v
retrieving revision 1.92
retrieving revision 1.93
diff -u -d -r1.92 -r1.93
--- cutaway.cpp	20 Dec 2003 16:54:46 -0000	1.92
+++ cutaway.cpp	29 Dec 2003 21:05:33 -0000	1.93
@@ -72,7 +72,7 @@
 void Cutaway::load(const char *filename) {
 	byte *ptr;
 
-	debug(0, "----- Cutaway::load(\"%s\") -----", filename);
+	debug(6, "----- Cutaway::load(\"%s\") -----", filename);
 
 	ptr = _fileData = _vm->resource()->loadFile(filename, 20);
 	if (!_fileData) {
@@ -87,11 +87,11 @@
 
 	_comPanel = READ_BE_UINT16(ptr);
 	ptr += 2;
-	debug(0, "_comPanel = %i", _comPanel);
+	debug(6, "_comPanel = %i", _comPanel);
 
 	_cutawayObjectCount = (int16)READ_BE_UINT16(ptr);
 	ptr += 2;
-	debug(0, "_cutawayObjectCount = %i", _cutawayObjectCount);
+	debug(6, "_cutawayObjectCount = %i", _cutawayObjectCount);
 
 	if (_cutawayObjectCount < 0) {
 		_cutawayObjectCount = -_cutawayObjectCount;
@@ -102,7 +102,7 @@
 
 	int16 flags1 = (int16)READ_BE_UINT16(ptr);
 	ptr += 2;
-	debug(0, "flags1 = %i", flags1);
+	debug(6, "flags1 = %i", flags1);
 
 	if (flags1 < 0) {
 		_vm->logic()->entryObj(0);
@@ -113,8 +113,8 @@
 
 	_anotherCutaway = (flags1 == 1);
 
-	debug(0, "[Cutaway::load] _finalRoom      = %i", _finalRoom);
-	debug(0, "[Cutaway::load] _anotherCutaway = %i", _anotherCutaway);
+	debug(6, "[Cutaway::load] _finalRoom      = %i", _finalRoom);
+	debug(6, "[Cutaway::load] _anotherCutaway = %i", _anotherCutaway);
 
 	/*
 		 Pointers to other places in the cutaway data
@@ -128,20 +128,20 @@
 
 	byte *bankNamesPtr  = _fileData + READ_BE_UINT16(ptr);
 	ptr += 2;
-	//debug(0, "Bank name file offset = %08x", 20 + bankNamesPtr - _fileData);
+	//debug(6, "Bank name file offset = %08x", 20 + bankNamesPtr - _fileData);
 
 	_objectData = ptr;
 
 	loadStrings(bankNamesPtr);
 
 	if (_bankNames[0][0]) {
-		debug(0, "Loading bank '%s'", _bankNames[0]);
+		debug(6, "Loading bank '%s'", _bankNames[0]);
 		_vm->graphics()->bankLoad(_bankNames[0], CUTAWAY_BANK);
 	}
 
 	char entryString[MAX_STRING_SIZE];
 	_nextSentence = Talk::getString(_nextSentence, entryString, MAX_STRING_LENGTH);
-	debug(0, "Entry string = '%s'", entryString);
+	debug(6, "Entry string = '%s'", entryString);
 
 	_vm->logic()->joeCutFacing(_vm->logic()->joeFacing());
 	_vm->logic()->joeFace();
@@ -173,7 +173,7 @@
 	int bankNameCount = READ_BE_UINT16(ptr);
 	ptr += 2;
 
-	//debug(0, "Bank name count = %i", bankNameCount);
+	//debug(6, "Bank name count = %i", bankNameCount);
 
 	/*
 		 The _bankNames zero-based array is the one-based BANK_NAMEstr array in
@@ -184,18 +184,18 @@
 		ptr = Talk::getString(ptr, _bankNames[j], MAX_FILENAME_LENGTH);
 
 		if (_bankNames[j][0]) {
-			//debug(0, "Bank name %i = '%s'", j, _bankNames[j]);
+			//debug(6, "Bank name %i = '%s'", j, _bankNames[j]);
 			j++;
 		}
 	}
 
-	debug(0, "Getting talk file");
+	debug(6, "Getting talk file");
 	ptr = Talk::getString(ptr, _talkFile, MAX_FILENAME_LENGTH);
-	debug(0, "Talk file = '%s'", _talkFile);
+	debug(6, "Talk file = '%s'", _talkFile);
 
 	_talkTo = (int16)READ_BE_UINT16(ptr);
 	ptr += 2;
-	debug(0, "_talkTo = %i", _talkTo);
+	debug(6, "_talkTo = %i", _talkTo);
 }
 
 byte *Cutaway::getCutawayObject(byte *ptr, CutawayObject &object)
@@ -236,7 +236,7 @@
 
 void Cutaway::dumpCutawayObject(int index, CutawayObject &object)
 {
-	debug(0, "----- CutawayObject[%i] -----", index);
+	debug(6, "----- CutawayObject[%i] -----", index);
 
 	const char *objectNumberStr;
 
@@ -253,24 +253,24 @@
 		  break;
 	}
 
-	debug(0, "objectNumber = %i (%s)", object.objectNumber, objectNumberStr);
+	debug(6, "objectNumber = %i (%s)", object.objectNumber, objectNumberStr);
 
-	if (object.moveToX) debug(0, "moveToX = %i", object.moveToX);
-	if (object.moveToY) debug(0, "moveToY = %i", object.moveToY);
-	if (object.bank) debug(0, "bank = %i", object.bank);
-	if (object.animList) debug(0, "animList = %i", object.animList);
-	if (object.execute) debug(0, "execute = %i", object.execute);
-	if (object.limitBobX1) debug(0, "limitBobX1 = %i", object.limitBobX1);
-	if (object.limitBobY1) debug(0, "limitBobY1 = %i", object.limitBobY1);
-	if (object.limitBobX2) debug(0, "limitBobX2 = %i", object.limitBobX2);
-	if (object.limitBobY2) debug(0, "limitBobY2 = %i", object.limitBobY2);
-	if (object.specialMove) debug(0, "specialMove = %i", object.specialMove);
-	if (object.animType) debug(0, "animType = %i", object.animType);
-	if (object.fromObject) debug(0, "fromObject = %i", object.fromObject);
-	if (object.bobStartX) debug(0, "bobStartX = %i", object.bobStartX);
-	if (object.bobStartY) debug(0, "bobStartY = %i", object.bobStartY);
-	if (object.room) debug(0, "room = %i", object.room);
-	if (object.scale) debug(0, "scale = %i", object.scale);
+	if (object.moveToX) debug(6, "moveToX = %i", object.moveToX);
+	if (object.moveToY) debug(6, "moveToY = %i", object.moveToY);
+	if (object.bank) debug(6, "bank = %i", object.bank);
+	if (object.animList) debug(6, "animList = %i", object.animList);
+	if (object.execute) debug(6, "execute = %i", object.execute);
+	if (object.limitBobX1) debug(6, "limitBobX1 = %i", object.limitBobX1);
+	if (object.limitBobY1) debug(6, "limitBobY1 = %i", object.limitBobY1);
+	if (object.limitBobX2) debug(6, "limitBobX2 = %i", object.limitBobX2);
+	if (object.limitBobY2) debug(6, "limitBobY2 = %i", object.limitBobY2);
+	if (object.specialMove) debug(6, "specialMove = %i", object.specialMove);
+	if (object.animType) debug(6, "animType = %i", object.animType);
+	if (object.fromObject) debug(6, "fromObject = %i", object.fromObject);
+	if (object.bobStartX) debug(6, "bobStartX = %i", object.bobStartX);
+	if (object.bobStartY) debug(6, "bobStartY = %i", object.bobStartY);
+	if (object.room) debug(6, "room = %i", object.room);
+	if (object.scale) debug(6, "scale = %i", object.scale);
 
 }
 
@@ -286,7 +286,7 @@
 	for (int i = 0; i < object.personCount; i++) {
 		object.person[i] = (int16)READ_BE_UINT16(ptr);
 		ptr += 2;
-		//debug(0, "[%i] Turn on person %i", i, object.person[i]);
+		//debug(6, "[%i] Turn on person %i", i, object.person[i]);
 	}
 
 	return ptr;
@@ -327,7 +327,7 @@
 void Cutaway::changeRooms(CutawayObject &object) {
 	// Lines 1291-1385 in cutaway.c
 
-	debug(0, "Changing from room %i to room %i", 
+	debug(6, "Changing from room %i to room %i", 
 			_temporaryRoom, 
 			object.room);
 
@@ -358,7 +358,7 @@
 					}
 				}
 
-				/*debug(0, "Person '%s' (%i) is %s", 
+				/*debug(6, "Person '%s' (%i) is %s", 
 						_vm->logic()->objectName(objectData->name),
 						objectData->name,
 						on ? "on" : "off");*/
@@ -492,7 +492,7 @@
 byte *Cutaway::getCutawayAnim(byte *ptr, int header, CutawayAnim &anim) {
 	// lines 1531-1607 in cutaway.c
 
-	//debug(0, "[Cutaway::getCutawayAnim] header=%i", header);
+	//debug(6, "[Cutaway::getCutawayAnim] header=%i", header);
 
 	anim.currentFrame = 0;
 	anim.originalFrame = 0;
@@ -536,7 +536,7 @@
 	else {
 		if (anim.bank != 13) {
 			/* XXX if (OLDBANK != T) */ {
-				//debug(0, "Loading bank '%s'", _bankNames[anim.bank-1]);
+				//debug(6, "Loading bank '%s'", _bankNames[anim.bank-1]);
 				_vm->graphics()->bankLoad(_bankNames[anim.bank-1], CUTAWAY_BANK);
 				// XXX OLDBANK=T;
 			}
@@ -584,19 +584,19 @@
 }
 
 void Cutaway::dumpCutawayAnim(CutawayAnim &anim) {
-	debug(0, "----- CutawayAnim -----");
-	if (anim.object) debug(0, "object = %i", anim.object);
-	if (anim.unpackFrame) debug(0, "unpackFrame = %i", anim.unpackFrame);
-	if (anim.speed) debug(0, "speed = %i", anim.speed);
-	if (anim.bank) debug(0, "bank = %i", anim.bank);
-	if (anim.mx) debug(0, "mx = %i", anim.mx);
-	if (anim.my) debug(0, "my = %i", anim.my);
-	if (anim.cx) debug(0, "cx = %i", anim.cx);
-	if (anim.cy) debug(0, "cy = %i", anim.cy);
-	if (anim.scale) debug(0, "scale = %i", anim.scale);
-	if (anim.currentFrame) debug(0, "currentFrame = %i", anim.currentFrame);
-	if (anim.originalFrame) debug(0, "originalFrame = %i", anim.originalFrame);
-	if (anim.song) debug(0, "song = %i", anim.song);
+	debug(6, "----- CutawayAnim -----");
+	if (anim.object) debug(6, "object = %i", anim.object);
+	if (anim.unpackFrame) debug(6, "unpackFrame = %i", anim.unpackFrame);
+	if (anim.speed) debug(6, "speed = %i", anim.speed);
+	if (anim.bank) debug(6, "bank = %i", anim.bank);
+	if (anim.mx) debug(6, "mx = %i", anim.mx);
+	if (anim.my) debug(6, "my = %i", anim.my);
+	if (anim.cx) debug(6, "cx = %i", anim.cx);
+	if (anim.cy) debug(6, "cy = %i", anim.cy);
+	if (anim.scale) debug(6, "scale = %i", anim.scale);
+	if (anim.currentFrame) debug(6, "currentFrame = %i", anim.currentFrame);
+	if (anim.originalFrame) debug(6, "originalFrame = %i", anim.originalFrame);
+	if (anim.song) debug(6, "song = %i", anim.song);
 }
 
 byte *Cutaway::handleAnimation(byte *ptr, CutawayObject &object) {
@@ -616,7 +616,7 @@
 		if (-2 == header)
 			break;
 
-		//debug(0, "Animation frame %i, header = %i", frameCount, header);
+		//debug(6, "Animation frame %i, header = %i", frameCount, header);
 
 		if (header > 1000)
 			error("Header too large");
@@ -633,7 +633,7 @@
 	if (object.animType == 1) {
 		// lines 1615-1636 in cutaway.c
 		
-		debug(0, "----- Complex cutaway animation (animType = %i) -----", object.animType);
+		debug(6, "----- Complex cutaway animation (animType = %i) -----", object.animType);
 
 		if ((_vm->logic()->currentRoom() == 47 || _vm->logic()->currentRoom() == 63) &&
 			objAnim[0].object == 1) {
@@ -673,10 +673,10 @@
 	if (object.animType != 1) {
 		// lines 1657-1761 in cutaway.c
 
-		debug(0, "----- Normal cutaway animation (animType = %i) -----", object.animType);
+		debug(6, "----- Normal cutaway animation (animType = %i) -----", object.animType);
 		
 		for (i = 0; i < frameCount; i++) {
-			//debug(0, "===== Animating frame %i =====", i);
+			//debug(6, "===== Animating frame %i =====", i);
 			//dumpCutawayAnim(objAnim[i]);
 
 			BobSlot *bob = _vm->graphics()->bob(objAnim[i].object);
@@ -698,7 +698,7 @@
 					// Unpack animation, but do not unpack moving people
 
 					if (!((objAnim[i].mx > 0 || objAnim[i].my > 0) && InRange(objAnim[i].object, 1, 3))) {
-						/*debug(0, "Animation - bankUnpack(%i, %i, %i);",
+						/*debug(6, "Animation - bankUnpack(%i, %i, %i);",
 								objAnim[i].unpackFrame, 
 								objAnim[i].originalFrame,
 								objAnim[i].bank);*/
@@ -778,7 +778,7 @@
 	for (int i = strlen(basename); i < 5; i++)
 		result[i] = '_';
 	snprintf(result + 5, 3, "%02i", index);
-	//debug(0, "findCdCut(\"%s\", %i, \"%s\")", basename, index, result);
+	//debug(6, "findCdCut(\"%s\", %i, \"%s\")", basename, index, result);
 }
 
 void Cutaway::handlePersonRecord(
@@ -863,7 +863,7 @@
 	BobSlot *joeBob = _vm->graphics()->bob(0);
 	int initialJoeX = joeBob->x;
 	int initialJoeY = joeBob->y;
-	debug(0, "[Cutaway::run] Joe started at (%i, %i)", initialJoeX, initialJoeY);
+	debug(6, "[Cutaway::run] Joe started at (%i, %i)", initialJoeX, initialJoeY);
 
 	_vm->input()->cutawayRunning(true);
 
@@ -905,7 +905,7 @@
 
 		char sentence[MAX_STRING_SIZE];
 		_nextSentence = Talk::getString(_nextSentence, sentence, MAX_STRING_LENGTH);
-		//debug(0, "Sentence = '%s'", sentence);
+		//debug(6, "Sentence = '%s'", sentence);
 
 		if (OBJECT_ROOMFADE == object.objectNumber) {
 			_roomFade = true;
@@ -992,13 +992,13 @@
 
 			restorePersonData();
 
-			debug(0, "_vm->logic()->entryObj() = %i", _vm->logic()->entryObj());
+			debug(6, "_vm->logic()->entryObj() = %i", _vm->logic()->entryObj());
 			if (_vm->logic()->entryObj() > 0) {
 				_initialRoom = _vm->logic()->objectData(_vm->logic()->entryObj())->room;
 			}
 			else {
 				// We're not returning to new room, so return to old Joe X,Y coords
-				debug(0, "[Cutaway::run] Moving joe to (%i, %i)", initialJoeX, initialJoeY);
+				debug(6, "[Cutaway::run] Moving joe to (%i, %i)", initialJoeX, initialJoeY);
 				_vm->logic()->joeX(initialJoeX);
 				_vm->logic()->joeY(initialJoeY);
 			}
@@ -1074,14 +1074,14 @@
 	int16 joeX    = READ_BE_UINT16(ptr); ptr += 2;
 	int16 joeY    = READ_BE_UINT16(ptr); ptr += 2;
 	
-	debug(0, "[Cutaway::stop] Final position is room %i and coordinates (%i, %i)", 
+	debug(6, "[Cutaway::stop] Final position is room %i and coordinates (%i, %i)", 
 			joeRoom, joeX, joeY);
 
 	if ((!_vm->input()->cutawayQuit() || (!_anotherCutaway && joeRoom == _finalRoom)) &&
 			joeRoom != _temporaryRoom &&
 			joeRoom != 0) {
 		
-		debug(0, "[Cutaway::stop] Changing rooms and moving Joe");
+		debug(6, "[Cutaway::stop] Changing rooms and moving Joe");
 
 		_vm->logic()->joeX(joeX);
 		_vm->logic()->joeY(joeY);
@@ -1190,7 +1190,7 @@
 			(joeX || joeY)) {
 		BobSlot *joeBob = _vm->graphics()->bob(0);
 		
-		debug(0, "[Cutaway::stop] Moving Joe");
+		debug(6, "[Cutaway::stop] Moving Joe");
 
 		joeBob->x = joeX;
 		joeBob->y = joeY;
@@ -1296,7 +1296,7 @@
 	int bobNum = objAnim[0].object;
 
 	memset(frameIndex, 0, sizeof(frameIndex));
-	debug(0, "[Cutaway::makeComplexAnimation] currentImage = %i", currentImage);
+	debug(6, "[Cutaway::makeComplexAnimation] currentImage = %i", currentImage);
 
 	BobSlot *bob = _vm->graphics()->bob(bobNum);
 	bob->xflip = objAnim[0].flip;
@@ -1318,13 +1318,13 @@
 
 	for (i = 0; i < frameCount; i++) {
 		_cutAnim[bobNum][i].frame = currentImage + frameIndex[objAnim[i].unpackFrame];
-		//debug(0, "_cutAnim[%i][%i].frame = %i", bobNum, i, _cutAnim[bobNum][i].frame);
+		//debug(6, "_cutAnim[%i][%i].frame = %i", bobNum, i, _cutAnim[bobNum][i].frame);
 	}
 
 	for (i = 1; i < 256; i++) {
 		if (frameIndex[i]) {
 			currentImage++;
-			//debug(0, "bankUnpack(%i, %i, %i)", i, currentImage, objAnim[0].bank);
+			//debug(6, "bankUnpack(%i, %i, %i)", i, currentImage, objAnim[0].bank);
 			_vm->graphics()->bankUnpack(i, currentImage, objAnim[0].bank);
 		}
 	}
@@ -1341,7 +1341,7 @@
 		const char *sentence) {
 	// lines 1776-1863 in cutaway.c
 
-	//debug(0, "----- Write '%s' ----", sentence);
+	//debug(6, "----- Write '%s' ----", sentence);
 
 	int spaces = countSpaces(type, sentence);
 

Index: display.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/display.cpp,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -d -r1.39 -r1.40
--- display.cpp	29 Dec 2003 20:18:31 -0000	1.39
+++ display.cpp	29 Dec 2003 21:05:33 -0000	1.40
@@ -175,7 +175,7 @@
 
 	uint offset = (y / 4) * 160 + (x / 4);
 	if (offset >= sizeof(_dynalum.msk)) {
-		debug(0, "Graphics::dynalumUpdate(%d, %d) - invalid offset: %08x", x, y, offset);
+		debug(6, "Graphics::dynalumUpdate(%d, %d) - invalid offset: %08x", x, y, offset);
 		return;
 	}
 
@@ -621,7 +621,7 @@
 
 
 void Display::screenMode(int comPanel, bool inCutaway) {
-	debug(0, "Display::screenMode(%d, %d)", comPanel, inCutaway);
+	debug(6, "Display::screenMode(%d, %d)", comPanel, inCutaway);
 
 	// FIXME: this is temporary, just to see if my theory is right
 	if (comPanel == 2 && !inCutaway) {

Index: display.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/display.h,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -d -r1.29 -r1.30
--- display.h	26 Dec 2003 15:36:28 -0000	1.29
+++ display.h	29 Dec 2003 21:05:33 -0000	1.30
@@ -100,7 +100,7 @@
 	void horizontalScroll(int16 scroll);
 	int16 horizontalScroll() const { return _horizontalScroll; }
 
-	void fullscreen(bool fs) { debug(0, "Display::fullscreen(%d)", fs); _fullscreen = fs; }
+	void fullscreen(bool fs) { debug(6, "Display::fullscreen(%d)", fs); _fullscreen = fs; }
 	bool fullscreen() const { return _fullscreen; }
 
 	void handleTimer();

Index: input.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/input.cpp,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- input.cpp	26 Dec 2003 14:49:49 -0000	1.17
+++ input.cpp	29 Dec 2003 21:05:33 -0000	1.18
@@ -143,7 +143,7 @@
 int Input::checkKeys() {
 
 	if (_inKey)
-		debug(0, "[Input::checkKeys] _inKey = %i", _inKey);
+		debug(6, "[Input::checkKeys] _inKey = %i", _inKey);
 
 	switch (_inKey) {
 		case KEY_SPACE:
@@ -177,7 +177,7 @@
 		case KEY_ESCAPE:
 			if (_canQuit) {
 				if (_cutawayRunning) {
-					debug(0, "[Input::checkKeys] Setting _cutawayQuit to true!");
+					debug(6, "[Input::checkKeys] Setting _cutawayQuit to true!");
 					_cutawayQuit = true;
 				}
 

Index: logic.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/logic.cpp,v
retrieving revision 1.145
retrieving revision 1.146
diff -u -d -r1.145 -r1.146
--- logic.cpp	29 Dec 2003 20:51:28 -0000	1.145
+++ logic.cpp	29 Dec 2003 21:05:33 -0000	1.146
@@ -550,7 +550,7 @@
 
 void Logic::gameState(int index, int16 newValue) {
 	if (index >= 0 && index < GAME_STATE_COUNT) {
-//		debug(0, "Logic::gameState() - GAMESTATE[%d] = %d", index, newValue);
+//		debug(6, "Logic::gameState() - GAMESTATE[%d] = %d", index, newValue);
 		_gameState[index] = newValue;
 	}
 	else
@@ -894,7 +894,7 @@
 	for (i = firstRoomObj; i <= lastRoomObj; ++i) {
 		ObjectData *pod = &_objectData[i];
 		if (pod->image == -3 || pod->image == -4) {
-			debug(0, "Logic::roomSetupObjects() - Setting up person %X, name=%X", i, pod->name);
+			debug(6, "Logic::roomSetupObjects() - Setting up person %X, name=%X", i, pod->name);
 			uint16 noun = i - _roomData[_currentRoom];
 			if (pod->name > 0) {
 				curImage = personSetup(noun, curImage);
@@ -936,11 +936,11 @@
 		return curImage;
 	}
 
-	debug(0, "Logic::roomRefreshObject(%X, %s)", obj, _objName[ABS(pod->name)]);
+	debug(6, "Logic::roomRefreshObject(%X, %s)", obj, _objName[ABS(pod->name)]);
 
 	// check the object is in the current room
 	if (pod->room != _currentRoom) {
-		debug(0, "Refreshing an object (%i=%s) not in current room (object room=%i, current room=%i)", obj, _objName[ABS(pod->name)], pod->room, _currentRoom);
+		debug(6, "Refreshing an object (%i=%s) not in current room (object room=%i, current room=%i)", obj, _objName[ABS(pod->name)], pod->room, _currentRoom);
 		return curImage;
 	}
 
@@ -1054,7 +1054,7 @@
 
 void Logic::roomDisplay(uint16 room, RoomDisplayMode mode, uint16 scale, int comPanel, bool inCutaway) {
 
-	debug(0, "Logic::roomDisplay(%d, %d, %d, %d, %d)", room, mode, scale, comPanel, inCutaway);
+	debug(6, "Logic::roomDisplay(%d, %d, %d, %d, %d)", room, mode, scale, comPanel, inCutaway);
 
 	roomErase();
 
@@ -1135,7 +1135,7 @@
 			pp->anim = NULL;
 		}
 
-		debug(0, "Logic::personSetData() - name=%s n=%d", pp->name, actor);
+		debug(6, "Logic::personSetData() - name=%s n=%d", pp->name, actor);
 
 		if (loadBank) {
 			const char *actorFile = _aFile[pp->actor->actorFile];
@@ -1182,7 +1182,7 @@
 	pbs->frameNum = p.bobFrame;
 	pbs->xflip = xflip;
 
-	debug(0, "Logic::personSetup(%d, %d) - bob = %d name = %s", noun, curImage, pad->bobNum, p.name);
+	debug(6, "Logic::personSetup(%d, %d) - bob = %d name = %s", noun, curImage, pad->bobNum, p.name);
 
 	if (p.anim != NULL) {
 		_personFrames[pad->bobNum] = curImage + 1;
@@ -1423,7 +1423,7 @@
 
 ObjectData *Logic::joeSetupInRoom(bool autoPosition, uint16 scale) {
 
-	debug(0, "Logic::joeSetupInRoom(%d, %d) joe.x=%d joe.y=%d", autoPosition, scale, _joe.x, _joe.y);
+	debug(6, "Logic::joeSetupInRoom(%d, %d) joe.x=%d joe.y=%d", autoPosition, scale, _joe.x, _joe.y);
 
 	uint16 oldx;
 	uint16 oldy;
@@ -1450,7 +1450,7 @@
 		}
 	}
 
-	debug(0, "Logic::joeSetupInRoom() - oldx=%d, oldy=%d scale=%d", oldx, oldy, scale);
+	debug(6, "Logic::joeSetupInRoom() - oldx=%d, oldy=%d scale=%d", oldx, oldy, scale);
 
 	if (scale > 0 && scale < 100) {
 		joeScale(scale);
@@ -2368,7 +2368,7 @@
 }
 
 void Logic::sceneStart() {
-	debug(0, "[Logic::sceneStart] _scene = %i", _scene);
+	debug(6, "[Logic::sceneStart] _scene = %i", _scene);
 	_scene++;
 
 	_vm->display()->showMouseCursor(false);
@@ -2381,7 +2381,7 @@
 }
 
 void Logic::sceneStop() {
-	debug(0, "[Logic::sceneStop] _scene = %i", _scene);
+	debug(6, "[Logic::sceneStop] _scene = %i", _scene);
 	_scene--;
 
 	if (_scene > 0)
@@ -2636,9 +2636,10 @@
 
 void Logic::executeSpecialMove(uint16 sm) {
 	
-	debug(0, "Special move: %d", sm);
-	if (!(this->*_executeASM)(sm))
-		warning("unhandled / invalid special move : %d", sm);
+	debug(6, "Special move: %d", sm);
+	if (sm)
+		if (!(this->*_executeASM)(sm))
+			warning("unhandled / invalid special move : %d", sm);
 }
 
 

Index: talk.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/queen/talk.cpp,v
retrieving revision 1.63
retrieving revision 1.64
diff -u -d -r1.63 -r1.64
--- talk.cpp	29 Dec 2003 16:33:03 -0000	1.63
+++ talk.cpp	29 Dec 2003 21:05:33 -0000	1.64
@@ -81,7 +81,7 @@
 	_oldSelectedSentenceIndex = 0;
 	_oldSelectedSentenceValue = 0;
 
-	debug(0, "----- talk(\"%s\") -----", filename);
+	debug(6, "----- talk(\"%s\") -----", filename);
 
 	cutawayFilename[0] = '\0';
 
@@ -143,7 +143,7 @@
 
 	// TODO: split this loop in several functions
 	while(retval != -1) {
-		// debug(0, "retval = %i", retval);
+		// debug(6, "retval = %i", retval);
 		
 		char otherVoiceFilePrefix    [MAX_STRING_SIZE];
 
@@ -191,7 +191,7 @@
 			}
 		}
 
-		debug(0, "choicesLeft = %i", choicesLeft);
+		debug(6, "choicesLeft = %i", choicesLeft);
 
 		if (1 == choicesLeft) {
 			// Automatically run the final dialogue option
@@ -369,7 +369,7 @@
 		int16 currentId = (int16)READ_BE_UINT16(ptr); ptr += 2;
 		if (id == currentId) {
 			ptr = getString(ptr, str, MAX_STRING_LENGTH, 4);
-			//debug(0, "Found string with ID %i: '%s'", id, str);
+			//debug(6, "Found string with ID %i: '%s'", id, str);
 			break;
 		}
 		else
@@ -395,7 +395,7 @@
 			File fdog;
 			fdog.open(filename, _vm->getGameDataPath());
 			if (fdog.isOpen()) {
-				debug(0, "Loading dog file '%s' from game data path", filename);
+				debug(6, "Loading dog file '%s' from game data path", filename);
 				uint32 size = fdog.size() - DOG_HEADER_SIZE;
 				byte *buf = new byte[size];
 				fdog.seek(DOG_HEADER_SIZE);
@@ -423,7 +423,7 @@
 
 	_levelMax = (int16)READ_BE_UINT16(ptr); ptr += 2;
 
-	//debug(0, "levelMax = %i", _levelMax);
+	//debug(6, "levelMax = %i", _levelMax);
 
 	if (_levelMax < 0) {
 		_levelMax = -_levelMax;
@@ -443,8 +443,8 @@
 		_itemNumber[i] = (int16)READ_BE_UINT16(ptr); ptr += 2;
 	}
 
-	//debug(0, "uniqueKey = %i", _uniqueKey);
-	//debug(0, "talkKey   = %i", _talkKey);
+	//debug(6, "uniqueKey = %i", _uniqueKey);
+	//debug(6, "talkKey   = %i", _talkKey);
 
 	_person1Ptr = _fileData + READ_BE_UINT16(ptr); ptr += 2;
 	_cutawayPtr = _fileData + READ_BE_UINT16(ptr); ptr += 2;
@@ -485,18 +485,18 @@
 	char joeString[MAX_STRING_SIZE];
 	if (!hasNotString) {
 		ptr = getString(ptr, joeString, MAX_STRING_LENGTH);
-		//debug(0, "joeString = '%s'", joeString);
+		//debug(6, "joeString = '%s'", joeString);
 	}
 	else
 		joeString[0] = '\0';
 
 	ptr = _person2Ptr;
 	ptr = getString(ptr, _person2String, MAX_STRING_LENGTH);
-	//debug(0, "person2String = '%s'", _person2String);
+	//debug(6, "person2String = '%s'", _person2String);
 
 	char joe2String[MAX_STRING_SIZE];
 	ptr = getString(ptr, joe2String, MAX_STRING_LENGTH);
-	//debug(0, "joe2String = '%s'", joe2String);
+	//debug(6, "joe2String = '%s'", joe2String);
 
 	if (!hasTalkedTo()) {
 		
@@ -581,7 +581,7 @@
 				commandCode = atoi(sentence + index + 2);
 				int x = atoi(sentence + index + 5);
 				int y = atoi(sentence + index + 9);
-				debug(0, "Calling MOVE_SPEAK(person, %i, %i)",x, y);
+				debug(6, "Calling MOVE_SPEAK(person, %i, %i)",x, y);
 				// XXX MOVE_SPEAK(person, x, y)
 				index += 11;
 				/// XXX personWalking = true;
@@ -632,7 +632,7 @@
 		person = &joe_person;
 	}
 	
-	//debug(0, "Sentence '%s' is said by person '%s' and voice files with prefix '%s' played",
+	//debug(6, "Sentence '%s' is said by person '%s' and voice files with prefix '%s' played",
 	//		sentence, person->name, voiceFilePrefix);
 
 	if (sentence[0] == '\0') {
@@ -760,7 +760,7 @@
 		return;
 	}
 	else if (!isdigit(parameters->animation[0])) {
-		debug(0, "Error in speak string animation: '%s'", parameters->animation);
+		debug(6, "Error in speak string animation: '%s'", parameters->animation);
 		return;
 	}
 	else
@@ -807,7 +807,7 @@
 	// lines 1730-1823 in talk.c
 
 #if 0
-	debug(0, "Talk::defaultAnimation(\"%s\", %s, {\"%s\", %i, ...}, %i, %i)",
+	debug(6, "Talk::defaultAnimation(\"%s\", %s, {\"%s\", %i, ...}, %i, %i)",
 			segment, 
 			isJoe ? "true" : "false",
 			parameters->name,
@@ -868,7 +868,7 @@
 					}
 				}
 				else {
-					debug(0, "[Talk::defaultAnimation] Body action!");
+					debug(6, "[Talk::defaultAnimation] Body action!");
 					// Just do a body action
 					_vm->graphics()->bankOverpack(parameters->body, startFrame, bankNum);
 				}
@@ -928,7 +928,7 @@
 	char voiceFileName[MAX_STRING_SIZE];
 	snprintf(voiceFileName, sizeof(voiceFileName), "%s%1x", voiceFilePrefix, index + 1);
 
-	// debug(0, "Sentence segment '%*s' is said by person '%s' and voice file '%s' is played",
+	// debug(6, "Sentence segment '%*s' is said by person '%s' and voice file '%s' is played",
 	//		length, segment, person->name, voiceFileName);
 
 	// FIXME - it seems the french talkie version has a useless voice file ; 
@@ -1192,7 +1192,7 @@
 
 int Talk::splitOption(const char *str, char optionText[5][MAX_STRING_SIZE]) {
 
-	//debug(0, "splitOption(\"%s\")", str);
+	//debug(6, "splitOption(\"%s\")", str);
 
 	// Check to see if option fits on one line, and exit early
 
@@ -1294,7 +1294,7 @@
 				int j;
 				for (j = 0; j < optionLines; j++) {
 					if (yOffset < 5) {
-						//debug(0, "Draw text '%s'", optionText[j]);
+						//debug(6, "Draw text '%s'", optionText[j]);
 						_vm->graphics()->textSet(
 								(j == 0) ? 0 : 24, 
 								150 - PUSHUP + yOffset * LINE_HEIGHT, 
@@ -1333,14 +1333,14 @@
 
 				if (5 == zone || 6 == zone) {
 					// XXX Arrow zones
-					debug(0, "Arrow zones");
+					debug(6, "Arrow zones");
 				}
 				else {
 					if (oldZone != zone) {
 						// Changed zone, change text colors
 						int y;
 
-						/*debug(0, "Changed zone. oldZone = %i, zone = %i",
+						/*debug(6, "Changed zone. oldZone = %i, zone = %i",
 								oldZone, zone);*/
 
 						if (zone > 0) {
@@ -1384,10 +1384,10 @@
 
 
 	// XXX Begin debug stuff
-	// debug(0, "----- Select a sentence of these -----");
+	// debug(6, "----- Select a sentence of these -----");
 	for (i = 1; i <= 4; i++) {
 		if (_talkString[i][0] != '\0') {
-			// XXX debug(0, "%i: %s", i, _talkString[i]);
+			// XXX debug(6, "%i: %s", i, _talkString[i]);
 			if (!selectedSentence)
 				selectedSentence = i;
 		}
@@ -1395,7 +1395,7 @@
 	// XXX End debug stuff
 
 
-	debug(0, "Selected sentence %i", selectedSentence);
+	debug(6, "Selected sentence %i", selectedSentence);
 
 	arrowBobUp->active    = false;
 	arrowBobDown->active  = false;





More information about the Scummvm-git-logs mailing list