[Scummvm-cvs-logs] CVS: scummvm/scumm actor.cpp,1.374,1.375 actor.h,1.81,1.82 akos.cpp,1.230,1.231 akos.h,1.41,1.42 base-costume.cpp,2.30,2.31 base-costume.h,1.39,1.40 bomp.cpp,2.33,2.34 boxes.cpp,1.90,1.91 boxes.h,1.11,1.12 charset.cpp,2.150,2.151 charset.h,2.46,2.47 costume.cpp,1.187,1.188 costume.h,1.37,1.38 cursor.cpp,2.46,2.47 debugger.cpp,1.152,1.153 debugger.h,1.37,1.38 dialogs.cpp,1.148,1.149 dialogs.h,1.56,1.57 gfx.cpp,2.463,2.464 gfx.h,1.120,1.121 help.cpp,1.22,1.23 imuse.cpp,2.145,2.146 imuse_internal.h,2.42,2.43 input.cpp,2.32,2.33 instrument.cpp,2.35,2.36 intern.h,2.513,2.514 logic_he.cpp,2.23,2.24 nut_renderer.cpp,1.62,1.63 object.cpp,1.246,1.247 palette.cpp,2.52,2.53 palette_he.cpp,1.23,1.24 player_mod.h,2.20,2.21 player_nes.cpp,2.4,2.5 player_v1.cpp,1.26,1.27 player_v2.cpp,2.60,2.61 player_v2.h,2.35,2.36 player_v2a.cpp,2.31,2.32 player_v3a.cpp,1.24,1.25 resource.cpp,1.330,1.331 resource.h,1.16,1.17 resource_v2.cpp,1.57,1.58 resource_v7he.cpp,1.44,1.45 resource_v7he.h,1.15,1.16 room.cpp,1.19,1.20 saveload.cpp,1.231,1.232 saveload.h,1.62,1.63 script.cpp,1.226,1.227 script_c64.cpp,2.10,2.11 script_v100he.cpp,2.169,2.170 script_v2.cpp,2.279,2.280 script_v5.cpp,1.290,1.291 script_v6.cpp,1.446,1.447 script_v6he.cpp,2.163,2.164 script_v72he.cpp,2.301,2.302 script_v7he.cpp,2.164,2.165 script_v8.cpp,2.297,2.298 script_v80he.cpp,2.123,2.124 script_v90he.cpp,2.277,2.278 scumm.cpp,1.555,1.556 scumm.h,1.638,1.639 sound.cpp,1.469,1.470 sound.h,1.90,1.91 sprite_he.cpp,1.151,1.152 sprite_he.h,1.42,1.43 string.cpp,1.298,1.299 thumbnail.cpp,1.6,1.7 usage_bits.cpp,1.15,1.16 util.cpp,2.12,2.13 util.h,2.13,2.14 vars.cpp,1.141,1.142 verbs.cpp,1.139,1.140 wiz_he.cpp,2.91,2.92 wiz_he.h,2.27,2.28

Eugene Sandulenko sev at users.sourceforge.net
Sat Jul 30 14:15:13 CEST 2005


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv9428/scumm

Modified Files:
	actor.cpp actor.h akos.cpp akos.h base-costume.cpp 
	base-costume.h bomp.cpp boxes.cpp boxes.h charset.cpp 
	charset.h costume.cpp costume.h cursor.cpp debugger.cpp 
	debugger.h dialogs.cpp dialogs.h gfx.cpp gfx.h help.cpp 
	imuse.cpp imuse_internal.h input.cpp instrument.cpp intern.h 
	logic_he.cpp nut_renderer.cpp object.cpp palette.cpp 
	palette_he.cpp player_mod.h player_nes.cpp player_v1.cpp 
	player_v2.cpp player_v2.h player_v2a.cpp player_v3a.cpp 
	resource.cpp resource.h resource_v2.cpp resource_v7he.cpp 
	resource_v7he.h room.cpp saveload.cpp saveload.h script.cpp 
	script_c64.cpp script_v100he.cpp script_v2.cpp script_v5.cpp 
	script_v6.cpp script_v6he.cpp script_v72he.cpp script_v7he.cpp 
	script_v8.cpp script_v80he.cpp script_v90he.cpp scumm.cpp 
	scumm.h sound.cpp sound.h sprite_he.cpp sprite_he.h string.cpp 
	thumbnail.cpp usage_bits.cpp util.cpp util.h vars.cpp 
	verbs.cpp wiz_he.cpp wiz_he.h 
Log Message:
Remove trailing whitespaces.


Index: actor.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/actor.cpp,v
retrieving revision 1.374
retrieving revision 1.375
diff -u -d -r1.374 -r1.375
--- actor.cpp	30 Jul 2005 05:58:48 -0000	1.374
+++ actor.cpp	30 Jul 2005 21:11:22 -0000	1.375
@@ -75,7 +75,7 @@
 		_walkdata.point3.x = 32000;
 		_walkScript = 0;
 		memset(_heTalkQueue, 0, sizeof(_heTalkQueue));
-		
+
 		mode = 1;
 	}
 
@@ -250,7 +250,7 @@
 	// The Dig also checks if the actor is in the current room, but that's
 	// not necessary here because we never call the function unless the
 	// actor is in the current room anyway.
-	
+
 	if (!_ignoreBoxes || (_vm->_gameId == GID_LOOM || _vm->_gameId == GID_LOOM256)) {
 		specdir = _vm->_extraBoxFlags[_walkbox];
 		if (specdir) {
@@ -337,7 +337,7 @@
 	if (_vm->_version >= 7)
 		// Direction interpolation interfers with walk scripts in Dig; they perform
 		// (much better) interpolation themselves.
-		shouldInterpolate = false;	
+		shouldInterpolate = false;
 	else
 		shouldInterpolate = (dir & 1024) ? true : false;
 	dir &= 1023;
@@ -686,7 +686,7 @@
 			// Skip over invisible boxes
 			if (flags & kBoxInvisible && !(flags & kBoxPlayerOnly && !isPlayer()))
 				continue;
-			
+
 			// For increased performance, we perform a quick test if
 			// the coordinates can even be within a distance of 'threshold'
 			// pixels of the box.
@@ -709,7 +709,7 @@
 			if (tmpDist < bestDist) {
 				abr.x = tmpX;
 				abr.y = tmpY;
-	
+
 				if (tmpDist == 0) {
 					abr.box = box;
 					return abr;
@@ -756,7 +756,7 @@
 
 void Actor::faceToObject(int obj) {
 	int x2, y2, dir;
-	
+
 	if (!isInCurrentRoom())
 		return;
 
@@ -909,7 +909,7 @@
 
 Actor *ScummEngine::derefActor(int id, const char *errmsg) const {
 	if (id == 0)
-		debugC(DEBUG_ACTORS, "derefActor(0, \"%s\") in script %d, opcode 0x%x", 
+		debugC(DEBUG_ACTORS, "derefActor(0, \"%s\") in script %d, opcode 0x%x",
 			errmsg, vm.slot[_curExecScript].number, _opcode);
 
 	if (id < 0 || id >= _numActors || _actors[id]._number != id) {
@@ -923,7 +923,7 @@
 
 Actor *ScummEngine::derefActorSafe(int id, const char *errmsg) const {
 	if (id == 0)
-		debugC(DEBUG_ACTORS, "derefActorSafe(0, \"%s\") in script %d, opcode 0x%x", 
+		debugC(DEBUG_ACTORS, "derefActorSafe(0, \"%s\") in script %d, opcode 0x%x",
 			errmsg, vm.slot[_curExecScript].number, _opcode);
 
 	if (id < 0 || id >= _numActors || _actors[id]._number != id) {
@@ -1006,7 +1006,7 @@
 			a->animateCostume();
 		}
 	}
-	
+
 	if (_features & GF_NEW_COSTUMES)
 		akos_processQueue();
 }
@@ -1063,7 +1063,7 @@
 	if (!hitTestMode) {
 		if (!_needRedraw)
 			return;
-	
+
 		_needRedraw = false;
 	}
 
@@ -1142,7 +1142,7 @@
 
 	bcr->_skipLimbs = (_heSkipLimbs != 0);
 	bcr->_paletteNum = _hePaletteNum;
-	
+
 	if (_vm->_heversion >= 80 && _heNoTalkAnimation == 0) {
 		_heCondMask &= 0xFFFFFC00;
 		_heCondMask |= 1;
@@ -1151,7 +1151,7 @@
 			// Otherwise just do rand animation
 			int rnd = _vm->_rnd.getRandomNumberRng(1, 10);
 			setTalkCondition(rnd);
-		} 
+		}
 	}
 	_heNoTalkAnimation = 0;
 
@@ -1180,7 +1180,7 @@
 	drawActorCostume(true);
 
 	ar->_actorHitMode = false;
-	
+
 	return ar->_actorHitResult;
 }
 #endif
@@ -1192,7 +1192,7 @@
 	_animProgress++;
 	if (_animProgress >= _animSpeed) {
 		_animProgress = 0;
-		
+
 		_vm->_costumeLoader->loadCostume(_costume);
 		if (_vm->_costumeLoader->increaseAnims(this)) {
 			_needRedraw = true;
@@ -1202,9 +1202,9 @@
 
 #ifndef DISABLE_SCUMM_7_8
 void Actor::animateLimb(int limb, int f) {
-	// This methods is very similiar to animateCostume(). 
+	// This methods is very similiar to animateCostume().
 	// However, instead of animating *all* the limbs, it only animates
-	// the specified limb to be at the frame specified by "f". 
+	// the specified limb to be at the frame specified by "f".
 
 	if (!f)
 		return;
@@ -1223,9 +1223,9 @@
 
 		aksq = _vm->findResourceData(MKID('AKSQ'), akos);
 		akfo = _vm->findResourceData(MKID('AKFO'), akos);
-	
+
 		size = _vm->getResourceDataSize(akfo) / 2;
-	
+
 		while (f--) {
 			if (_cost.active[limb] != 0)
 				_vm->akos_increaseAnim(this, limb, aksq, (const uint16 *)akfo, size);
@@ -1334,7 +1334,7 @@
 	Actor *a;
 
 	convertMessageToString(msg, _charsetBuffer, sizeof(_charsetBuffer));
-	
+
 	// Play associated speech, if any
 	playSpeech((byte *)_lastStringTag);
 
@@ -1375,8 +1375,8 @@
 	Actor *a;
 
 	convertMessageToString(msg, _charsetBuffer, sizeof(_charsetBuffer));
-	
-	// FIXME: Workaround for bugs #770039 and #770049 
+
+	// FIXME: Workaround for bugs #770039 and #770049
 	if (_gameId == GID_LOOM || _gameId == GID_LOOM256) {
 		if (!*_charsetBuffer)
 			return;
@@ -1389,13 +1389,13 @@
 		setTalkingActor(0xFF);
 	} else {
 		int oldact;
-		
+
 		// FIXME: Workaround for bug #770724
 		if (_gameId == GID_LOOM && _roomResource == 23 &&
 			vm.slot[_currentScript].number == 232 && _actorToPrintStrFor == 0) {
 			_actorToPrintStrFor = 2;	// Could be anything from 2 to 5. Maybe compare to original?
 		}
-		
+
 		a = derefActor(_actorToPrintStrFor, "actorTalk");
 		if (!a->isInCurrentRoom() && (_version <= 6)) {
 			oldact = 0xFF;
@@ -1436,7 +1436,7 @@
 }
 
 void Actor::runActorTalkScript(int f) {
-	if (_vm->_version == 8 && _vm->VAR(_vm->VAR_HAVE_MSG) == 2) 
+	if (_vm->_version == 8 && _vm->VAR(_vm->VAR_HAVE_MSG) == 2)
 		return;
 
 	if (_talkScript) {
@@ -1496,15 +1496,15 @@
 		c &= 0xff;
 
 	_costumeNeedsInit = true;
-	
+
 	if (_vm->_features & GF_NEW_COSTUMES) {
 		memset(_animVariable, 0, sizeof(_animVariable));
-		
+
 #ifndef DISABLE_HE
 		if (_vm->_heversion >= 71)
 			((ScummEngine_v71he *)_vm)->queueAuxBlock(this);
 #endif
-		
+
 		_costume = c;
 		_cost.reset();
 		_auxBlock.reset();
@@ -1698,7 +1698,7 @@
 		}
 
 		_walkdata.curbox = next_box;
-		
+
 		if (findPathTowards(_walkbox, next_box, _walkdata.destbox, foundPath))
 			break;
 
@@ -1725,10 +1725,10 @@
 			_moving = 0;
 		return;
 	}
-	
+
 	if (!_moving)
 		return;
-	
+
 	if (_moving & MF_IN_LEG) {
 		actorWalkStep();
 	} else {
@@ -1746,7 +1746,7 @@
 					_moving |= MF_LAST_LEG;
 					return;
 				}
-		
+
 				// Can't walk through locked boxes
 				int flags = _vm->getBoxFlags(next_box);
 				if (flags & kBoxLocked && !(flags & kBoxPlayerOnly && !isPlayer())) {
@@ -1770,7 +1770,7 @@
 
 	if (!_moving)
 		return;
-	
+
 	if (!(_moving & MF_NEW_LEG)) {
 		if (_moving & MF_IN_LEG && actorWalkStep())
 			return;
@@ -1815,7 +1815,7 @@
 
 		next_box = _vm->getPathToDestBox(_walkbox, _walkdata.destbox);
 
-		// WORKAROUND: To fully fix bug #774783, we add a special case 
+		// WORKAROUND: To fully fix bug #774783, we add a special case
 		// here, resulting in a different next_box value for Hitler.
 		if ((_vm->_gameId == GID_INDY3) && _vm->_roomResource == 46 && _walkbox == 1 && _walkdata.destbox == 0 && _number == 9)
 			next_box = 1;
@@ -1824,7 +1824,7 @@
 			_moving |= MF_LAST_LEG;
 			return;
 		}
-		
+
 		// Can't walk through locked boxes
 		int flags = _vm->getBoxFlags(next_box);
 		if (flags & kBoxLocked && !(flags & kBoxPlayerOnly && !isPlayer())) {
@@ -1847,7 +1847,7 @@
 			if (p2.x == 32000 && p3.x == 32000) {
 				break;
 			}
-	
+
 			if (p2.x != 32000) {
 				if (calcMovementFactor(p2)) {
 					_walkdata.point3 = p3;
@@ -2014,10 +2014,10 @@
 		} else {
 			_heCondMask |= 1;
 		}
-	}	
+	}
 }
 
-bool Actor::isTalkConditionSet(int slot) const {	
+bool Actor::isTalkConditionSet(int slot) const {
 	assert(slot >= 1 && slot <= 0x10);
 	return (_heCondMask & (1 << (slot - 1))) != 0;
 }
@@ -2085,7 +2085,7 @@
 						int x1 = (int16)READ_LE_UINT16(axur + 0) + dx;
 						int y1 = (int16)READ_LE_UINT16(axur + 2) + dy;
 						int x2 = (int16)READ_LE_UINT16(axur + 4) + dx;
-						int y2 = (int16)READ_LE_UINT16(axur + 6) + dy;					
+						int y2 = (int16)READ_LE_UINT16(axur + 6) + dy;
 						markRectAsDirty(kMainVirtScreen, x1, x2, y1, y2 + 1);
 						axur += 8;
 					}
@@ -2173,7 +2173,7 @@
 		// Actor palette grew from 64 to 256 bytes
 		MKARRAY_OLD(Actor, _palette[0], sleByte, 64, VER(8), VER(9)),
 		MKARRAY(Actor, _palette[0], sleByte, 256, VER(10)),
-	
+
 		MK_OBSOLETE(Actor, _mask, sleByte, VER(8), VER(9)),
 		MKLINE(Actor, _shadowMode, sleByte, VER(8)),
 		MKLINE(Actor, _visible, sleByte, VER(8)),
@@ -2189,9 +2189,9 @@
 		MKLINE(Actor, _talkPosY, sleInt16, VER(8)),
 		MKLINE(Actor, _talkPosX, sleInt16, VER(8)),
 		MKLINE(Actor, _ignoreTurns, sleByte, VER(8)),
-	
+
 		MKLINE(Actor, _layer, sleByte, VER(8)),
-	
+
 		MKLINE(Actor, _talkScript, sleUint16, VER(8)),
 		MKLINE(Actor, _walkScript, sleUint16, VER(8)),
 
@@ -2211,7 +2211,7 @@
 
 		MKLINE(Actor, _walkdata.point3.x, sleUint16, VER(42)),
 		MKLINE(Actor, _walkdata.point3.y, sleUint16, VER(42)),
-	
+
 		MKARRAY(Actor, _cost.active[0], sleByte, 16, VER(8)),
 		MKLINE(Actor, _cost.stopped, sleUint16, VER(8)),
 		MKARRAY(Actor, _cost.curpos[0], sleUint16, 16, VER(8)),
@@ -2220,7 +2220,7 @@
 		MKARRAY(Actor, _cost.frame[0], sleUint16, 16, VER(8)),
 		MKEND()
 	};
-	
+
 	return actorEntries;
 }
 

Index: actor.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/actor.h,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -d -r1.81 -r1.82
--- actor.h	12 Apr 2005 02:29:49 -0000	1.81
+++ actor.h	30 Jul 2005 21:11:22 -0000	1.82
@@ -87,13 +87,13 @@
 
 public:
 	static byte kInvalidBox;
-	
+
 	static void initActorClass(ScummEngine *scumm);
 
 public:
 	/** The position of the actor inside the virtual screen. */
 	Common::Point _pos;
-	
+
 	/** HE specific: This rect is used to clip actor drawing. */
 	Common::Rect _clipOverride;
 
@@ -165,7 +165,7 @@
 public:
 
 	Actor();
-	
+
 //protected:
 	void hideActor();
 	void showActor();
@@ -195,11 +195,11 @@
 	void drawActorCostume(bool hitTestMode = false);
 	void animateCostume();
 	void setActorCostume(int c);
-	
+
 	void animateLimb(int limb, int f);
-	
+
 	bool actorHitTest(int x, int y);
-	
+
 	byte *getActorName();
 	void startWalkActor(int x, int y, int dir);
 	void stopActorMoving();
@@ -217,20 +217,20 @@
 	bool isInCurrentRoom() const {
 		return _room == _vm->_currentRoom;
 	}
-	
+
 	int getActorXYPos(int &x, int &y) const;
 
 	int getRoom() const {
 		return _room;
 	}
-	
+
 	int getFacing() const {
 		return _facing;
 	}
 
 	int getAnimVar(byte var) const;
 	void setAnimVar(byte var, int value);
-	
+
 	void setAnimSpeed(byte newAnimSpeed) {
 		_animSpeed = newAnimSpeed;
 		_animProgress = 0;
@@ -247,19 +247,19 @@
 	int getElevation() const {
 		return _elevation;
 	}
-	
+
 	void setElevation(int newElevation) {
 		if (_elevation != newElevation) {
 			_elevation = newElevation;
 			_needRedraw = true;
 		}
 	}
-	
+
 	void setPalette(int idx, int val) {
 		_palette[idx] = val;
 		_needRedraw = true;
 	}
-	
+
 	void setScale(int sx, int sy) {
 		if (sx != -1)
 			_scalex = sx;
@@ -269,19 +269,19 @@
 	}
 
 	void classChanged(int cls, bool value);
-	
+
 	void setUserCondition(int slot, int set);
 	bool isUserConditionSet(int slot) const;
 
 	void setTalkCondition(int slot);
 	bool isTalkConditionSet(int slot) const;
-	
+
 	// Used by the save/load syste:
 	static const SaveLoadEntry *getSaveLoadEntries();
-	
+
 protected:
 	bool isInClass(int cls);
-	
+
 	bool isPlayer();
 
 	bool findPathTowards(byte box, byte box2, byte box3, Common::Point &foundPath);

Index: akos.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/akos.cpp,v
retrieving revision 1.230
retrieving revision 1.231
diff -u -d -r1.230 -r1.231
--- akos.cpp	24 Jun 2005 15:23:07 -0000	1.230
+++ akos.cpp	30 Jul 2005 21:11:23 -0000	1.231
@@ -250,7 +250,7 @@
 							}
 							if (!found) {
 								error("Sequence not found in actor 0x%X costume %d", a, a->_costume);
-							}							
+							}
 						}
 					}
 
@@ -276,7 +276,7 @@
 								error("Sequence not found in actor 0x%X costume %d", a, a->_costume);
 							}
 						}
-					}					
+					}
 					break;
 				}
 			} else {
@@ -312,7 +312,7 @@
 	if (_vm->_heversion == 70) {
 		for (i = 0; i < size; i++)
 			palette[i] = _vm->_HEV7ActorPalette[palette[i]];
-	} 
+	}
 
 	if (size == 256) {
 		byte color = new_palette[0];
@@ -548,7 +548,7 @@
 					if (color && !masked && !skip_column) {
 						pcolor = palette[color];
 						if (_shadow_mode == 1) {
-							if (pcolor == 13)	
+							if (pcolor == 13)
 								pcolor = _shadow_table[*dst];
 						} else if (_shadow_mode == 2) {
 							warning("codec1_spec2"); // TODO
@@ -919,7 +919,7 @@
 	v1.destptr = (byte *)_out.pixels + v1.y * _out.pitch + v1.x;
 
 	codec1_genericDecode(v1);
-	
+
 	return drawFlag;
 }
 
@@ -983,7 +983,7 @@
 	_vm->drawBomp(bdd, !_mirror);
 
 	_vm->_bompActorPalettePtr = NULL;
-	
+
 	return 0;
 }
 
@@ -1020,7 +1020,7 @@
 			*buf = akos16.color;
 			buf += dir;
 		}
-		
+
 		if (akos16.unk5 == 0) {
 			AKOS16_FILL_BITS()
 			bits = akos16.bits & 3;
@@ -1075,7 +1075,7 @@
 	}
 
 	maskpitch = _numStrips;
-	
+
 	maskptr = _vm->getMaskBuffer(maskLeft, maskTop, zBuf);
 
 	assert(t_height > 0);
@@ -1104,7 +1104,7 @@
 		warning("codec16: _actorHitMode not yet implemented");
 		return 0;
 	}
-	
+
 	if (!_mirror) {
 		clip.left = (_actorX - xmoveCur - _width) + 1;
 	} else {
@@ -1249,7 +1249,7 @@
 	if (diff > 0) {
 		src.bottom -= diff;
 		dst.bottom -= diff;
-	}	
+	}
 
 	if (dst.isValidRect() == false)
 		return 0;
@@ -1352,7 +1352,7 @@
 				curpos += 3;
 				break;
 			case AKC_SoundStuff:
-				if (_heversion >= 61) 
+				if (_heversion >= 61)
 					curpos += 6;
 				else
 					curpos += 8;

Index: akos.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/akos.h,v
retrieving revision 1.41
retrieving revision 1.42
diff -u -d -r1.41 -r1.42
--- akos.h	15 May 2005 10:02:13 -0000	1.41
+++ akos.h	30 Jul 2005 21:11:23 -0000	1.42
@@ -1,6 +1,6 @@
 /* ScummVM - Scumm Interpreter
  * Copyright (C) 2001  Ludvig Strigeus
- * Copyright (C) 2001-2005 The ScummVM project 
+ * Copyright (C) 2001-2005 The ScummVM project
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
@@ -41,7 +41,7 @@
 	void loadCostume(int id);
 	byte increaseAnims(Actor *a);
 	void costumeDecodeData(Actor *a, int frame, uint usemask);
-	
+
 	//void animateLimb(int limb, int f);
 	bool hasManyDirections(int id) {
 		loadCostume(id);
@@ -113,7 +113,7 @@
 	void akos16SkipData(int32 numskip);
 	void akos16DecodeLine(byte *buf, int32 numbytes, int32 dir);
 	void akos16Decompress(byte *dest, int32 pitch, const byte *src, int32 t_width, int32 t_height, int32 dir, int32 numskip_before, int32 numskip_after, byte transparency, int maskLeft, int maskTop, int zBuf);
-	
+
 	void markRectAsDirty(Common::Rect rect);
 };
 

Index: base-costume.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/base-costume.cpp,v
retrieving revision 2.30
retrieving revision 2.31
diff -u -d -r2.30 -r2.31
--- base-costume.cpp	24 Jun 2005 15:23:07 -0000	2.30
+++ base-costume.cpp	30 Jul 2005 21:11:23 -0000	2.31
@@ -35,7 +35,7 @@
 		_out.pixels = vs.getBackPixels(0, 0);
 	else
 		_out.pixels = vs.getPixels(0, 0);
-	
+
 	_actorX += _vm->virtscr[0].xstart & 7;
 	_out.w = _out.pitch;
 	_out.pixels = (byte *)_out.pixels - (_vm->virtscr[0].xstart & 7);

Index: base-costume.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/base-costume.h,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -d -r1.39 -r1.40
--- base-costume.h	15 May 2005 10:02:13 -0000	1.39
+++ base-costume.h	30 Jul 2005 21:11:23 -0000	1.40
@@ -1,6 +1,6 @@
 /* ScummVM - Scumm Interpreter
  * Copyright (C) 2001  Ludvig Strigeus
- * Copyright (C) 2001-2005 The ScummVM project 
+ * Copyright (C) 2001-2005 The ScummVM project
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
@@ -65,7 +65,7 @@
 public:
 	BaseCostumeLoader(ScummEngine *vm) : _vm(vm) {}
 	virtual ~BaseCostumeLoader() {}
-	
+
 	virtual void loadCostume(int id) = 0;
 	virtual byte increaseAnims(Actor *a) = 0;
 	virtual void costumeDecodeData(Actor *a, int frame, uint usemask) = 0;
@@ -127,7 +127,7 @@
 		byte *destptr;
 		const byte *mask_ptr;
 	};
-	
+
 public:
 	BaseCostumeRenderer(ScummEngine *scumm) {
 		_actorID = 0;
@@ -137,7 +137,7 @@
 		_zbuf = 0;
 		_scaleX = _scaleY = 0;
 		_draw_top = _draw_bottom = 0;
-		
+
 		_vm = scumm;
 		_numStrips = -1;
 		_srcptr = 0;

Index: bomp.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/bomp.cpp,v
retrieving revision 2.33
retrieving revision 2.34
diff -u -d -r2.33 -r2.34
--- bomp.cpp	24 Jun 2005 15:23:07 -0000	2.33
+++ bomp.cpp	30 Jul 2005 21:11:23 -0000	2.34
@@ -77,7 +77,7 @@
 	assert(len > 0);
 
 	dst += len;
-	
+
 	int num;
 	byte code, color;
 
@@ -101,7 +101,7 @@
 void bompApplyMask(byte *line_buffer, byte *mask, byte maskbit, int32 size, byte transparency) {
 	while (1) {
 		do {
-			if (size-- == 0) 
+			if (size-- == 0)
 				return;
 			if (*mask & maskbit) {
 				*line_buffer = transparency;
@@ -288,7 +288,7 @@
 		if (bd.scale_y != 255) {
 			// A bit set means we should skip this line...
 			tmp = skip_y_new & skip_y_bits;
-			
+
 			// Advance the scale-skip bit mask, if it's 0, get the next scale-skip byte
 			skip_y_bits /= 2;
 			if (skip_y_bits == 0) {
@@ -297,7 +297,7 @@
 			}
 
 			// Skip the current line if the above check tells us to
-			if (tmp != 0) 
+			if (tmp != 0)
 				continue;
 		}
 
@@ -313,11 +313,11 @@
 			// Replace the parts of the line which are masked with the transparency color
 			if (bd.maskPtr)
 				bompApplyMask(line_ptr, mask, maskbit, width, 255);
-	
+
 			// Apply custom color map, if available
 			if (_bompActorPalettePtr)
 				bompApplyActorPalette(_bompActorPalettePtr, line_ptr, width);
-			
+
 			// Finally, draw the decoded, scaled, masked and recolored line onto
 			// the target surface, using the specified shadow mode
 			bompApplyShadow(bd.shadowMode, _shadowPalette, line_ptr, dst, width, 255);
@@ -361,7 +361,7 @@
 	count = (256 - size / 2);
 	assert(0 <= count && count < 768);
 	tmp_ptr = bigCostumeScaleTable + count;
-	
+
 	count = (size + 7) / 8;
 	while (count--) {
 		a = 0;

Index: boxes.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/boxes.cpp,v
retrieving revision 1.90
retrieving revision 1.91
diff -u -d -r1.90 -r1.91
--- boxes.cpp	24 Jun 2005 15:23:07 -0000	1.90
+++ boxes.cpp	30 Jul 2005 21:11:23 -0000	1.91
@@ -85,7 +85,7 @@
 
 
 byte ScummEngine::getMaskFromBox(int box) {
-	// Fix for bug #740244 and #755863. This appears to have been a 
+	// Fix for bug #740244 and #755863. This appears to have been a
 	// long standing bug in the original engine?
 	if (_version <= 3 && box == 255)
 		return 1;
@@ -163,7 +163,7 @@
 	Box *ptr = getBoxBaseAddr(box);
 	if (!ptr)
 		return 255;
-		
+
 	int slot , scale;
 
 	if (_version == 8) {
@@ -180,9 +180,9 @@
 
 	// Was a scale slot specified? If so, we compute the effective scale
 	// from it, ignoring the box scale.
-	if (slot) 
+	if (slot)
     scale = getScaleFromSlot(slot, x, y);
-	
+
 	return scale;
 }
 
@@ -219,7 +219,7 @@
 		scale = 1;
 	else if (scale > 255)
 		scale = 255;
-	
+
 	return scale;
 }
 
@@ -255,36 +255,36 @@
 	byte *resptr = getResourceAddress(rtScaleTable, slot);
 	int lowerIdx, upperIdx;
 	float m, oldM;
-	
+
 	// Do nothing if the given scale table doesn't exist
 	if (resptr == 0)
 		return;
-	
+
 	if (resptr[0] == resptr[199]) {
 		// The scale is constant. This usually means we encountered one of the
-		// "broken" cases. We set pseudo scale item values which lead to a 
+		// "broken" cases. We set pseudo scale item values which lead to a
 		// constant scale of 255.
 		setScaleSlot(slot, 0, 0, 255, 0, 199, 255);
 		return;
 	}
-	
+
 	/*
 	 * Essentially, what we are doing here is some kind of "line fitting"
 	 * algorithm. The data in the scale table represents a linear graph. What
 	 * we want to find is the slope and (vertical) offset of this line. Things
 	 * are complicated by the fact that the line is cut of vertically at 1 and
 	 * 255. We have to be careful in handling this and some border cases.
-	 * 
+	 *
 	 * Some typical graphs look like these:
 	 *       ---         ---     ---
-	 *      /         ---           \ 
+	 *      /         ---           \
 	 *  ___/       ---               \___
-	 * 
+	 *
 	 * The method used here is to compute the slope of secants fixed at the
 	 * left and right end. For most cases this detects the cut-over points
-	 * quite accurately. 
+	 * quite accurately.
 	 */
-	
+
 	// Search for the bend on the left side
 	m = (resptr[199] - resptr[0]) / 199.0;
 	for (lowerIdx = 0; lowerIdx < 199 && (resptr[lowerIdx] == 1 || resptr[lowerIdx] == 255); lowerIdx++) {
@@ -298,7 +298,7 @@
 				break;
 		}
 	}
-	
+
 	// Search for the bend on the right side
 	m = (resptr[199] - resptr[0]) / 199.0;
 	for (upperIdx = 199; upperIdx > 1 && (resptr[upperIdx] == 1 || resptr[upperIdx] == 255); upperIdx--) {
@@ -322,7 +322,7 @@
 
 	// The values of y1 and y2, as well as the scale, can now easily be computed
 	setScaleSlot(slot, 0, lowerIdx, resptr[lowerIdx], 0, upperIdx, resptr[upperIdx]);
-	
+
 	// Compute the variance, for debugging. It shouldn't exceed 1
 	ScaleSlot &s = _scaleSlots[slot-1];
 	int y;
@@ -477,7 +477,7 @@
 		box->ul.y = (short)FROM_LE_32(bp->v8.uly);
 		box->ur.x = (short)FROM_LE_32(bp->v8.urx);
 		box->ur.y = (short)FROM_LE_32(bp->v8.ury);
-	
+
 		box->ll.x = (short)FROM_LE_32(bp->v8.llx);
 		box->ll.y = (short)FROM_LE_32(bp->v8.lly);
 		box->lr.x = (short)FROM_LE_32(bp->v8.lrx);
@@ -505,7 +505,7 @@
 		box->ul.y = bp->v2.uy * 2;
 		box->ur.x = bp->v2.urx * 8;
 		box->ur.y = bp->v2.uy * 2;
-	
+
 		box->ll.x = bp->v2.llx * 8;
 		box->ll.y = bp->v2.ly * 2;
 		box->lr.x = bp->v2.lrx * 8;
@@ -515,7 +515,7 @@
 		box->ul.y = (int16)READ_LE_UINT16(&bp->old.uly);
 		box->ur.x = (int16)READ_LE_UINT16(&bp->old.urx);
 		box->ur.y = (int16)READ_LE_UINT16(&bp->old.ury);
-	
+
 		box->ll.x = (int16)READ_LE_UINT16(&bp->old.llx);
 		box->ll.y = (int16)READ_LE_UINT16(&bp->old.lly);
 		box->lr.x = (int16)READ_LE_UINT16(&bp->old.lrx);
@@ -649,7 +649,7 @@
 	BoxCoords box;
 
 	getBoxCoordinates(b, &box);
-	
+
 	pt = closestPtOnLine(box.ul, box.ur, x, y);
 	dist = distanceFromPt(x, y, pt.x, pt.y);
 	if (dist < bestdist) {
@@ -704,7 +704,7 @@
 	byte i;
 	const int numOfBoxes = getNumBoxes();
 	int dest = -1;
-	
+
 	if (from == to)
 		return to;
 
@@ -713,7 +713,7 @@
 
 	if (from == Actor::kInvalidBox)
 		return to;
-	
+
 	assert(from < numOfBoxes);
 	assert(to < numOfBoxes);
 
@@ -759,7 +759,7 @@
 			dest = (int8)boxm[2];
 		boxm += 3;
 	}
-	
+
 	if (boxm >= end)
 		warning("The box matrix apparently is truncated (room %d)", _roomResource);
 
@@ -986,7 +986,7 @@
 				}
 			}
 		}
-	
+
 	}
 
 	// "Compress" the distance matrix into the box matrix format used
@@ -995,12 +995,12 @@
 	// followed by an arbitrary number of byte triples; the end is marked
 	// again by the lead 0xFF for the next "row". The meaning of the
 	// byte triples is as follows: the first two bytes define a range
-	// of box numbers (e.g. 7-11), while the third byte defines an 
-	// itineray box. Assuming we are in the 5th "row" and encounter 
+	// of box numbers (e.g. 7-11), while the third byte defines an
+	// itineray box. Assuming we are in the 5th "row" and encounter
 	// the triplet 7,11,15: this means to get from box 5 to any of
 	// the boxes 7,8,9,10,11 the shortest way is to go via box 15.
 	// See also getPathToDestBox.
-	
+
 	byte *matrixStart = res.createResource(rtMatrix, 1, BOX_MATRIX_SIZE);
 	const byte *matrixEnd = matrixStart + BOX_MATRIX_SIZE;
 
@@ -1020,7 +1020,7 @@
 		}
 	}
 	addToMatrix(0xFF);
-	
+
 
 #if BOX_DEBUG
 	printf("Itinerary matrix:\n");
@@ -1183,7 +1183,7 @@
 	Common::Point boxCorner[8];
 	int line1, line2;
 
-	// For all corner coordinates of the first box, compute the point closest 
+	// For all corner coordinates of the first box, compute the point closest
 	// to them on the second box (and also compute the distance of these points).
 	getBoxCoordinates(box1, &coords);
 	boxCorner[0] = coords.ul;

Index: boxes.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/boxes.h,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- boxes.h	1 Jan 2005 16:09:13 -0000	1.11
+++ boxes.h	30 Jul 2005 21:11:23 -0000	1.12
@@ -1,6 +1,6 @@
 /* ScummVM - Scumm Interpreter
  * Copyright (C) 2001  Ludvig Strigeus
- * Copyright (C) 2001-2005 The ScummVM project 
+ * Copyright (C) 2001-2005 The ScummVM project
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License

Index: charset.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/charset.cpp,v
retrieving revision 2.150
retrieving revision 2.151
diff -u -d -r2.150 -r2.151
--- charset.cpp	24 Jun 2005 15:23:08 -0000	2.150
+++ charset.cpp	30 Jul 2005 21:11:23 -0000	2.151
@@ -159,7 +159,7 @@
 		warning("Invaild Char! f %x s %x base %x c %d p %d", f, s, base, c, p);
 		return 0;
 	}
-	
+
 	debug(6, "Kanji: %c%c f 0x%x s 0x%x base 0x%x c %d p %d chunk %d cr %d index %d", f, s, f, s, base, c, p, chunk, cr, ((chunk_f + chunk) * 32 + (s - base)) + cr);
 	return ((chunk_f + chunk) * 32 + (s - base)) + cr;
 }
@@ -286,7 +286,7 @@
 	if (offs) {
 		spacing = _fontPtr[offs] + (signed char)_fontPtr[offs + 2];
 	}
-	
+
 	return spacing;
 }
 
@@ -974,7 +974,7 @@
 };
 
 // Spanish Zak font.
-// FIXME: This is identical to germanCharsetDataV2 it seems?! 
+// FIXME: This is identical to germanCharsetDataV2 it seems?!
 static byte spanishCharsetDataV2[] = {
 	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
 	0x01, 0x03, 0x06, 0x0c, 0x18, 0x3e, 0x03, 0x00,
@@ -1254,7 +1254,7 @@
 	int drawTop = _top - vs->topline;
 
 	_vm->markRectAsDirty(vs->number, _left, _left + width, drawTop, drawTop + height);
-	
+
 	if (!_ignoreCharsetMask) {
 		_hasMask = true;
 		_textScreenID = vs->number;
@@ -1303,13 +1303,13 @@
 void CharsetRenderer::translateColor() {
 	// Based on disassembly
 	if (_vm->_renderMode == Common::kRenderCGA) {
-		static byte CGAtextColorMap[16] = {0,  3, 3, 3, 5, 5, 5,  15, 
+		static byte CGAtextColorMap[16] = {0,  3, 3, 3, 5, 5, 5,  15,
 										   15, 3, 3, 3, 5, 5, 15, 15};
 		_color = CGAtextColorMap[_color & 0x0f];
 	}
 
 	if (_vm->_renderMode == Common::kRenderHercA || _vm->_renderMode == Common::kRenderHercG) {
-		static byte HercTextColorMap[16] = {0, 15,  2, 15, 15,  5, 15,  15, 
+		static byte HercTextColorMap[16] = {0, 15,  2, 15, 15,  5, 15,  15,
 										   8, 15, 15, 15, 15, 15, 15, 15};
 		_color = HercTextColorMap[_color & 0x0f];
 	}
@@ -1324,7 +1324,7 @@
 	int is2byte = (chr >= 0x80 && _vm->_useCJKMode) ? 1 : 0;
 
 	checkRange(_vm->_numCharsets - 1, 1, _curId, "Printing with bad charset %d");
-	
+
 	if ((vs = _vm->findVirtScreen(_top)) == NULL && (vs = _vm->findVirtScreen(_top + getFontHeight())) == NULL)
 		return;
 
@@ -1348,7 +1348,7 @@
 		if (!charOffs)
 			return;
 		charPtr = _fontPtr + charOffs;
-		
+
 		width = charPtr[0];
 		height = charPtr[1];
 
@@ -1357,14 +1357,14 @@
 		} else {
 			offsX = (signed char)charPtr[2];
 		}
-	
+
 		offsY = (signed char)charPtr[3];
 
 		charPtr += 4;	// Skip over char header
 	}
 	origWidth = width;
 	origHeight = height;
-	
+
 	if (_shadowMode != kNoShadowMode) {
 		width++;
 		height++;
@@ -1412,7 +1412,7 @@
 		_hasMask = true;
 		_textScreenID = vs->number;
 	}
-	
+
 	if ((_vm->_heversion >= 71 && type >= 8) || (_vm->_heversion >= 90 && type == 0)) {
 #ifndef DISABLE_HE
 		if (_ignoreCharsetMask || !vs->hasTwoBuffers) {
@@ -1471,7 +1471,7 @@
 		if (_blitAlso && vs->hasTwoBuffers) {
 			// FIXME: Revisiting this code, I think the _blitAlso mode is likely broken
 			// right now -- we are copying stuff from "dstPtr" to "back", but "dstPtr" really
-			// only conatains charset data... 
+			// only conatains charset data...
 			// One way to fix this: don't copy etc.; rather simply render the char twice,
 			// once to each of the two buffers. That should hypothetically yield
 			// identical results, though I didn't try it and right now I don't know
@@ -1492,7 +1492,7 @@
 				back -= drawTop * backSurface.pitch;
 				dstPtr -= drawTop * dstSurface.pitch;
 			}
-		
+
 			// Blit the image data
 			if (w > 0) {
 				while (h-- > 0) {
@@ -1502,7 +1502,7 @@
 				}
 			}
 		}
-	}	
+	}
 
 	_left += origWidth;
 
@@ -1535,7 +1535,7 @@
 		if (!charOffs)
 			return;
 		charPtr = _fontPtr + charOffs;
-		
+
 		width = charPtr[0];
 		height = charPtr[1];
 
@@ -1563,7 +1563,7 @@
 	for (y = 0; y < height && y + drawTop < s.h; y++) {
 		for (x = 0; x < width; x++) {
 			color = (bits >> (8 - bpp)) & 0xFF;
-			
+
 			if (color && y + drawTop >= 0) {
 				*dst = _vm->_charsetColorMap[color];
 			}
@@ -1593,7 +1593,7 @@
 					*(dst + s.pitch) = _shadowColor;
 					if (_shadowMode != kFMTOWNSShadowMode)
 						*(dst + s.pitch + 1) = _shadowColor;
-				}					
+				}
 				*dst = _color;
 			}
 			dst++;
@@ -1688,7 +1688,7 @@
 		_hasMask = true;
 		_textScreenID = kMainVirtScreen;
 	}
-	
+
 	int drawTop = _top;
 	if (_ignoreCharsetMask) {
 		VirtScreen *vs = &_vm->virtscr[kMainVirtScreen];
@@ -1752,7 +1752,7 @@
 	int drawTop = _top - vs->topline;
 
 	_vm->markRectAsDirty(vs->number, _left, _left + width, drawTop, drawTop + height);
-	
+
 	if (!_ignoreCharsetMask) {
 		_hasMask = true;
 		_textScreenID = vs->number;

Index: charset.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/charset.h,v
retrieving revision 2.46
retrieving revision 2.47
diff -u -d -r2.46 -r2.47
--- charset.h	18 Jun 2005 15:44:40 -0000	2.46
+++ charset.h	30 Jul 2005 21:11:23 -0000	2.47
@@ -52,7 +52,7 @@
 
 class CharsetRenderer {
 public:
-	
+
 	Common::Rect _str;
 	int _nextLeft, _nextTop;
 
@@ -98,14 +98,14 @@
 	int getStringWidth(int a, const byte *str);
 	void addLinebreaks(int a, byte *str, int pos, int maxwidth);
 	void translateColor();
-	
+
 	virtual void setCurID(byte id) = 0;
 	int getCurID() { return _curId; }
-	
+
 	virtual int getFontHeight() = 0;
 	virtual int getCharHeight(byte chr) { return getFontHeight(); }
 	virtual int getCharWidth(byte chr) = 0;
-	
+
 	virtual void setColor(byte color) { _color = color; translateColor(); }
 };
 
@@ -130,7 +130,7 @@
 	CharsetRendererCommon(ScummEngine *vm);
 
 	void setCurID(byte id);
-	
+
 	int getFontHeight();
 };
 
@@ -140,7 +140,7 @@
 
 public:
 	CharsetRendererClassic(ScummEngine *vm) : CharsetRendererCommon(vm) {}
-	
+
 	void printChar(int chr);
 	void drawChar(int chr, const Graphics::Surface &s, int x, int y);
 
@@ -155,7 +155,7 @@
 
 public:
 	CharsetRendererNES(ScummEngine *vm) : CharsetRendererCommon(vm) {}
-	
+
 	void setCurID(byte id) {}
 	void printChar(int chr);
 	void drawChar(int chr, const Graphics::Surface &s, int x, int y);
@@ -170,7 +170,7 @@
 
 public:
 	CharsetRendererV3(ScummEngine *vm) : CharsetRendererCommon(vm) {}
-	
+
 	void printChar(int chr);
 	void drawChar(int chr, const Graphics::Surface &s, int x, int y);
 	void setCurID(byte id);
@@ -182,7 +182,7 @@
 class CharsetRendererV2 : public CharsetRendererV3 {
 public:
 	CharsetRendererV2(ScummEngine *vm, Common::Language language);
-	
+
 	void setCurID(byte id) {}
 	int getCharWidth(byte chr) { return 8; }
 };
@@ -196,11 +196,11 @@
 public:
 	CharsetRendererNut(ScummEngine *vm);
 	~CharsetRendererNut();
-	
+
 	void printChar(int chr);
 
 	void setCurID(byte id);
-	
+
 	int getFontHeight();
 	int getCharHeight(byte chr);
 	int getCharWidth(byte chr);

Index: costume.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/costume.cpp,v
retrieving revision 1.187
retrieving revision 1.188
diff -u -d -r1.187 -r1.188
--- costume.cpp	24 Jun 2005 15:23:08 -0000	1.187
+++ costume.cpp	30 Jul 2005 21:11:23 -0000	1.188
@@ -78,7 +78,7 @@
 	0x02, 0x00, 0x07, 0x0C, 0x04,
 	0x09, 0x0A, 0x12, 0x0B, 0x14,
 	0x0D, 0x11, 0x0F, 0x0E, 0x10,
-	0x17, 0x00, 0x01, 0x05, 0x16 
+	0x17, 0x00, 0x01, 0x05, 0x16
 };
 
 
@@ -92,7 +92,7 @@
 	int step;
 	Codec1 v1;
 
-	
+
 	const int scaletableSize = 128;
 	const bool newAmiCost = (_vm->_version == 5) && (_vm->_platform == Common::kPlatformAmiga);
 
@@ -383,7 +383,7 @@
 		while (len--) {
 			if (!rep)
 				color = *src++;
-			
+
 			if (0 <= y && y < _out.h && 0 <= v1.x && v1.x < _out.w) {
 				if (!_mirror) {
 					LINE(0, 0); LINE(2, 2); LINE(4, 4); LINE(6, 6);
@@ -467,7 +467,7 @@
 		do {
 			if (_scaleY == 255 || *scaleytab++ < _scaleY) {
 				masked = (y < 0 || y >= _out.h) || (v1.mask_ptr && (mask[0] & maskbit));
-				
+
 				if (color && !masked) {
 					if (_shadow_mode & 0x20) {
 						pcolor = _shadow_table[*dst];
@@ -534,7 +534,7 @@
 		do {
 			if (_scaleY == 255 || v1.scaletable[_scaleIndexY] < _scaleY) {
 				masked = (y < 0 || y >= _out.h) || (v1.mask_ptr && (mask[0] & maskbit));
-				
+
 				if (color && v1.x >= 0 && v1.x < _out.w && !masked) {
 					*dst = _palette[color];
 				}
@@ -608,8 +608,8 @@
 		error("Costume %d with format 0x%X is invalid", id, _format);
 	}
 
-	
-	// In GF_OLD_BUNDLE games, there is no actual palette, just a single color byte. 
+
+	// In GF_OLD_BUNDLE games, there is no actual palette, just a single color byte.
 	// Don't forget, these games were designed around a fixed 16 color HW palette :-)
 	// In addition, all offsets are shifted by 2; we accomodate that via a separate
 	// _baseptr value (instead of adding tons of if's throughout the code).
@@ -729,7 +729,7 @@
 
 	// Determine the position the limb is at
 	i = cost.curpos[limb] & 0x7FFF;
-	
+
 	// Get the frame pointer for that limb
 	frameptr = _loaded._baseptr + READ_LE_UINT16(_loaded._frameOffsets + limb * 2);
 
@@ -914,12 +914,12 @@
 	i = a->_cost.curpos[slot] & 0x7FFF;
 	end = a->_cost.end[slot];
 	code = _animCmds[i] & 0x7F;
-	
+
 	if (_vm->_version <= 3) {
 		if (_animCmds[i] & 0x80)
 			a->_cost.soundCounter++;
 	}
-	
+
 	do {
 		if (!highflag) {
 			if (i++ >= end)

Index: costume.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/costume.h,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -d -r1.37 -r1.38
--- costume.h	31 May 2005 22:09:35 -0000	1.37
+++ costume.h	30 Jul 2005 21:11:23 -0000	1.38
@@ -81,7 +81,7 @@
 class ClassicCostumeRenderer : public BaseCostumeRenderer {
 protected:
 	ClassicCostumeLoader _loaded;
-	
+
 	byte _scaleIndexX;						/* must wrap at 256 */
 	byte _scaleIndexY;
 	byte _palette[32];

Index: cursor.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/cursor.cpp,v
retrieving revision 2.46
retrieving revision 2.47
diff -u -d -r2.46 -r2.47
--- cursor.cpp	19 Jul 2005 17:53:45 -0000	2.46
+++ cursor.cpp	30 Jul 2005 21:11:23 -0000	2.47
@@ -133,7 +133,7 @@
 
 void ScummEngine::updateCursor() {
 	_system->setMouseCursor(_grabbedCursor, _cursor.width, _cursor.height,
-							_cursor.hotspotX, _cursor.hotspotY, 
+							_cursor.hotspotX, _cursor.hotspotY,
 							(_platform == Common::kPlatformNES ? _grabbedCursor[63] : 255),
 							(_heversion == 70 ? 2 : 1));
 }
@@ -254,7 +254,7 @@
 		size = READ_BE_UINT32(dataptr + 4);
 		if (size > sizeof(_grabbedCursor))
 			error("setCursorFromImg: Cursor image too large");
-		
+
 		bomp = findResource(MKID('BOMP'), dataptr);
 	}
 
@@ -342,8 +342,8 @@
 	}
 
 	assert(index >= 0 && index < 4);
-	
-//	const int oldID = _charset->getCurID(); 
+
+//	const int oldID = _charset->getCurID();
 
 	if (_version == 3) {
 		_charset->setCurID(0);
@@ -361,7 +361,7 @@
 	// s.h = 17 for FM-TOWNS Loom Japanese. Fixes bug #1166917
 	assert(s.w <= 16 && s.h <= 17);
 	s.bytesPerPixel = 1;
-	
+
 	_charset->drawChar(chr, s, 0, 0);
 
 	uint16 *ptr = _cursorImages[index];
@@ -373,7 +373,7 @@
 		}
 		ptr++;
 	}
-	
+
 //	_charset->setCurID(oldID);
 }
 
@@ -495,7 +495,7 @@
 		*(hotspot + (_cursor.width * 5) + 1) = color;
 	} else {
 		const uint16 *src;
-		
+
 		_cursor.hotspotX = _cursorHotspots[2 * _currentCursor];
 		_cursor.hotspotY = _cursorHotspots[2 * _currentCursor + 1];
 		src = _cursorImages[_currentCursor];
@@ -505,7 +505,7 @@
 
 		for (i = 0; i < 16; i++) {
 			for (j = 0; j < 16; j++) {
-				if (src[i] & (1 << j))	
+				if (src[i] & (1 << j))
 					_grabbedCursor[16 * i + 15 - j] = color;
 			}
 		}

Index: debugger.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/debugger.cpp,v
retrieving revision 1.152
retrieving revision 1.153
diff -u -d -r1.152 -r1.153
--- debugger.cpp	11 Jul 2005 10:59:14 -0000	1.152
+++ debugger.cpp	30 Jul 2005 21:11:23 -0000	1.153
@@ -68,7 +68,7 @@
 
 	debug(buf);
 }
-	
+
 ScummDebugger::ScummDebugger(ScummEngine *s)
 	: Common::Debugger<ScummDebugger>() {
 	_vm = s;
@@ -563,7 +563,7 @@
 	if ((argc == 1) && (_vm->_debugFlags > 0)) {
 		for (int i = 0; i < numChannels; i++) {
 			if (_vm->_debugFlags & debugChannels[i].flag)
-				DebugPrintf("%s - %s\n", debugChannels[i].channel, 
+				DebugPrintf("%s - %s\n", debugChannels[i].channel,
 							 debugChannels[i].desc);
 		}
 		return true;
@@ -629,7 +629,7 @@
 	DebugPrintf("Camera: cur (%d,%d) - dest (%d,%d) - accel (%d,%d) -- last (%d,%d)\n",
 		_vm->camera._cur.x, _vm->camera._cur.y, _vm->camera._dest.x, _vm->camera._dest.y,
 		_vm->camera._accel.x, _vm->camera._accel.y, _vm->camera._last.x, _vm->camera._last.y);
-		
+
 	return true;
 }
 

Index: debugger.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/debugger.h,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -d -r1.37 -r1.38
--- debugger.h	21 Jun 2005 22:19:02 -0000	1.37
+++ debugger.h	30 Jul 2005 21:11:24 -0000	1.38
@@ -31,7 +31,7 @@
 public:
 	ScummDebugger(ScummEngine *s);
 	virtual ~ScummDebugger(); // we need this here for __SYMBIAN32__
-	
+
 protected:
 	ScummEngine *_vm;
 	bool  _old_soundsPaused;
@@ -67,7 +67,7 @@
 	bool Cmd_Hide(int argc, const char **argv);
 
 	bool Cmd_IMuse (int argc, const char **argv);
-	
+
 	void printBox(int box);
 	void drawBox(int box);
 };

Index: dialogs.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/dialogs.cpp,v
retrieving revision 1.148
retrieving revision 1.149
diff -u -d -r1.148 -r1.149
--- dialogs.cpp	5 Jul 2005 20:22:37 -0000	1.148
+++ dialogs.cpp	30 Jul 2005 21:11:24 -0000	1.149
@@ -119,25 +119,25 @@
 	{94, "text speed"}, //boot26
 	{95, "text display"}, //boot27
 	{96, "the dig v1.0"},*/
-	
+
 };
 
 static ResString string_map_table_v6[] = {
-	{117, "How may I serve you?"}, 
-	{109, "Select a game to LOAD"}, 
-	{108, "Name your SAVE game"}, 
-	{96, "Save"}, 
-	{97, "Load"}, 
-	{98, "Play"}, 
-	{99, "Cancel"}, 
-	{100, "Quit"}, 
-	{101, "OK"}, 
-	{93, "Game paused"}, 
+	{117, "How may I serve you?"},
+	{109, "Select a game to LOAD"},
+	{108, "Name your SAVE game"},
+	{96, "Save"},
+	{97, "Load"},
+	{98, "Play"},
+	{99, "Cancel"},
+	{100, "Quit"},
+	{101, "OK"},
+	{93, "Game paused"},
 	{210, "Game version"}
 };
 
 static ResString string_map_table_v5[] = {
-	{28, "How may I serve you?"}, 
+	{28, "How may I serve you?"},
 	{20, "Select a game to LOAD"},
 	{19, "Name your SAVE game"},
 	{7, "Save"},
@@ -181,7 +181,7 @@
 	// Convert to a proper string (take care of FF codes)
 	byte chr;
 	String tmp;
-	while ((chr = *result++)) {		
+	while ((chr = *result++)) {
 		if (chr == 0xFF) {
 			result += 3;
 		} else if (chr != '@') {
@@ -211,7 +211,7 @@
 
 public:
 	SaveLoadChooser(const String &title, const String &buttonLabel, bool saveMode);
-	
+
 	virtual void handleCommand(CommandSender *sender, uint32 cmd, uint32 data);
 	const String &getResultString() const;
 	void setList(const StringList& list) { GUI_ChooserDialog::setList(list); }
@@ -275,23 +275,23 @@
 
 public:
 	SaveLoadChooserEx(const String &title, const String &buttonLabel, bool saveMode, ScummEngine *engine);
-	
+
 	virtual void handleCommand(CommandSender *sender, uint32 cmd, uint32 data);
-	const String &getResultString() const;	
+	const String &getResultString() const;
 	void setList(const StringList& list);
 	int runModal();
 };
 
 SaveLoadChooserEx::SaveLoadChooserEx(const String &title, const String &buttonLabel, bool saveMode, ScummEngine *engine)
 	: Dialog(8, 8, engine->_system->getOverlayWidth() - 2 * 8, engine->_system->getOverlayHeight() - 16), _saveMode(saveMode), _list(0), _chooseButton(0), _gfxWidget(0), _scumm(engine) {
-	
+
 	new StaticTextWidget(this, 10, 6, _w - 2 * 10, kLineHeight, title, kTextAlignCenter);
-	
+
 	// Add choice list
 	_list = new GUI::ListWidget(this, 10, 18, _w - 2 * 10 - 180, _h - 14 - kBigButtonHeight - 18, GUI::kBigWidgetSize);
 	_list->setEditable(saveMode);
 	_list->setNumberingMode(saveMode ? GUI::kListNumberingOne : GUI::kListNumberingZero);
-	
+
 	// Add the thumbnail display
 	_gfxWidget = new GUI::GraphicsWidget(this,
 			_w - (kThumbnailWidth + 22),
@@ -299,7 +299,7 @@
 			kThumbnailWidth + 8,
 			((_scumm->_system->getHeight() % 200 && _scumm->_system->getHeight() != 350) ? kThumbnailHeight2 : kThumbnailHeight1) + 8);
 	_gfxWidget->setFlags(GUI::WIDGET_BORDER);
-	
+
 	// Buttons
 	addButton(this, _w - 2 * (kBigButtonWidth + 10), _h - kBigButtonHeight - 8, "Cancel", kCloseCmd, 0, GUI::kBigWidgetSize);
 	_chooseButton = addButton(this, _w - (kBigButtonWidth + 10), _h - kBigButtonHeight - 8, buttonLabel, kChooseCmd, 0, GUI::kBigWidgetSize);
@@ -391,7 +391,7 @@
 
 	const int screenW = g_system->getOverlayWidth();
 	const int screenH = g_system->getOverlayHeight();
-	
+
 	int hOffset;
 	int vSpace;
 	int vAddOff;
@@ -417,7 +417,7 @@
 	}
 
 	int y = vSpace + vAddOff;
-	
+
 
 	addBigButton("Resume", kPlayCmd, 'P');
 	y += vSpace;
@@ -640,7 +640,7 @@
 	}
 
 	GUI_OptionsDialog::close();
-	
+
 	_vm->setupVolumes();
 }
 
@@ -851,12 +851,12 @@
 void ValueDisplayDialog::drawDialog() {
 	g_gui.blendRect(_x, _y, _w, _h, g_gui._bgcolor);
 	g_gui.box(_x, _y, _w, _h, g_gui._color, g_gui._shadowcolor);
-	
+
 	const int labelWidth = _w - 8 - _percentBarWidth;
 
 	// Draw the label
 	g_gui.drawString(_label, _x + 4, _y + 4, labelWidth, g_gui._textcolor);
-	
+
 	// Draw the percentage bar
 	g_gui.fillRect(_x + 4 + labelWidth, _y + 4, _percentBarWidth * (_value - _min) / (_max - _min), _h - 8, g_gui._textcolorhi);
 	g_gui.frameRect(_x + 4 + labelWidth, _y + 4, _percentBarWidth, _h - 8, g_gui._textcolor);
@@ -876,7 +876,7 @@
 			_value++;
 		else if (ascii == _decKey && _value > _min)
 			_value--;
-		
+
 		setResult(_value);
 		_timer = getMillis() + kDisplayDelay;
 		draw();

Index: dialogs.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/dialogs.h,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -d -r1.56 -r1.57
--- dialogs.h	5 Jul 2005 20:22:38 -0000	1.56
+++ dialogs.h	30 Jul 2005 21:11:24 -0000	1.57
@@ -43,7 +43,7 @@
 public:
 	ScummDialog(ScummEngine *scumm, int x, int y, int w, int h)
 		: GUI::Dialog(x, y, w, h), _vm(scumm) {}
-	
+
 protected:
 	typedef Common::String String;
 
@@ -60,7 +60,7 @@
 {
 public:
 	virtual ~BaseSaveLoadChooser() {};
-	
+
 	virtual const Common::String &getResultString() const = 0;
 	virtual void setList(const Common::StringList& list) = 0;
 	virtual int runModal() = 0;
@@ -143,7 +143,7 @@
 	// from resources
 	InfoDialog(ScummEngine *scumm, int res);
 
-	virtual void handleMouseDown(int x, int y, int button, int clickCount) { 
+	virtual void handleMouseDown(int x, int y, int button, int clickCount) {
 		setResult(0);
 		close();
 	}
@@ -187,7 +187,7 @@
 	virtual void open();
 	virtual void drawDialog();
 	virtual void handleTickle();
-	virtual void handleMouseDown(int x, int y, int button, int clickCount) { 
+	virtual void handleMouseDown(int x, int y, int button, int clickCount) {
 		close();
 	}
 	virtual void handleKeyDown(uint16 ascii, int keycode, int modifiers);

Index: gfx.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/gfx.cpp,v
retrieving revision 2.463
retrieving revision 2.464
diff -u -d -r2.463 -r2.464
--- gfx.cpp	24 Jun 2005 15:23:09 -0000	2.463
+++ gfx.cpp	30 Jul 2005 21:11:24 -0000	2.464
@@ -100,7 +100,7 @@
 			0,  0,  0, 24
 		}
 	},
-	
+
 	// Box wipe (a box expands from the upper-left corner to the lower-right corner)
 	{
 		25,		// Number of iterations
@@ -117,7 +117,7 @@
 		  255,  0,  0,  0
 		}
 	},
-	
+
 	// Box wipe (a box expands from the lower-right corner to the upper-left corner)
 	{
 		25,		// Number of iterations
@@ -134,7 +134,7 @@
 		  255,  0,  0,  0
 		}
 	},
-	
+
 	// Inverse box wipe
 	{
 		25,		// Number of iterations
@@ -185,7 +185,7 @@
 			255, 0,  0,  0
 		}
 	}
-	
+
 };
 #endif
 
@@ -241,7 +241,7 @@
 	} else if (_vm->_version == 2) {
 		_roomStrips = generateStripTable(roomptr + IM00_offs, _vm->_roomWidth, _vm->_roomHeight, _roomStrips);
 	}
-	
+
 	_transparentColor = transparentColor;
 }
 
@@ -287,7 +287,7 @@
 	initVirtScreen(kVerbVirtScreen, h + adj, _screenWidth, _screenHeight - h - adj, false, false);
 	_screenB = b;
 	_screenH = h;
-	
+
 	gdi.init();
 }
 
@@ -421,7 +421,7 @@
 void ScummEngine::drawDirtyScreenParts() {
 	// Update verbs
 	updateDirtyScreen(kVerbVirtScreen);
-	
+
 	// Update the conversation area (at the top of the screen)
 	updateDirtyScreen(kTextVirtScreen);
 
@@ -521,7 +521,7 @@
 	assert(x >= 0 && width <= vs->pitch);
 	assert(_charset->_textSurface.pixels);
 	assert(_compositeBuf);
-	
+
 	if (width > vs->w - x)
 		width = vs->w - x;
 
@@ -534,7 +534,7 @@
 	// Convert the vertical coordinates to real screen coords
 	int y = vs->topline + top - _screenTop;
 	int height = bottom - top;
-	
+
 	// Compute screen etc. buffer pointers
 	const byte *src = vs->getPixels(x, top);
 	byte *dst = _compositeBuf + x + y * _screenWidth;
@@ -573,7 +573,7 @@
 	if (_renderMode == Common::kRenderHercA || _renderMode == Common::kRenderHercG) {
 		ditherHerc(_compositeBuf + x + y * _screenWidth, _herculesBuf, _screenWidth, &x, &y, &width, &height);
 		// center image on the screen
-		_system->copyRectToScreen(_herculesBuf + x + y * Common::kHercW, 
+		_system->copyRectToScreen(_herculesBuf + x + y * Common::kHercW,
 			Common::kHercW, x + (Common::kHercW - _screenWidth * 2) / 2, y, width, height);
 	} else {
 		// Finally blit the whole thing to the screen
@@ -864,7 +864,7 @@
 
 	const int height = rect.height();
 	const int width = rect.width();
-	
+
 	if (!height)
 		return;
 
@@ -897,7 +897,7 @@
 			return;
 
 		_vm->markRectAsDirty(vs->number, Common::Rect(vs->w, vs->h), USAGE_BIT_RESTORED);
-	
+
 		byte *screenBuf = vs->getPixels(0, 0);
 
 		if (vs->hasTwoBuffers && _vm->_currentRoom != 0 && _vm->isLightOn()) {
@@ -945,7 +945,7 @@
 	assert(h > 0);
 	assert(src != NULL);
 	assert(dst != NULL);
-	
+
 	if (w == srcPitch && w == dstPitch) {
 		memcpy(dst, src, w*h);
 	} else {
@@ -960,7 +960,7 @@
 static void fill(byte *dst, int dstPitch, byte color, int w, int h) {
 	assert(h > 0);
 	assert(dst != NULL);
-	
+
 	if (w == dstPitch) {
 		memset(dst, color, w*h);
 	} else {
@@ -1016,7 +1016,7 @@
 	// Adjust for the topline of the VirtScreen
 	y -= vs->topline;
 	y2 -= vs->topline;
-	
+
 	// Clip the coordinates
 	if (x < 0)
 		x = 0;
@@ -1037,7 +1037,7 @@
 		return;
 	else if (y2 > vs->h)
 		y2 = vs->h;
-	
+
 	width = x2 - x;
 	height = y2 - y;
 
@@ -1084,7 +1084,7 @@
 	if (_flashlight.isDrawn) {
 		markRectAsDirty(kMainVirtScreen, _flashlight.x, _flashlight.x + _flashlight.w,
 										_flashlight.y, _flashlight.y + _flashlight.h, USAGE_BIT_DIRTY);
-		
+
 		if (_flashlight.buffer) {
 			fill(_flashlight.buffer, vs->pitch, 0, _flashlight.w, _flashlight.h);
 		}
@@ -1152,7 +1152,7 @@
 			_flashlight.buffer[maxrow + maxcol - j] = 0;
 		}
 	}
-	
+
 	_flashlight.isDrawn = true;
 }
 
@@ -1211,7 +1211,7 @@
 		theX = 0;
 		maxX = width;
 	}
-	
+
 	// Decode and draw the image data.
 	assert(height <= 128);
 	for (; theX < maxX; theX++) {
@@ -1265,7 +1265,7 @@
 		do {
 			if (!runFlag)
 				data = *src++;
-			
+
 			if (left <= theX) {
 				*mask_ptr = data;
 				mask_ptr += _numStrips;
@@ -1303,7 +1303,7 @@
 	else {
 		numzbuf = _numZBuffer;
 		assert(numzbuf <= 9);
-		
+
 		if (_vm->_features & GF_SMALL_HEADER) {
 			if (_vm->_features & GF_16COLOR)
 				zplane_list[1] = ptr + READ_LE_UINT16(ptr);
@@ -1320,7 +1320,7 @@
 		} else if (_vm->_version == 8) {
 			// Find the OFFS chunk of the ZPLN chunk
 			const byte *zplnOffsChunkStart = ptr + 24 + READ_BE_UINT32(ptr + 12);
-			
+
 			// Each ZPLN contains a WRAP chunk, which has (as always) an OFFS subchunk pointing
 			// at ZSTR chunks. These once more contain a WRAP chunk which contains nothing but
 			// an OFFS chunk. The content of this OFFS chunk contains the offsets to the
@@ -1341,13 +1341,13 @@
 				MKID('ZP03'),
 				MKID('ZP04')
 			};
-			
+
 			for (i = 1; i < numzbuf; i++) {
 				zplane_list[i] = _vm->findResource(zplane_tags[i], ptr);
 			}
 		}
 	}
-	
+
 	return numzbuf;
 }
 
@@ -1376,7 +1376,7 @@
 	const bool lightsOn = _vm->isLightOn();
 
 	_objectMode = (flag & dbObjectMode) == dbObjectMode;
-	
+
 	if (_objectMode && _vm->_version == 1) {
 		if (_vm->_platform == Common::kPlatformNES) {
 			decodeNESObject(ptr, x, y, width, height);
@@ -1397,7 +1397,7 @@
 	assert(smap_ptr);
 
 	numzbuf = getZPlanes(ptr, zplane_list, false);
-	
+
 	const byte *tmsk_ptr = NULL;
 	if (_vm->_heversion >= 72) {
 		tmsk_ptr = _vm->findResource(MKID('TMSK'), ptr);
@@ -1613,9 +1613,9 @@
 	_decomp_shr = code % 10;
 	_decomp_mask = 0xFF >> (8 - _decomp_shr);
 	code /= 10;
-		
+
 	switch (code) {
-	case 13:	
+	case 13:
 		drawStripHE(dst, vs->pitch, bmap_ptr, vs->w, vs->h, false);
 		break;
 	case 14:
@@ -1674,7 +1674,7 @@
 		rect1.right -= rect2.left;
 		rect1.top -= rect2.top;
 		rect1.bottom -= rect2.top;
-		
+
 		copyVirtScreenBuffers(rect1);
 	}
 #endif
@@ -1706,13 +1706,13 @@
 
 	const int rw = rect.width();
 	const int rh = rect.height();
-	
+
 	if (rw == 0 || rh == 0)
 		return;
 
 	src = _vm->virtscr[0].getBackPixels(rect.left, rect.top);
 	dst = _vm->virtscr[0].getPixels(rect.left, rect.top);
-	
+
 	assert(rw <= _vm->_screenWidth && rw > 0);
 	assert(rh <= _vm->_screenHeight && rh > 0);
 	blit(dst, _vm->virtscr[0].pitch, src, _vm->virtscr[0].pitch, rw, rh);
@@ -1726,7 +1726,7 @@
 	VirtScreen *vs = &_vm->virtscr[0];
 	byte *backbuff_ptr, *bgbak_ptr;
 	int numLinesToProcess;
-	
+
 	if (bottom >= vs->h)
 		bottom = vs->h;
 
@@ -1756,7 +1756,7 @@
 
 bool Gdi::decompressBitmap(byte *dst, int dstPitch, const byte *src, int numLinesToProcess) {
 	assert(numLinesToProcess);
-	
+
 	if (_vm->_features & GF_16COLOR) {
 		drawStripEGA(dst, dstPitch, src, numLinesToProcess);
 		return false;
@@ -1764,39 +1764,39 @@
 
 	byte code = *src++;
 	bool useOrDecompress = false;
-	
+
 	if (code <= 10) {
 		switch (code) {
 		case 1:
 			unkDecode7(dst, dstPitch, src, numLinesToProcess);
 			break;
-	
+
 		case 2:
 			unkDecode8(dst, dstPitch, src, numLinesToProcess);       /* Ender - Zak256/Indy256 */
 			break;
-	
+
 		case 3:
 			unkDecode9(dst, dstPitch, src, numLinesToProcess);       /* Ender - Zak256/Indy256 */
 			break;
-	
+
 		case 4:
 			unkDecode10(dst, dstPitch, src, numLinesToProcess);      /* Ender - Zak256/Indy256 */
 			break;
-	
+
 		case 7:
 			unkDecode11(dst, dstPitch, src, numLinesToProcess);      /* Ender - Zak256/Indy256 */
 			break;
-	
+
 		case 8:
 			// Used in 3DO versions of HE games
 			useOrDecompress = true;
 			drawStrip3DO(dst, dstPitch, src, numLinesToProcess, true);
 			break;
-	
+
 		case 9:
 			drawStrip3DO(dst, dstPitch, src, numLinesToProcess, false);
 			break;
-	
+
 		case 10:
 			// Used in Amiga version of Monkey Island 1
 			drawStripEGA(dst, dstPitch, src, numLinesToProcess);
@@ -1809,51 +1809,51 @@
 		_decomp_shr = code % 10;
 		_decomp_mask = 0xFF >> (8 - _decomp_shr);
 		code /= 10;
-		
+
 		switch (code) {
 		case 1:
 			drawStripBasicV(dst, dstPitch, src, numLinesToProcess, false);
 			break;
-	
+
 		case 2:
 			drawStripBasicH(dst, dstPitch, src, numLinesToProcess, false);
 			break;
-	
+
 		case 3:
 			useOrDecompress = true;
 			drawStripBasicV(dst, dstPitch, src, numLinesToProcess, true);
 			break;
-	
+
 		case 4:
 			useOrDecompress = true;
 			drawStripBasicH(dst, dstPitch, src, numLinesToProcess, true);
 			break;
-	
+
 		case 6:
 		case 10:
 			drawStripComplex(dst, dstPitch, src, numLinesToProcess, false);
 			break;
-	
+
 		case 8:
 		case 12:
 			useOrDecompress = true;
 			drawStripComplex(dst, dstPitch, src, numLinesToProcess, true);
 			break;
-	
+
 		case 13:
 			drawStripHE(dst, dstPitch, src, 8, numLinesToProcess, false);
 			break;
-	
+
 		case 14:
 			useOrDecompress = true;
 			drawStripHE(dst, dstPitch, src, 8, numLinesToProcess, true);
 			break;
-	
+
 		default:
 			error("Gdi::decompressBitmap: default case %d", code);
 		}
 	}
-	
+
 	return useOrDecompress;
 }
 
@@ -1935,7 +1935,7 @@
 
 	while (height) {
 		b = *src++;
-		
+
 		if (b & 0x80) {
 			b &= 0x7F;
 			c = *src++;
@@ -2350,7 +2350,7 @@
 	x = 0;
 	y = height;
 	width /= 8;
-	
+
 	for (;;) {
 		length = *src++;
 		const byte runFlag = length & 0x80;
@@ -2384,7 +2384,7 @@
 
 	while (x < 8) {
 		color = *src++;
-		
+
 		if (color & 0x80) {
 			run = color & 0x3f;
 
@@ -2423,7 +2423,7 @@
 			if (run == 0) {
 				run = *src++;
 			}
-			
+
 			for (z = 0; z < run; z++) {
 				*(dst + y * dstPitch + x) = _roomPalette[color & 0xf];
 
@@ -2451,12 +2451,12 @@
 	uint32 dataBit, data;
 	byte color;
 	int shift;
-	
+
 	color = *src++;
 	data = READ_LE_UINT24(src);
 	src += 3;
 	shift = 24;
-	
+
 	int x = width;
 	while (1) {
 		if (!transpCheck || color != _transparentColor)
@@ -2889,10 +2889,10 @@
 
 
 	if (_screenEffectFlag && effect != 0) {
-	
+
 		// Fill screen 0 with black
 		memset(vs->getPixels(0, 0), 0, vs->pitch * vs->h);
-	
+
 		// Fade to black with the specified effect, if any.
 		switch (effect) {
 		case 1:
@@ -2996,7 +2996,7 @@
 /**
  * Update width*height areas of the screen, in random order, until the whole
  * screen has been updated. For instance:
- * 
+ *
  * dissolveEffect(1, 1) produces a pixel-by-pixel dissolve
  * dissolveEffect(8, 8) produces a square-by-square dissolve
  * dissolveEffect(virtsrc[0].width, 1) produces a line-by-line dissolve
@@ -3089,7 +3089,7 @@
 
 	blits = 0;
 	blits_before_refresh = (3 * w * h) / 25;
-	
+
 	// Speed up the effect for CD Loom since it uses it so often. I don't
 	// think the original had any delay at all, so on modern hardware it
 	// wasn't even noticeable.

Index: gfx.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/gfx.h,v
retrieving revision 1.120
retrieving revision 1.121
diff -u -d -r1.120 -r1.121
--- gfx.h	21 May 2005 09:05:58 -0000	1.120
+++ gfx.h	30 Jul 2005 21:11:25 -0000	1.121
@@ -1,6 +1,6 @@
 /* ScummVM - Scumm Interpreter
  * Copyright (C) 2001  Ludvig Strigeus
- * Copyright (C) 2001-2005 The ScummVM project 
+ * Copyright (C) 2001-2005 The ScummVM project
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
@@ -84,7 +84,7 @@
 	 * ScummEngine:virtscr array).
 	 */
 	VirtScreenNumber number;
-	
+
 	/**
 	 * Vertical position of the virtual screen. Tells how much the virtual
 	 * screen is shifted along the y axis relative to the real screen.
@@ -94,7 +94,7 @@
 	 * horizontal scrolling in V7-V8 games.
 	 */
 	uint16 topline;
-	
+
 	/**
 	 * Horizontal scroll offset, tells how far the screen is scrolled to the
 	 * right. Only used for the main screen. After all, verbs and the
@@ -111,7 +111,7 @@
 	 * and useIm01Cursor()), we keep it (at least for now).
 	 */
 	bool hasTwoBuffers;
-	
+
 	/**
 	 * Pointer to the screen's back buffer, if it has one (see also
 	 * the hasTwoBuffers member).
@@ -154,7 +154,7 @@
 			bdirty[i] = bottom;
 		}
 	}
-	
+
 	byte *getPixels(int x, int y) const {
 		return (byte *)pixels + xstart + y * pitch + x;
 	}
@@ -184,7 +184,7 @@
 	uint16 shadowMode;
 
 	byte *maskPtr;
-	
+
 	BompDrawData() { memset(this, 0, sizeof(*this)); }
 };
 
@@ -199,7 +199,7 @@
 	int _numZBuffer;
 	int _imgBufOffs[8];
 	int32 _numStrips;
-	
+
 	Gdi(ScummEngine *vm);
 	~Gdi();
 
@@ -266,7 +266,7 @@
 	int getZPlanes(const byte *smap_ptr, const byte *zplane_list[9], bool bmapImage) const;
 
 	StripTable *generateStripTable(const byte *src, int width, int height, StripTable *table) const;
-	void drawBitmapV2Helper(const byte *ptr, VirtScreen *vs, int x, int y, const int width, const int height, 
+	void drawBitmapV2Helper(const byte *ptr, VirtScreen *vs, int x, int y, const int width, const int height,
 	                int stripnr, int numstrip);
 
 public:
@@ -281,7 +281,7 @@
 
 	void drawBMAPBg(const byte *ptr, VirtScreen *vs);
 	void drawBMAPObject(const byte *ptr, VirtScreen *vs, int obj, int x, int y, int w, int h);
-	
+
 	void copyVirtScreenBuffers(Common::Rect rect, int dirtybit = 0);
 
 	byte *getMaskBuffer(int x, int y, int z);

Index: help.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/help.cpp,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -d -r1.22 -r1.23
--- help.cpp	24 Jun 2005 15:23:11 -0000	1.22
+++ help.cpp	30 Jul 2005 21:11:25 -0000	1.23
@@ -50,11 +50,11 @@
 	case GID_FT:
 	case GID_CMI:
 		return 3;
-		break;  
+		break;
 /*	TODO - I don't know the controls for these games
 	case GID_PUTTDEMO:
 	case GID_PUTTPUTT:
-*/	
+*/
 	default:
 		return 2;
 	}

Index: imuse.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/imuse.cpp,v
retrieving revision 2.145
retrieving revision 2.146
diff -u -d -r2.145 -r2.146
--- imuse.cpp	24 Jun 2005 15:23:11 -0000	2.145
+++ imuse.cpp	30 Jul 2005 21:11:25 -0000	2.146
@@ -1226,7 +1226,7 @@
 	byte buffer[52];
 	char info[256] = "ScummVM ";
 	int len;
-	
+
 	// Reset the MT-32
 	memcpy(&buffer[0], "\x41\x10\x16\x12\x7f\x00\x00\x01\x00", 9);
 	midi->sysEx(buffer, 9);
@@ -1255,7 +1255,7 @@
 	midi->sysEx(buffer, 31);
 	g_system->delayMillis(250);
 
-	// Map percussion to notes 24 - 34 without reverb 
+	// Map percussion to notes 24 - 34 without reverb
 	memcpy(&buffer[4], "\x03\x01\x10\x40\x64\x07\x00\x4a\x64\x06\x00\x41\x64\x07\x00\x4b\x64\x08\x00\x45\x64\x06\x00\x44\x64\x0b\x00\x51\x64\x05\x00\x43\x64\x08\x00\x50\x64\x07\x00\x42\x64\x03\x00\x4c\x64\x07\x00\x44", 48);
 	midi->sysEx(buffer, 52);
 	g_system->delayMillis(250);
@@ -1273,23 +1273,23 @@
 	g_system->delayMillis(200);
 
 	if (_enable_gs) {
-		
+
 		// All GS devices recognize the GS Reset command,
 		// even with Roland's ID. It is impractical to
-		// support other manufacturers' devices for 
+		// support other manufacturers' devices for
 		// further GS settings, as there are limitless
 		// numbers of them out there that would each
 		// require individual SysEx commands with unique IDs.
 
 		// Roland GS SysEx ID
 		memcpy(&buffer[0], "\xF0\x41\x10\x42\x12", 5);
-	
+
 		// GS Reset
 		memcpy(&buffer[5], "\x40\x00\x7F\x00\x41\xF7", 6);
 		midi->sysEx(buffer, 11);
 		debug(2, "GS SysEx: GS Reset");
 		g_system->delayMillis(200);
-		
+
 		if (_sc55) {
 			// This mode is for GS devices that support an MT-32-compatible
 			// Map, such as the Roland Sound Canvas line of modules. It
@@ -1334,7 +1334,7 @@
 			midi->send((  0    << 16) | (38  << 8) | (0xB0 | i));
 			midi->send((  127  << 16) | (100 << 8) | (0xB0 | i));
 			midi->send((  127  << 16) | (101 << 8) | (0xB0 | i));
-		} 
+		}
 		debug(2, "GM Controller 6 Change: Channels 1-16 Pitch Bend Sensitivity is 12 semitones");
 
 		// Set channels 1-16 Mod. LFO1 Pitch Depth to 4
@@ -1580,7 +1580,7 @@
 
 	ser->saveLoadEntries(this, mainEntries);
 	ser->saveLoadArrayOf(_cmd_queue, ARRAYSIZE(_cmd_queue), sizeof(_cmd_queue[0]), cmdQueueEntries);
-	ser->saveLoadArrayOf(_snm_triggers, ARRAYSIZE(_snm_triggers), sizeof(_snm_triggers[0]), snmTriggerEntries); 
+	ser->saveLoadArrayOf(_snm_triggers, ARRAYSIZE(_snm_triggers), sizeof(_snm_triggers[0]), snmTriggerEntries);
 
 	// The players
 	for (i = 0; i < ARRAYSIZE(_players); ++i)

Index: imuse_internal.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/imuse_internal.h,v
retrieving revision 2.42
retrieving revision 2.43
diff -u -d -r2.42 -r2.43
--- imuse_internal.h	25 May 2005 09:32:19 -0000	2.42
+++ imuse_internal.h	30 Jul 2005 21:11:26 -0000	2.43
@@ -332,7 +332,7 @@
 	void sendAll();
 	void sendPitchBend();
 	bool clearToTransmit();
-	
+
 	Part() {
 		memset(this,0,sizeof(Part));
 	}

Index: input.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/input.cpp,v
retrieving revision 2.32
retrieving revision 2.33
diff -u -d -r2.32 -r2.33
--- input.cpp	24 Jun 2005 15:23:12 -0000	2.32
+++ input.cpp	30 Jul 2005 21:11:26 -0000	2.33
@@ -183,12 +183,12 @@
 		case OSystem::EVENT_RBUTTONUP:
 			_rightBtnPressed &= ~msDown;
 			break;
-		
+
 		// The following two cases enable dialog choices to be
 		// scrolled through in the SegaCD version of MI
 		// as nothing else uses the wheel don't bother
 		// checking the gameid
-			
+
 		case OSystem::EVENT_WHEELDOWN:
 			_keyPressed = 55;
 			break;
@@ -196,14 +196,14 @@
 		case OSystem::EVENT_WHEELUP:
 			_keyPressed = 54;
 			break;
-	
+
 		case OSystem::EVENT_QUIT:
 			if (_confirmExit)
 				confirmExitDialog();
 			else
 				_quit = true;
 			break;
-	
+
 		default:
 			break;
 		}
@@ -238,8 +238,8 @@
 		// Convert F-Keys for V1/V2 games (they start at 1 instead of at 315)
 		_lastKeyHit -= 314;
 	}
-	
-	
+
+
 	//
 	// Clip the mouse coordinates, and compute _virtualMouse.x (and clip it, too)
 	//
@@ -348,9 +348,9 @@
 		else
 		if (vm.cutScenePtr[vm.cutSceneStackPointer])
 			_lastKeyHit = (uint)VAR(VAR_CUTSCENEEXIT_KEY);
-		else 
-		// Skip talk 
-		if (VAR_TALKSTOP_KEY != 0xFF && _talkDelay > 0) 
+		else
+		// Skip talk
+		if (VAR_TALKSTOP_KEY != 0xFF && _talkDelay > 0)
 			_lastKeyHit = (uint)VAR(VAR_TALKSTOP_KEY);
 		else
 		// Escape

Index: instrument.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/instrument.cpp,v
retrieving revision 2.35
retrieving revision 2.36
diff -u -d -r2.35 -r2.36
--- instrument.cpp	24 Jun 2005 15:23:12 -0000	2.35
+++ instrument.cpp	30 Jul 2005 21:11:26 -0000	2.36
@@ -45,7 +45,7 @@
 	{ "foghorn   ",  60 },
 	{ "glop      ",  39 },
 //	{ "jacob's la", ??? },
-	{ "LeshBass  ",  33 }, 
+	{ "LeshBass  ",  33 },
 //	{ "lowsnort  ", ??? },
 	{ "ML explosn", 127 },
 	{ "ReggaeBass",  32 },
@@ -117,7 +117,7 @@
 const byte Instrument::_gmRhythmMap[35] = {
 	  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,
 	  0,  0,  0,  0,  0,  0,  0,  0, 36, 37, 38, 39, 40, 41, 66, 47,
-	 65, 48, 56}; 
+	 65, 48, 56};
        // This emulates the percussion bank setup LEC used with the MT-32,
        // where notes 24 - 34 were assigned instruments without reverb.
        // It also fixes problems on GS devices that map sounds to these

Index: intern.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/intern.h,v
retrieving revision 2.513
retrieving revision 2.514
diff -u -d -r2.513 -r2.514
--- intern.h	30 Jul 2005 05:58:48 -0000	2.513
+++ intern.h	30 Jul 2005 21:11:26 -0000	2.514
@@ -52,9 +52,9 @@
 		OpcodeProcV5 proc;
 		const char *desc;
 	};
-	
+
 	const OpcodeEntryV5 *_opcodesV5;
-	
+
 	uint16 _cursorImages[4][17];
 	byte _cursorHotspots[2 * 4];
 
@@ -294,7 +294,7 @@
 	virtual void ifNotStateCommon(byte type);
 	virtual void setStateCommon(byte type);
 	virtual void clearStateCommon(byte type);
-	
+
 	void resetSentence();
 	void setUserState(byte state);
 
@@ -452,7 +452,7 @@
 		OpcodeProcV6 proc;
 		const char *desc;
 	};
-	
+
 	enum ArrayType {
 		kBitArray = 1,
 		kNibbleArray = 2,
@@ -461,18 +461,18 @@
 		kIntArray = 5,
 		kDwordArray = 6
 	};
-	
+
 	#if !defined(__GNUC__)
 		#pragma START_PACK_STRUCTS
-	#endif	
-	
+	#endif
+
 	struct ArrayHeader {
 		int16 dim1;
 		int16 type;
 		int16 dim2;
 		byte data[1];
 	} GCC_PACK;
-	
+
 	#if !defined(__GNUC__)
 		#pragma END_PACK_STRUCTS
 	#endif
@@ -490,7 +490,7 @@
 		uint16 mode;
 	};
 
-	int _blastObjectQueuePos; 
+	int _blastObjectQueuePos;
 	BlastObject _blastObjectQueue[128];
 
 	struct BlastText {
@@ -744,7 +744,7 @@
 	const OpcodeEntryv60he *_opcodesv60he;
 
 	Common::File _hFileTable[17];
-	
+
 public:
 	ScummEngine_v60he(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16], int substResFileNameIndex) : ScummEngine_v6(detector, syst, gs, md5sum, substResFileNameIndex) {}
 
@@ -795,7 +795,7 @@
 		OpcodeProcv70he proc;
 		const char *desc;
 	};
-	
+
 	const OpcodeEntryv70he *_opcodesv70he;
 
 	ResExtractor *_resExtractor;
@@ -820,7 +820,7 @@
 	virtual void setupOpcodes();
 	virtual void executeOpcode(byte i);
 	virtual const char *getOpcodeDesc(byte i);
-	
+
 	virtual void setupScummVars();
 	virtual void initScummVars();
 
@@ -881,7 +881,7 @@
 	void postProcessAuxQueue();
 
 public:
-	/* Actor AuxQueue stuff (HE) */	
+	/* Actor AuxQueue stuff (HE) */
 	AuxBlock _auxBlocks[16];
 	uint16 _auxBlocksNum;
 	AuxEntry _auxEntries[16];
@@ -898,10 +898,10 @@
 		OpcodeProcV72he proc;
 		const char *desc;
 	};
-	
+
 #if !defined(__GNUC__)
 	#pragma START_PACK_STRUCTS
-#endif	
+#endif
 
 	struct ArrayHeader {
 		int32 type;      //0
@@ -945,10 +945,10 @@
 	ArrayHeader *defineArray(int array, int type, int dim2start, int dim2end, int dim1start, int dim1end);
 	virtual int readArray(int array, int idx2, int idx1);
 	virtual void writeArray(int array, int idx2, int idx1, int value);
-	void redimArray(int arrayId, int newDim2start, int newDim2end, 
+	void redimArray(int arrayId, int newDim2start, int newDim2end,
 					int newDim1start, int newDim1end, int type);
 	void checkArrayLimits(int array, int dim2start, int dim2end, int dim1start, int dim1end);
-	void copyArray(int array1, int a1_dim2start, int a1_dim2end, int a1_dim1start, int a1_dim1end, 
+	void copyArray(int array1, int a1_dim2start, int a1_dim2end, int a1_dim1start, int a1_dim1end,
 					int array2, int a2_dim2start, int a2_dim2end, int a2_dim1start, int a2_dim1end);
 	void copyArrayHelper(ArrayHeader *ah, int idx2, int idx1, int len1, byte **data, int *size, int *num);
 	virtual int setupStringArray(int size);
@@ -1037,7 +1037,7 @@
 		OpcodeProcV80he proc;
 		const char *desc;
 	};
-	
+
 	const OpcodeEntryV80he *_opcodesV80he;
 
 	int32 _heSBNGId;
@@ -1058,7 +1058,7 @@
 
 	void drawLine(int x1, int y1, int x, int unk1, int unk2, int type, int id);
 	void drawPixel(int x, int y, int flags);
-	
+
 	/* HE version 80 script opcodes */
 	void o80_loadSBNG();
 	void o80_getFileSize();
@@ -1142,7 +1142,7 @@
 	void getArrayDim(int array, int *dim2start, int *dim2end, int *dim1start, int *dim1end);
 	void sortArray(int array, int dim2start, int dim2end, int dim1start, int dim1end, int sortOrder);
 
-public:	
+public:
 	int getGroupSpriteArray(int spriteGroupId);
 
 protected:
@@ -1242,7 +1242,7 @@
 	virtual void setupOpcodes();
 	virtual void executeOpcode(byte i);
 	virtual const char *getOpcodeDesc(byte i);
-	
+
 	virtual void saveOrLoad(Serializer *s, uint32 savegameVersion);
 
 	virtual void decodeParseString(int a, int b);
@@ -1331,7 +1331,7 @@
 		OpcodeProcV8 proc;
 		const char *desc;
 	};
-	
+
 	const OpcodeEntryV8 *_opcodesV8;
 
 	struct ObjectNameId {
@@ -1359,7 +1359,7 @@
 
 	virtual uint fetchScriptWord();
 	virtual int fetchScriptWordSigned();
-	
+
 	virtual int readVar(uint var);
 	virtual void writeVar(uint var, int value);
 
@@ -1384,7 +1384,7 @@
 	void o8_actorOps();
 	void o8_cameraOps();
 	void o8_verbOps();
-	
+
 	void o8_systemOps();
 	void o8_startVideo();
 	void o8_kernelSetFunctions();
@@ -1398,7 +1398,7 @@
 	void o8_getObjectImageY();
 	void o8_getObjectImageWidth();
 	void o8_getObjectImageHeight();
-	
+
 	void o8_getStringWidth();
 
 };

Index: logic_he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/logic_he.cpp,v
retrieving revision 2.23
retrieving revision 2.24
diff -u -d -r2.23 -r2.24
--- logic_he.cpp	24 Jun 2005 15:23:12 -0000	2.23
+++ logic_he.cpp	30 Jul 2005 21:11:26 -0000	2.24
@@ -176,7 +176,7 @@
 	op_sub1(_userData[520]);
 
 	_userData[521] = (float)args[5] / args[10];
-	
+
 	op_sub2(_userData[521]);
 
 	_userData[532] = (float)args[10];
@@ -220,7 +220,7 @@
 		op_sub3(temp);
 		retval = 1;
 	}
-	
+
 	temp = args[1] / _userData[532];
 
 	if (_userData[520] != temp) {
@@ -269,7 +269,7 @@
 
 int32 LogicHErace::op_1103(int32 *args) {
 	double angle = args[0] / args[1] * DEG2RAD;
-	
+
 	writeScummVar(108, (int32)(sin(angle) * args[2]));
 	writeScummVar(109, (int32)(cos(angle) * args[2]));
 
@@ -294,11 +294,11 @@
 
 	expr = a2 * _userDataD[17] + a1 * _userDataD[14] + a0 * _userDataD[11];
 
-	res1 = (atan2(a2 * _userDataD[15] + a1 * _userDataD[12] + a0 * _userDataD[9], expr) * RAD2DEG) 
+	res1 = (atan2(a2 * _userDataD[15] + a1 * _userDataD[12] + a0 * _userDataD[9], expr) * RAD2DEG)
 			/ _userData[526];
 	res2 = (atan2(a2 * _userDataD[16] + a1 * _userDataD[13] + a0 * _userDataD[10], expr) * RAD2DEG
 			- _userData[528]) / _userData[527];
-	
+
 	writeScummVar(108, (int32)res1);
 	writeScummVar(109, (int32)res2);
 
@@ -328,9 +328,9 @@
 	res = (args[0] - 2 * (arg2 * args[0] + arg3 * args[1]) * arg2) * 0.86956525;
 
 	writeScummVar(108, (int32)res);
-	
+
 	res = args[1] - 2 * (arg2 * args[0] + arg3 * args[1]) * arg3;
-	
+
 	if (-args[3] * args[3] >= 0)
 		res *= 0.83333331f;
 
@@ -432,7 +432,7 @@
 		data[i] = cos(at + a1) * sq;
 		data[i + 1] = sin(at + a1) * sq;
 	}
-	
+
 	int minx = 2;
 	int miny = 3;
 
@@ -468,7 +468,7 @@
 		data[2 * i] *= args1;
 		data[2 * i + 1] *= args2;
 	}
-	
+
 	for (i = 520; i <= 526; i += 2) {
 		putInArray(args[0], 0, i - 1, scumm_round(data[i - 520]));
 		putInArray(args[0], 0, i, scumm_round(data[i - 520 + 1]));
@@ -520,7 +520,7 @@
 	}
 
 	delta2 = diff2 * diff0_4 - diff1 * diff2_6;
-	
+
 	if (delta2 < 0) {
 		delta2 -= data7;
 	} else {
@@ -647,7 +647,7 @@
 int LogicHEfootball::op_1006(int32 *args) {
 	double res;
 
-	res = (1.0 - args[1] * 2.9411764e-4 * 5.3050399e-2) * args[0] * 1.2360656e-1 + 
+	res = (1.0 - args[1] * 2.9411764e-4 * 5.3050399e-2) * args[0] * 1.2360656e-1 +
 		args[1] * 1.1764706e-2 + 46;
 	writeScummVar(108, (int32)res);
 
@@ -682,7 +682,7 @@
 	double a1 = (640.0 - (double)args[1] - 26.0) * 8.6294413;
 	double res;
 
-	res = ((double)args[0] - 46 - a1 * 1.1764706e-2) / 
+	res = ((double)args[0] - 46 - a1 * 1.1764706e-2) /
 		((1.0 - a1 * 2.9411764e-4 * 5.3050399e-2) * 1.2360656e-1);
 	writeScummVar(108, (int32)res);
 
@@ -708,7 +708,7 @@
 	writeScummVar(108, (int32)res);
 	writeScummVar(109, (int32)var10);
 	writeScummVar(110, (int32)var8);
-	
+
 	return 1;
 }
 
@@ -722,20 +722,20 @@
 	var10 = (argf[3] - argf[1]) / (argf[2] - argf[0]);
 	var28 = var10 * var10 + 1;
 	var20 = argf[0] * var10;
-	var18 = (argf[5] + argf[1] + var20) * argf[4] * var10 * 2 + 
-		argf[6] * argf[6] * var28 + argf[4] * argf[4] - 
-		argf[0] * argf[0] * var10 * var10 - 
-		argf[5] * argf[0] * var10 * 2 - 
-		argf[5] * argf[1] * 2 - 
+	var18 = (argf[5] + argf[1] + var20) * argf[4] * var10 * 2 +
+		argf[6] * argf[6] * var28 + argf[4] * argf[4] -
+		argf[0] * argf[0] * var10 * var10 -
+		argf[5] * argf[0] * var10 * 2 -
+		argf[5] * argf[1] * 2 -
 		argf[1] * argf[1] - argf[5] * argf[5];
-	
+
 	if (var18 >= 0) {
 		var18 = sqrt(var18);
 
 		var30_ = argf[4] + argf[5] * var10 + argf[1] * var10 + argf[0] * var10 * var10;
 		var30 = (var30_ - var18) / var28;
 		var18 = (var30_ + var18) / var28;
-		
+
 		if ((argf[0] - var30 < 0) && (argf[0] - var18 < 0)) {
 			var30_ = var30;
 			var30 = var18;
@@ -754,7 +754,7 @@
 	writeScummVar(109, (int32)var28);
 	writeScummVar(110, (int32)var30);
 	writeScummVar(111, (int32)var20);
-	
+
 	return 1;
 }
 int LogicHEfootball::op_1024(int32 *args) {

Index: nut_renderer.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/nut_renderer.cpp,v
retrieving revision 1.62
retrieving revision 1.63
diff -u -d -r1.62 -r1.63
--- nut_renderer.cpp	24 Jun 2005 17:08:19 -0000	1.62
+++ nut_renderer.cpp	30 Jul 2005 21:11:26 -0000	1.63
@@ -188,7 +188,7 @@
 	int offsetY[7] = {  0, -1, 0, 1, 2, 1, 0 };
 	int cTable[7] =  {  0,  0, 0, 0, 0, 0, color };
 	int i = 0;
-	
+
 	if (!showShadow)
 		i = 6;
 
@@ -196,12 +196,12 @@
 		x += offsetX[i];
 		y += offsetY[i];
 		color = cTable[i];
-		
+
 		if (c >= 256 && _vm->_useCJKMode)
 			draw2byte(s, c, x, y, color);
 		else
 			drawChar(s, (byte)c, x, y, color);
-		
+
 		x -= offsetX[i];
 		y -= offsetY[i];
 	}

Index: object.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/object.cpp,v
retrieving revision 1.246
retrieving revision 1.247
diff -u -d -r1.246 -r1.247
--- object.cpp	24 Jun 2005 15:23:12 -0000	1.246
+++ object.cpp	30 Jul 2005 21:11:26 -0000	1.247
@@ -249,7 +249,7 @@
 			switch (FROM_LE_32(imhd->v8.version)) {
 			case 800:
 				x = od.x_pos + (int32)READ_LE_UINT32((const byte *)imhd + 8 * state + 0x44);
-				y = od.y_pos + (int32)READ_LE_UINT32((const byte *)imhd + 8 * state + 0x48); 
+				y = od.y_pos + (int32)READ_LE_UINT32((const byte *)imhd + 8 * state + 0x48);
 				break;
 			case 801:
 				x = od.x_pos + (int32)READ_LE_UINT32(&imhd->v8.hotspot[state].x);
@@ -353,7 +353,7 @@
 			}
 		} while ((_objs[b].state & mask) == a);
 	}
-	
+
 	return 0;
 }
 
@@ -387,9 +387,9 @@
 			if (_objs[i].obj_nr > 0 && (_objs[i].state & mask) && _objs[i].fl_object_index == 0)
 				drawRoomObject(i, arg);
 		}
-		// HACK: Reverse order is required to draw inventory background and items 
-		// in correct order in putttime/puttzoo. Otherwise the inventory background 
-		// is drawn over the items. But this doesn't match original, maybe masking 
+		// HACK: Reverse order is required to draw inventory background and items
+		// in correct order in putttime/puttzoo. Otherwise the inventory background
+		// is drawn over the items. But this doesn't match original, maybe masking
 		// issue somewhere?
 		for (i = 1; i < _numLocalObjects; i++) {
 			if (_objs[i].obj_nr > 0 && (_objs[i].state & mask) && _objs[i].fl_object_index != 0)
@@ -741,7 +741,7 @@
 		else
 			searchptr = room;
 	}
-		
+
 	cdhd = (const CodeHeader *)findResourceData(MKID('CDHD'), searchptr + od->OBCDoffset);
 	if (cdhd == NULL)
 		error("Room %d missing CDHD blocks(s)", _roomResource);
@@ -1087,7 +1087,7 @@
 	} else {
 		ptr = findResource(IMxx_tags[state], ptr);
 	}
-	
+
 	return ptr;
 }
 
@@ -1205,7 +1205,7 @@
 		numobj = roomptr[20];
 	} else {
 		const RoomHeader *roomhdr = (const RoomHeader *)findResourceData(MKID('RMHD'), roomptr);
-	
+
 		if (_version == 8)
 			numobj = READ_LE_UINT32(&(roomhdr->v8.numObjects));
 		else if (_version == 7)
@@ -1213,7 +1213,7 @@
 		else
 			numobj = READ_LE_UINT16(&(roomhdr->old.numObjects));
 	}
-	
+
 	if (numobj == 0)
 		error("findObjectInRoom: No object found in room %d", room);
 	if (numobj > _numLocalObjects)
@@ -1480,7 +1480,7 @@
 		warning("enqueueObject: overflow");
 		return;
 	}
-	
+
 	int idx = getObjectIndex(objectNumber);
 	assert(idx >= 0);
 
@@ -1555,7 +1555,7 @@
 		bdd.srcwidth = READ_LE_UINT16(&((const BompHeader *)bomp)->old.width);
 		bdd.srcheight = READ_LE_UINT16(&((const BompHeader *)bomp)->old.height);
 	}
-	
+
 	bdd.dst = *vs;
 	bdd.dst.pixels = vs->getPixels(0, 0);
 	// Skip the bomp header
@@ -1599,9 +1599,9 @@
 	int i;
 
 	r = eo->rect;
-	
+
 	r.clip(Common::Rect(vs->w, vs->h));
-	
+
 	if (r.width() <= 0 || r.height() <= 0)
 		return;
 

Index: palette.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/palette.cpp,v
retrieving revision 2.52
retrieving revision 2.53
diff -u -d -r2.52 -r2.53
--- palette.cpp	24 Jun 2005 16:14:37 -0000	2.52
+++ palette.cpp	30 Jul 2005 21:11:26 -0000	2.53
@@ -346,9 +346,9 @@
 	byte *end = palette + cycleEnd * size;
 	int num = cycleEnd - cycleStart;
 	byte tmp[6];
-	
+
 	assert(size <= 6);
-	
+
 	if (forward) {
 		memmove(tmp, end, size);
 		memmove(start + size, start, num * size);
@@ -375,13 +375,13 @@
 	int num = cycleEnd - cycleStart + 1;
 	int i;
 	int offset = forward ? 1 : num - 1;
-	
+
 	for (i = 0; i < 256; i++) {
 		if (cycleStart <= palette[i] && palette[i] <= cycleEnd) {
 			palette[i] = (palette[i] - cycleStart + offset) % num + cycleStart;
 		}
 	}
-	
+
 	doCyclePalette(palette, cycleStart, cycleEnd, 1, forward);
 }
 
@@ -521,7 +521,7 @@
 
 	if (!_palManipCounter || !_palManipPalette || !_palManipIntermediatePal)
 		return;
-	
+
 	target = _palManipPalette + _palManipStart * 3;
 	pal = _currentPalette + _palManipStart * 3;
 	between = _palManipIntermediatePal + _palManipStart * 6;
@@ -590,7 +590,7 @@
 	// There seems to be no explanation for why this function is called
 	// from within Room 23 (the big machine), as it has no shadow effects
 	// and thus doesn't result in any visual differences.
-	
+
 	if (_gameId == GID_SAMNMAX) {
 		for (i = 0; i < 256; i++)
 			_shadowPalette[i] = i;
@@ -715,7 +715,7 @@
 
 			if (diff != 0) {
 				int H, S, L;
-				
+
 				if (sum <= 255)
 					S = 255 * diff / sum;
 				else
@@ -732,13 +732,13 @@
 					H = H + 360;
 
 				// Scale the result
-	
+
 				H = (H * hueScale) / 255;
 				S = (S * satScale) / 255;
 				L = (sum * lightScale) / 255;
-	
+
 				// HLS to RGB (Foley and VanDam)
-	
+
 				int m1, m2;
 				if (L <= 255)
 					m2 = L * (255 + S) / (255 * 2);
@@ -967,7 +967,7 @@
 			*p++ = 0;
 		}
 	}
-	
+
 	_system->setPalette(palette_colors, first, num);
 
 	_palDirtyMax = -1;

Index: palette_he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/palette_he.cpp,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -d -r1.23 -r1.24
--- palette_he.cpp	24 Jun 2005 17:08:19 -0000	1.23
+++ palette_he.cpp	30 Jul 2005 21:11:26 -0000	1.24
@@ -306,7 +306,7 @@
 		*p++ = data[2];
 		*p++ = 0;
 	}
-	
+
 	_system->setPalette(palette_colors, _palDirtyMin, num);
 
 	_palDirtyMax = -1;

Index: player_mod.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/player_mod.h,v
retrieving revision 2.20
retrieving revision 2.21
diff -u -d -r2.20 -r2.21
--- player_mod.h	11 May 2005 00:01:26 -0000	2.20
+++ player_mod.h	30 Jul 2005 21:11:26 -0000	2.21
@@ -86,7 +86,7 @@
 	uint8 _maxvol;
 
 	virtual void do_mix(int16 *buf, uint len);
-	
+
 	ModUpdateProc *_playproc;
 	void *_playparam;
 };

Index: player_nes.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/player_nes.cpp,v
retrieving revision 2.4
retrieving revision 2.5
diff -u -d -r2.4 -r2.5
--- player_nes.cpp	24 Jun 2005 15:23:13 -0000	2.4
+++ player_nes.cpp	30 Jul 2005 21:11:26 -0000	2.5
@@ -122,7 +122,7 @@
 
 inline void Square0_Write(int Reg, byte Val) {
 	switch (Reg) {
-	case 0:	
+	case 0:
 		Square0.volume = Val & 0xF;
 		Square0.envelope = Val & 0x10;
 		Square0.wavehold = Val & 0x20;
@@ -130,7 +130,7 @@
 		Square0.Vol = Square0.envelope ? Square0.volume : Square0.Envelope;
 		break;
 
-	case 1:	
+	case 1:
 		Square0.swpstep = Val & 0x07;
 		Square0.swpdir = Val & 0x08;
 		Square0.swpspeed = (Val >> 4) & 0x7;
@@ -638,7 +638,7 @@
 	APU_writeControl(0);
 
 	APUe::APU_Reset();
-	
+
 	_mixer->setupPremix(this);
 }
 
@@ -695,7 +695,7 @@
 
 	int soundType = data[1];
 	int chan = data[0];
-	
+
 	if (chan == 4) {
 		if (_slot[2].framesleft)
 			return;
@@ -841,7 +841,7 @@
 				_mchan[x].envflags = 0x30;
 				_mchan[x].volume = 0x6F;
 				_mchan[x].voldelta = 0;
-				
+
 				APU_writeChannel(x, 0, 0x00);
 				APU_writeChannel(x, 1, 0x7F);
 				APU_writeControl(APU_readStatus() | channelMask[x]);
@@ -956,7 +956,7 @@
 				_mchan[x].envflags = 0x30;
 				_mchan[x].volume = 0x5F;
 				_mchan[x].voldelta = -22;
-				
+
 				APU_writeChannel(x, 0, 0x00);
 				APU_writeControl(APU_readStatus() | channelMask[x]);
 				APU_writeChannel(x, 2, _mchan[x].pitch & 0xF);
@@ -970,7 +970,7 @@
 				_mchan[x].envflags = 0x30;
 				_mchan[x].volume = 0x5F;
 				_mchan[x].voldelta = -6;
-				
+
 				APU_writeChannel(x, 0, 0x00);
 				APU_writeControl(APU_readStatus() | channelMask[x]);
 				APU_writeChannel(x, 2, _mchan[x].pitch & 0xF);
@@ -1030,7 +1030,7 @@
 
 			case 0x18:
 				_mchan[x].envflags = 0x70;
-				
+
 				chainCommand(x);
 				break;
 

Index: player_v1.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/player_v1.cpp,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -d -r1.26 -r1.27
--- player_v1.cpp	24 Jun 2005 16:14:37 -0000	1.26
+++ player_v1.cpp	30 Jul 2005 21:11:26 -0000	1.27
@@ -33,7 +33,7 @@
 #define TIMER_BASE_FREQ 1193000
 #define FIXP_SHIFT  16
 
-Player_V1::Player_V1(ScummEngine *scumm, bool pcjr) : Player_V2(scumm, pcjr) {	
+Player_V1::Player_V1(ScummEngine *scumm, bool pcjr) : Player_V2(scumm, pcjr) {
 	// Initialize channel code
 	for (int i = 0; i < 4; ++i)
 		clear_channel(i);
@@ -132,7 +132,7 @@
 
  parse_again:
 	_chunk_type = READ_LE_UINT16(_next_chunk);
-	debug(6, "parseSpeakerChunk: sound %d, offset %4x, chunk %x", 
+	debug(6, "parseSpeakerChunk: sound %d, offset %4x, chunk %x",
 			_current_nr, _next_chunk - _current_data, _chunk_type);
 
 	_next_chunk += 2;
@@ -169,7 +169,7 @@
 		_repeat_ctr = READ_LE_UINT16(_next_chunk + 8);
 		_channels[0].freq = _start;
 		_next_chunk += 10;
-		debug(6, "chunk 1: mplex %d, freq %d -> %d step %d  x %d", 
+		debug(6, "chunk 1: mplex %d, freq %d -> %d step %d  x %d",
 				_mplex, _start, _end, _delta, _repeat_ctr);
 		break;
 	case 2:
@@ -179,7 +179,7 @@
 		_channels[0].freq = 0;
 		_next_chunk += 6;
 		_forced_level = -1;
-		debug(6, "chunk 2: %d -> %d step %d", 
+		debug(6, "chunk 2: %d -> %d step %d",
 				_start, _end, _delta);
 		break;
 	case 3:
@@ -189,7 +189,7 @@
 		_channels[0].freq = 0;
 		_next_chunk += 6;
 		_forced_level = -1;
-		debug(6, "chunk 3: %d -> %d step %d", 
+		debug(6, "chunk 3: %d -> %d step %d",
 				_start, _end, _delta);
 		break;
 	}
@@ -208,7 +208,7 @@
 			_time_left = READ_LE_UINT16(_next_chunk);
 			_next_chunk += 2;
 		}
-		debug(7, "nextSpeakerCmd: chunk %d, offset %4x: notelen %d", 
+		debug(7, "nextSpeakerCmd: chunk %d, offset %4x: notelen %d",
 				_chunk_type, _next_chunk - 2 - _current_data, _time_left);
 		if (_time_left == 0) {
 			parseSpeakerChunk();
@@ -264,7 +264,7 @@
 parse_again:
 
 	_chunk_type = READ_LE_UINT16(_next_chunk);
-	debug(6, "parsePCjrChunk: sound %d, offset %4x, chunk %x", 
+	debug(6, "parsePCjrChunk: sound %d, offset %4x, chunk %x",
 		  _current_nr, _next_chunk - _current_data, _chunk_type);
 
 	_next_chunk += 2;
@@ -350,7 +350,7 @@
 			}
 			*_value_ptr_2 = _start_2;
 		}
-		debug(6, "chunk 1: %d: %d step %d for %d, %d: %d step %d for %d", 
+		debug(6, "chunk 1: %d: %d step %d for %d, %d: %d step %d for %d",
 			  _value_ptr - (uint*)_channels, _start, _delta, _time_left,
 			  _value_ptr_2 - (uint*)_channels, _start_2, _delta_2, _time_left_2);
 		break;
@@ -362,10 +362,10 @@
 		_channels[0].freq = 0;
 		_next_chunk += 6;
 		_forced_level = -1;
-		debug(6, "chunk 2: %d -> %d step %d", 
+		debug(6, "chunk 2: %d -> %d step %d",
 			  _start, _end, _delta);
 		break;
-	case 3: 
+	case 3:
 		set_mplex(READ_LE_UINT16(_next_chunk));
 		tmp = READ_LE_UINT16(_next_chunk + 2);
 		assert((tmp & 0xf0) == 0xe0);
@@ -407,7 +407,7 @@
 					_channels[i].hull_counter = 1;
 					_channels[i].freq = dummy;
 				}
-				debug(7, "chunk 0: channel %d play %d for %d", 
+				debug(7, "chunk 0: channel %d play %d for %d",
 					  i, dummy, _channels[i].notelen);
 				_channels[i].cmd_ptr += 4;
 			}
@@ -495,7 +495,7 @@
 			_channels[3].volume = dummy;
 			break;
 		}
-		
+
 		if (!--_repeat_ctr) {
 			parsePCjrChunk();
 			return;
@@ -566,7 +566,7 @@
 					/* HACK: this channel is playing at
 					 * the same frequency as another.
 					 * Synchronize it to the same phase to
-					 * prevent interference. 
+					 * prevent interference.
 					 */
 					_timer_count[i] = _timer_count[j];
 					_timer_output ^= (1 << i) &
@@ -586,16 +586,16 @@
 		} else if (i < 3) {
 			hasdata = true;
 			squareGenerator(i, freq, vol, 0, data, len);
-			debug(9, "channel[%d]: %8x: freq %d %.1f ; volume %d", 
+			debug(9, "channel[%d]: %8x: freq %d %.1f ; volume %d",
 				  i, _tick_len, freq, 111860.0 / freq,  vol);
 		} else {
 			int noiseFB = (freq & 4) ? FB_WNOISE : FB_PNOISE;
 			int n = (freq & 3);
-			
+
 			freq = (n == 3) ? 2 * (_channels[2].freq) : 1 << (5 + n);
 			hasdata = true;
 			squareGenerator(i, freq, vol, noiseFB, data, len);
-			debug(9, "channel[%d]: %x: noise freq %d %.1f ; volume %d", 
+			debug(9, "channel[%d]: %x: noise freq %d %.1f ; volume %d",
 				  i, _tick_len, freq, 111860.0 / freq,  vol);
 		}
 	}
@@ -604,4 +604,4 @@
 		lowPassFilter(data, len);
 }
 
-} // End of namespace Scumm 
+} // End of namespace Scumm

Index: player_v2.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/player_v2.cpp,v
retrieving revision 2.60
retrieving revision 2.61
diff -u -d -r2.60 -r2.61
--- player_v2.cpp	24 Jun 2005 15:23:13 -0000	2.60
+++ player_v2.cpp	30 Jul 2005 21:11:26 -0000	2.61
@@ -52,7 +52,7 @@
 static const uint16 *pcjr_freq_table;
 #else
 const uint8 note_lengths[] = {
-	0,  
+	0,
 	0,  0,  2,
 	0,  3,  4,
 	5,  6,  8,
@@ -63,8 +63,8 @@
 };
 
 static const uint16 hull_offsets[] = {
-	0, 12, 24, 36, 48, 60, 
-	72, 88, 104, 120, 136, 256, 
+	0, 12, 24, 36, 48, 60,
+	72, 88, 104, 120, 136, 256,
 	152, 164, 180
 };
 
@@ -193,7 +193,7 @@
    -70, -67, -65, -62, -59, -57, -54, -51,
    -48, -45, -42, -39, -36, -33, -30, -27,
    -24, -21, -18, -15, -12,  -9,  -6,  -3,
-  
+
      0,   1,   2,   3,   4,   5,   6,   7,
      8,   9,  10,  11,  12,  13,  14,  15,
     16,  17,  18,  19,  20,  21,  22,  23,
@@ -226,9 +226,9 @@
    -24, -23, -22, -21, -20, -19, -18, -17,
    -16, -15, -14, -13, -12, -11, -10,  -9,
     -8,  -7,  -6,  -5,  -4,  -3,  -2,  -1,
-  
+
   -120, 120,
-  
+
   -120,-120,-120,-120,-120,-120,-120,-120,
   -120,-120,-120,-120,-120,-120,-120,-120,
   -120,-120,-120,-120,-120,-120,-120,-120,
@@ -330,12 +330,12 @@
 
 
 static const uint16  spk_freq_table[12] = {
-	36484, 34436, 32503, 30679, 28957, 27332, 
+	36484, 34436, 32503, 30679, 28957, 27332,
 	25798, 24350, 22983, 21693, 20476, 19326
 };
 
 static const uint16 pcjr_freq_table[12] = {
-	65472, 61760, 58304, 55040, 52032, 49024, 
+	65472, 61760, 58304, 55040, 52032, 49024,
 	46272, 43648, 41216, 38912, 36736, 34624
 };
 #endif
@@ -351,10 +351,10 @@
 
 	_header_len = (scumm->_features & GF_OLD_BUNDLE) ? 4 : 6;
 
-	// Initialize sound queue 
+	// Initialize sound queue
 	_current_nr = _next_nr = 0;
 	_current_data = _next_data = 0;
-	
+
 	// Initialize channel code
 	for (i = 0; i < 4; ++i)
 		clear_channel(i);
@@ -419,7 +419,7 @@
 
 	/* scale to int16, FIXME: find best value */
 	double out = vol * 128 / 3;
-	
+
 	/* build volume table (2dB per step) */
 	for (int i = 0; i < 15; i++) {
 		/* limit volume to avoid clipping */
@@ -510,13 +510,13 @@
 		data = tdata;
 		restartable = data ? *(data + _header_len + 1) : 0;
 	}
-	
+
 	if (!_current_nr) {
 		nr = 0;
 		_next_nr = 0;
 		_next_data = 0;
 	}
-	
+
 	if (nr != _current_nr
 		&& restartable
 		&& (!_next_nr
@@ -564,14 +564,14 @@
 		if (opcode >= 0xf8) {
 			switch (opcode) {
 			case 0xf8: // set hull curve
-				debug(7, "channels[%d]: hull curve %2d", 
+				debug(7, "channels[%d]: hull curve %2d",
 				channel - _channels, *script_ptr);
 				channel->d.hull_curve = hull_offsets[*script_ptr / 2];
 				script_ptr++;
 				break;
 
 			case 0xf9: // set freqmod curve
-				debug(7, "channels[%d]: freqmod curve %2d", 
+				debug(7, "channels[%d]: freqmod curve %2d",
 				channel - _channels, *script_ptr);
 				channel->d.freqmod_table = freqmod_offsets[*script_ptr / 4];
 				channel->d.freqmod_modulo = freqmod_lengths[*script_ptr / 4];
@@ -642,7 +642,7 @@
 				opcode = *script_ptr++;
 				value = READ_LE_UINT16 (script_ptr);
 				channel->array[opcode / 2] = value;
-				debug(7, "channels[%d]: set param %2d = %5d", 
+				debug(7, "channels[%d]: set param %2d = %5d",
 						channel - &_channels[0], opcode, value);
 				script_ptr += 2;
 				if (opcode == 14) {
@@ -670,7 +670,7 @@
 					is_last_note = note & 0x80;
 					note &= 0x7f;
 					if (note == 0x7f) {
-						debug(8, "channels[%d]: pause %d", 
+						debug(8, "channels[%d]: pause %d",
 							  channel - _channels, channel->d.time_left);
 						goto end;
 					}
@@ -679,7 +679,7 @@
 					channel->d.time_left = ((opcode & 7) << 8) | *script_ptr++;
 
 					if ((opcode & 0x10)) {
-						debug(8, "channels[%d]: pause %d", 
+						debug(8, "channels[%d]: pause %d",
 							  channel - _channels, channel->d.time_left);
 						goto end;
 					}
@@ -688,7 +688,7 @@
 					note = (*script_ptr++) & 0x7f;
 				}
 
-				debug(8, "channels[%d]: @%04x note: %3d+%d len: %2d hull: %d mod: %d/%d/%d %s", 
+				debug(8, "channels[%d]: @%04x note: %3d+%d len: %2d hull: %d mod: %d/%d/%d %s",
 						dest_channel - channel, script_ptr ? script_ptr - _current_data - 2 : 0,
 						note, (signed short) dest_channel->d.transpose, channel->d.time_left,
 						dest_channel->d.hull_curve, dest_channel->d.freqmod_table,
@@ -697,7 +697,7 @@
 
 				uint16 myfreq;
 				dest_channel->d.time_left = channel->d.time_left;
-				dest_channel->d.note_length = 
+				dest_channel->d.note_length =
 					channel->d.time_left - dest_channel->d.inter_note_pause;
 				note += dest_channel->d.transpose;
 				while (note < 0)
@@ -749,7 +749,7 @@
 	channel->d.freqmod_offset += channel->d.freqmod_incr;
 	if (channel->d.freqmod_offset > channel->d.freqmod_modulo)
 		channel->d.freqmod_offset -= channel->d.freqmod_modulo;
-	channel->d.freq = 
+	channel->d.freq =
 		(int) (freqmod_table[channel->d.freqmod_table + (channel->d.freqmod_offset >> 4)])
 		* (int) channel->d.freqmod_multiplier / 256
 		+ channel->d.base_freq;
@@ -770,7 +770,7 @@
 	}
 
 #if 0
-	debug(9, "channels[%d]: freq %d hull %d/%d/%d", 
+	debug(9, "channels[%d]: freq %d hull %d/%d/%d",
 			channel - &_channels[0], channel->d.freq,
 			channel->d.hull_curve, channel->d.hull_offset,
 			channel->d.hull_counter);
@@ -849,10 +849,10 @@
 
 	for (uint i = 0; i < len; i++) {
 		unsigned int duration = 0;
-		
+
 		if (_timer_output & (1 << channel))
 			duration += _timer_count[channel];
-		
+
 		_timer_count[channel] -= (1 << FIXP_SHIFT);
 		while (_timer_count[channel] <= 0) {
 
@@ -871,11 +871,11 @@
 
 			_timer_count[channel] += period;
 		}
-		
+
 		if (_timer_output & (1 << channel))
 			duration -= _timer_count[channel];
-		
-		nsample = *sample + 
+
+		nsample = *sample +
 			(((signed long) (duration - (1 << (FIXP_SHIFT - 1)))
 				* (signed long) _volumetable[vol]) >> FIXP_SHIFT);
 		/* overflow: clip value */
@@ -902,12 +902,12 @@
 
 	memset(data, 0, 2 * sizeof(int16) * len);
 	if (winning_channel != -1) {
-		squareGenerator(0, _channels[winning_channel].d.freq, 0, 
+		squareGenerator(0, _channels[winning_channel].d.freq, 0,
 				0, data, len);
 	} else if (_level == 0)
 		/* shortcut: no sound is being played. */
 		return;
-	
+
 	lowPassFilter(data, len);
 }
 
@@ -928,7 +928,7 @@
 					/* HACK: this channel is playing at
 					 * the same frequency as another.
 					 * Synchronize it to the same phase to
-					 * prevent interference. 
+					 * prevent interference.
 					 */
 					_timer_count[i] = _timer_count[j];
 					_timer_output ^= (1 << i) &
@@ -951,13 +951,13 @@
 		} else {
 			int noiseFB = (freq & 4) ? FB_WNOISE : FB_PNOISE;
 			int n = (freq & 3);
-			
+
 			freq = (n == 3) ? 2 * (_channels[2].d.freq>>6) : 1 << (5 + n);
 			hasdata = true;
 			squareGenerator(i, freq, vol, noiseFB, data, len);
 		}
 #if 0
-		debug(9, "channel[%d]: freq %d %.1f ; volume %d", 
+		debug(9, "channel[%d]: freq %d %.1f ; volume %d",
 				i, freq, 111860.0 / freq,  vol);
 #endif
 	}
@@ -1001,4 +1001,4 @@
 _GRELEASEPTR(GBVARS_PCJRFREQTABLE_INDEX, GBVARS_SCUMM)
 _GEND
 
-#endif 
+#endif

Index: player_v2.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/player_v2.h,v
retrieving revision 2.35
retrieving revision 2.36
diff -u -d -r2.35 -r2.36
--- player_v2.h	10 May 2005 23:48:38 -0000	2.35
+++ player_v2.h	30 Jul 2005 21:11:26 -0000	2.36
@@ -38,7 +38,7 @@
 
 #if !defined(__GNUC__)
 	#pragma START_PACK_STRUCTS
-#endif	
+#endif
 
 struct channel_data {
 	uint16 time_left;          // 00
@@ -127,7 +127,7 @@
 		channel_data d;
 		uint16 array[sizeof(channel_data)/2];
 	};
-	
+
 	int _music_timer;
 	int _music_timer_ctr;
 	int _ticks_per_music_timer;
@@ -163,4 +163,4 @@
 
 } // End of namespace Scumm
 
-#endif 
+#endif

Index: player_v2a.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/player_v2a.cpp,v
retrieving revision 2.31
retrieving revision 2.32
diff -u -d -r2.31 -r2.32
--- player_v2a.cpp	24 Jun 2005 15:23:13 -0000	2.31
+++ player_v2a.cpp	30 Jul 2005 21:11:26 -0000	2.32
@@ -905,7 +905,7 @@
 	virtual void start(Player_MOD *mod, int id, const byte *data) {
 		_mod = mod;
 		_id = id;
-		
+
 		char *tmp_data1 = (char *)malloc(_size);
 		char *tmp_data2 = (char *)malloc(_size);
 		char *tmp_data3 = (char *)malloc(_size);
@@ -1416,4 +1416,4 @@
 	return 0;
 }
 
-} // End of namespace Scumm 
+} // End of namespace Scumm

Index: player_v3a.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/player_v3a.cpp,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -d -r1.24 -r1.25
--- player_v3a.cpp	24 Jun 2005 15:23:13 -0000	1.24
+++ player_v3a.cpp	30 Jul 2005 21:11:26 -0000	1.25
@@ -208,7 +208,7 @@
 
 	if (getSoundStatus(nr))
 		stopSound(nr);	// if a sound is playing, restart it
-	
+
 	if (data[26]) {
 		if (_curSong)
 			stopSound(_curSong);

Index: resource.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/resource.cpp,v
retrieving revision 1.330
retrieving revision 1.331
diff -u -d -r1.330 -r1.331
--- resource.cpp	24 Jun 2005 16:13:20 -0000	1.330
+++ resource.cpp	30 Jul 2005 21:11:26 -0000	1.331
@@ -152,7 +152,7 @@
 			if (_gameId == GID_MANIAC)
 				_demoMode = true;
 		}
-			
+
 		if (result) {
 			if (room == 0)
 				return;
@@ -230,18 +230,18 @@
 
 		result = file.openSubFile(filename);
 	}
-	
+
 	if (!result) {
 		file.close();
 		result = file.open(filename);
 	}
-	
+
 	return result;
 }
 
 bool ScummEngine::openResourceFile(const char *filename, byte encByte) {
 	debugC(DEBUG_GENERAL, "openResourceFile(%s)", filename);
-	
+
 	if (openFile(*_fileHandle, filename)) {
 		_fileHandle->setEnc(encByte);
 		return true;
@@ -269,7 +269,7 @@
 			error("Cannot find file: '%s'", filename);
 		}
 #endif
-	} else { 
+	} else {
 		sprintf(buf, "Cannot find file: '%s'", filename);
 		InfoDialog dialog(this, (char*)buf);
 		runDialog(dialog);
@@ -390,7 +390,7 @@
 	case MKID('DIRF'):
 		readResTypeList(rtCharset, MKID('CHAR'), "charset");
 		break;
-	
+
 	case MKID('DOBJ'):
 		debug(9, "found DOBJ block, reading object table");
 		readGlobalObjects();
@@ -419,11 +419,11 @@
 			}
 		}
 		break;
-	
+
 	case MKID('DIRM'):
 		readResTypeList(rtImage, MKID('AWIZ'), "images");
 		break;
-		
+
 	case MKID('DIRT'):
 		readResTypeList(rtTalkie, MKID('TLKE'), "talkie");
 		break;
@@ -605,7 +605,7 @@
 	// TODO: determine why the heck anything would try to load a costume
 	// with id 0. Is that "normal", or is it caused by yet another bug in
 	// our code base? After all we also have to add special cases for many
-	// of our script opcodes that check for the (invalid) actor 0... so 
+	// of our script opcodes that check for the (invalid) actor 0... so
 	// maybe both issues are related...
 	if (type != rtCharset && i == 0)
 		return;
@@ -716,7 +716,7 @@
 int ScummEngine::getResourceSize(int type, int idx) {
 	byte *ptr = getResourceAddress(type, idx);
 	MemBlkHeader *hdr = (MemBlkHeader *)(ptr - sizeof(MemBlkHeader));
-	
+
 	return hdr->size;
 }
 
@@ -1091,7 +1091,7 @@
 
 	_objectRoomTable = (byte *)calloc(_numGlobalObjects, 1);
 
-	if ((_gameId == GID_FT) && (_features & GF_DEMO) && 
+	if ((_gameId == GID_FT) && (_features & GF_DEMO) &&
 		(_platform == Common::kPlatformPC))
 		_numGlobalScripts = 300;
 	else
@@ -1171,7 +1171,7 @@
 		_classData[i] = _fileHandle->readUint32LE();
 	}
 	memset(_objectOwnerTable, 0xFF, num);
-	
+
 	// Finally, sort the object name->ID map, so we can later use
 	// bsearch on it. For this we (ab)use strcmp, which works fine
 	// since the table entries start with a string.
@@ -1276,24 +1276,24 @@
 		_pos = 8;
 		_ptr = searchin + 8;
 	}
-	
+
 }
 
 const byte *ResourceIterator::findNext(uint32 tag) {
 	uint32 size = 0;
 	const byte *result = 0;
-	
+
 	if (_smallHeader) {
 		uint16 smallTag = newTag2Old(tag);
 		do {
 			if (_pos >= _size)
 				return 0;
-	
+
 			result = _ptr;
 			size = READ_LE_UINT32(result);
 			if ((int32)size <= 0)
 				return 0;	// Avoid endless loop
-			
+
 			_pos += size;
 			_ptr += size;
 		} while (READ_LE_UINT16(result + 4) != smallTag);
@@ -1301,12 +1301,12 @@
 		do {
 			if (_pos >= _size)
 				return 0;
-	
+
 			result = _ptr;
 			size = READ_BE_UINT32(result + 4);
 			if ((int32)size <= 0)
 				return 0;	// Avoid endless loop
-			
+
 			_pos += size;
 			_ptr += size;
 		} while (READ_UINT32(result) != tag);

Index: resource.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/resource.h,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- resource.h	31 Mar 2005 23:11:39 -0000	1.16
+++ resource.h	30 Jul 2005 21:11:27 -0000	1.17
@@ -26,7 +26,7 @@
 enum {
 	OF_OWNER_MASK = 0x0F,
 	OF_STATE_MASK = 0xF0,
-	
+
 	OF_STATE_SHL = 4
 };
 

Index: resource_v2.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/resource_v2.cpp,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -d -r1.57 -r1.58
--- resource_v2.cpp	24 Jun 2005 16:13:21 -0000	1.57
+++ resource_v2.cpp	30 Jul 2005 21:11:27 -0000	1.58
@@ -173,7 +173,7 @@
 	switch (magic) {
 		case 0x0100:
 			printf("Enhanced V2 game detected\n");
-			readEnhancedIndexFile();			
+			readEnhancedIndexFile();
 			break;
 		case 0x0A31:
 			printf("Classic V1 game detected\n");

Index: resource_v7he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/resource_v7he.cpp,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -d -r1.44 -r1.45
--- resource_v7he.cpp	24 Jun 2005 15:23:13 -0000	1.44
+++ resource_v7he.cpp	30 Jul 2005 21:11:27 -0000	1.45
@@ -122,7 +122,7 @@
 	"fontdir", "font", "accelerator", "rcdata", "messagelist",
 	"group_cursor", NULL, "group_icon", NULL,
 	/* the following are not defined in winbase.h, but found in wrc. */
-	/* 0x10: */ 
+	/* 0x10: */
 	"version", "dlginclude", NULL, "plugplay", "vxd",
 	"anicursor", "aniicon"
 };
@@ -152,7 +152,7 @@
 	arg_type = res_type_string_to_id(arg_type);
 
 	WinLibrary fi;
-		
+
 	/* initiate stuff */
 	fi.memory = NULL;
 	fi.file = new Common::File;
@@ -290,7 +290,7 @@
                   bool *free_it, char *type, char *lang, bool raw) {
 	char *str;
 	int32 intval;
-	
+
 	/* just return pointer to data if raw */
 	if (raw) {
 		*free_it = false;
@@ -374,7 +374,7 @@
 				continue;
 		    }
 		    if ((uint32)iconsize != icondir->entries[c].bytes_in_res) {
-				debugC(DEBUG_RESOURCE, "%s: mismatch of size in icon resource `%s' and group (%d != %d)", 
+				debugC(DEBUG_RESOURCE, "%s: mismatch of size in icon resource `%s' and group (%d != %d)",
 					fi->file->name(), name, iconsize, icondir->entries[c].bytes_in_res);
 		    }
 		    size += iconsize; /* size += icondir->entries[c].bytes_in_res; */
@@ -405,7 +405,7 @@
 		char name[14];
 		WinResource *fwr;
 		byte *data;
-	
+
 		/* find the corresponding icon resource */
 		snprintf(name, sizeof(name)/sizeof(char), "-%d", icondir->entries[c].res_id);
 		fwr = find_resource(fi, (is_icon ? "-3" : "-1"), name, lang, &level);
@@ -505,7 +505,7 @@
 /* does the id of this entry match the specified id? */
 #define LEVEL_MATCHES(x) (x == NULL || x ## _wr->id[0] == '\0' || compare_resource_id(x ## _wr, x))
 
-int Win32ResExtractor::do_resources_recurs(WinLibrary *fi, WinResource *base, 
+int Win32ResExtractor::do_resources_recurs(WinLibrary *fi, WinResource *base,
 		  WinResource *type_wr, WinResource *name_wr, WinResource *lang_wr,
 		  const char *type, char *name, char *lang, int action, byte **data) {
 	int c, rescnt;
@@ -596,7 +596,7 @@
 	wr->numeric_id = (value & IMAGE_RESOURCE_NAME_IS_STRING ? false:true);
 	return true;
 }
- 
+
 byte *Win32ResExtractor::get_resource_entry(WinLibrary *fi, WinResource *wr, int *size) {
 	if (fi->is_PE_binary) {
 		Win32ImageResourceDataEntry *dataent;
@@ -1019,7 +1019,7 @@
 
 				width = bitmap.width;
 				height = ABS(bitmap.height)/2;
-				
+
 				image_size = height * ROW_BYTES(width * bitmap.bit_count);
 				mask_size = height * ROW_BYTES(width);
 
@@ -1304,7 +1304,7 @@
 					// And finally check if we have dumped resource fork
 					snprintf(_fileName, 128, "%s.rsrc", buf1);
 					if (!in.exists(_fileName)) {
-						error("Cannot open file any of files '%s', '%s.bin', '%s.rsrc", 
+						error("Cannot open file any of files '%s', '%s.bin', '%s.rsrc",
 							  buf1, buf1, buf1);
 					}
 				}
@@ -1387,7 +1387,7 @@
 		return false;
 	}
 
-	debug(7, "got header: data %d [%d] map %d [%d]", 
+	debug(7, "got header: data %d [%d] map %d [%d]",
 		_dataOffset, _dataLength, _mapOffset, _mapLength);
 
 	readMap(in);
@@ -1401,7 +1401,7 @@
 	int resNum = -1;
 	byte *buf;
 	int len;
-	
+
 	for (i = 0; i < _resMap.numTypes; i++)
 		if (strcmp(_resTypes[i].id, typeID) == 0) {
 			typeNum = i;
@@ -1434,7 +1434,7 @@
 
 void MacResExtractor::readMap(Common::File in) {
 	int	i, j, len;
-	
+
 	in.seek(_mapOffset + 22);
 
 	_resMap.resAttr = in.readUint16BE();
@@ -1453,22 +1453,22 @@
 		_resTypes[i].offset = in.readUint16BE();
 		_resTypes[i].items++;
 	}
-	
+
 	_resLists = new ResPtr[_resMap.numTypes];
-	
+
 	for (i = 0; i < _resMap.numTypes; i++) {
 		_resLists[i] = new Resource[_resTypes[i].items];
 		in.seek(_resTypes[i].offset + _mapOffset + _resMap.typeOffset);
 
 		for (j = 0; j < _resTypes[i].items; j++) {
 			ResPtr resPtr = _resLists[i] + j;
-			
+
 			resPtr->id = in.readUint16BE();
 			resPtr->nameOffset = in.readUint16BE();
 			resPtr->dataOffset = in.readUint32BE();
 			in.readUint32BE();
 			resPtr->name = 0;
-			
+
 			resPtr->attr = resPtr->dataOffset >> 24;
 			resPtr->dataOffset &= 0xFFFFFF;
 		}
@@ -1476,7 +1476,7 @@
 		for (j = 0; j < _resTypes[i].items; j++) {
 			if (_resLists[i][j].nameOffset != -1) {
 				in.seek(_resLists[i][j].nameOffset + _mapOffset + _resMap.nameOffset);
-				
+
 				len = in.readByte();
 				_resLists[i][j].name = new byte[len + 1];
 				_resLists[i][j].name[len] = 0;
@@ -1506,7 +1506,7 @@
 	dis.readUint32BE(); // expanded cursor data
 	dis.readUint16BE(); // expanded data depth
 	dis.readUint32BE(); // reserved
-	  
+
 	// Grab B/W icon data
 	*cursor = (byte *)malloc(16 * 16);
 	for (i = 0; i < 32; i++) {
@@ -1534,10 +1534,10 @@
 
 	dis.readUint32BE(); // reserved
 	dis.readUint32BE(); // cursorID
-	      
+
 	// Color version of cursor
 	dis.readUint32BE(); // baseAddr
-	
+
 	// Keep only lowbyte for now
 	dis.readByte();
 	iconRowBytes = dis.readByte();
@@ -1638,7 +1638,7 @@
 	num = READ_LE_UINT16(_heV7RoomOffsets);
 	ptr = _heV7RoomOffsets + 2;
 	for (i = 0; i < num; i++) {
-		res.roomoffs[rtRoom][i] = READ_LE_UINT32(ptr);	
+		res.roomoffs[rtRoom][i] = READ_LE_UINT32(ptr);
 		ptr += 4;
 	}
 }

Index: resource_v7he.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/resource_v7he.h,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- resource_v7he.h	18 May 2005 15:57:16 -0000	1.15
+++ resource_v7he.h	30 Jul 2005 21:11:27 -0000	1.16
@@ -123,7 +123,7 @@
 
 	virtual int extractResource(int id, byte **buf) { return 0; };
 	virtual int convertIcons(byte *data, int datasize, byte **cursor, int *w, int *h,
-							 int *hotspot_x, int *hotspot_y, int *keycolor, 
+							 int *hotspot_x, int *hotspot_y, int *keycolor,
 							 byte **palette, int *palSize) { return 0; };
 
 	enum {
@@ -166,12 +166,12 @@
  private:
 	int extractResource_(const char *resType, char *resName, byte **data);
 /*
- * Structures 
+ * Structures
  */
 
 #if !defined(__GNUC__)
 	#pragma START_PACK_STRUCTS
-#endif	
+#endif
 
 	struct WinLibrary {
 		Common::File *file;
@@ -546,7 +546,7 @@
 	ResMap _resMap;
 	ResType *_resTypes;
 	ResPtr  *_resLists;
-}; 
+};
 
 } // End of namespace Scumm
 

Index: room.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/room.cpp,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -d -r1.19 -r1.20
--- room.cpp	24 Jun 2005 16:14:37 -0000	1.19
+++ room.cpp	30 Jul 2005 21:11:27 -0000	1.20
@@ -75,7 +75,7 @@
 	if (_version >= 4 && _heversion <= 61)
 		stopCycle(0);
 	_sound->processSound();
-	
+
 	clearDrawQueues();
 
 	// For HE80+ games
@@ -136,7 +136,7 @@
 
 	loadRoomObjects();
 
-	
+
 	if (VAR_ROOM_WIDTH != 0xFF && VAR_ROOM_HEIGHT != 0xFF) {
 		VAR(VAR_ROOM_WIDTH) = _roomWidth;
 		VAR(VAR_ROOM_HEIGHT) = _roomHeight;
@@ -207,7 +207,7 @@
 /**
  * Init some static room data after a room has been loaded.
  * E.g. the room dimension, the offset to the graphics data, the room scripts,
- * the offset to the room palette and other things which won't be changed 
+ * the offset to the room palette and other things which won't be changed
  * late on.
  * So it is possible to call this after loading a savegame.
  */
@@ -234,7 +234,7 @@
 	// Determine the room dimensions (width/height)
 	//
 	rmhd = (const RoomHeader *)findResourceData(MKID('RMHD'), roomptr);
-	
+
 	if (_version == 8) {
 		_roomWidth = READ_LE_UINT32(&(rmhd->v8.width));
 		_roomHeight = READ_LE_UINT32(&(rmhd->v8.height));
@@ -412,7 +412,7 @@
 				_HEV7ActorPalette[i] = i;
 		}
 	}
-	
+
 	gdi.roomChanged(roomptr, _IM00_offs, trans);
 }
 
@@ -554,7 +554,7 @@
 	// Determine the room dimensions (width/height)
 	//
 	rmhd = (const RoomHeader *)(roomptr + 4);
-	
+
 	if (_version == 1) {
 		if (_platform == Common::kPlatformNES) {
 			_roomWidth = READ_LE_UINT16(&(rmhd->old.width)) * 8;

Index: saveload.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/saveload.cpp,v
retrieving revision 1.231
retrieving revision 1.232
diff -u -d -r1.231 -r1.232
--- saveload.cpp	24 Jun 2005 15:23:14 -0000	1.231
+++ saveload.cpp	30 Jul 2005 21:11:27 -0000	1.232
@@ -127,7 +127,7 @@
 		delete in;
 		return false;
 	}
-	
+
 	// Since version 52 a thumbnail is saved directly after the header
 	if (hdr.ver >= VER(52)) {
 		uint32 type;
@@ -155,7 +155,7 @@
 	// state for temporary state saves - such as certain cutscenes in DOTT,
 	// FOA, Sam and Max, etc.
 	//
-	// Thusly, we should probably not stop music when restoring from one of 
+	// Thusly, we should probably not stop music when restoring from one of
 	// these saves. This change stops the Mole Man theme from going quiet in
 	// Sam & Max when Doug tells you about the Ball of Twine, as mentioned in
 	// patch #886058.
@@ -183,7 +183,7 @@
 
 	memset(_inventory, 0, sizeof(_inventory[0]) * _numInventory);
 	memset(_newNames, 0, sizeof(_newNames[0]) * _numNewNames);
-	
+
 	// Because old savegames won't fill the entire gfxUsageBits[] array,
 	// clear it here just to be sure it won't hold any unforseen garbage.
 	memset(gfxUsageBits, 0, sizeof(gfxUsageBits));
@@ -207,7 +207,7 @@
 	Serializer ser(in, 0, hdr.ver);
 	saveOrLoad(&ser, hdr.ver);
 	delete in;
-	
+
 	// Update volume settings
 	setupVolumes();
 
@@ -222,7 +222,7 @@
 	// it is not, hence we check & correct it here.
 	if (_screenTop < 0)
 		_screenTop = 0;
-	
+
 	if (hdr.ver < VER(33) && _version >= 7) {
 		// For a long time, we didn't set these vars to default values.
 		VAR(VAR_DEFAULT_TALK_DELAY) = 60;
@@ -415,7 +415,7 @@
 	Common::InSaveFile *in;
 	SaveGameHeader hdr;
 	int len;
-	
+
 	makeSavegameName(filename, slot, false);
 	if (!(in = _saveFileMan->openForLoading(filename))) {
 		return 0;
@@ -531,7 +531,7 @@
 
 		MKARRAY(ScummEngine, _resourceMapper[0], sleByte, 128, VER(8)),
 		MKARRAY(ScummEngine, _charsetColorMap[0], sleByte, 16, VER(8)),
-		
+
 		// _charsetData grew from 10*16 to 15*16 bytes
 		MKARRAY_OLD(ScummEngine, _charsetData[0][0], sleByte, 10 * 16, VER(8), VER(9)),
 		MKARRAY(ScummEngine, _charsetData[0][0], sleByte, 15 * 16, VER(10)),
@@ -647,7 +647,7 @@
 		MK_OBSOLETE(ScummEngine, _cd_loops, sleInt16, VER(9), VER(9)),
 		MK_OBSOLETE(ScummEngine, _cd_frame, sleInt16, VER(9), VER(9)),
 		MK_OBSOLETE(ScummEngine, _cd_end, sleInt16, VER(9), VER(9)),
-		
+
 		MKEND()
 	};
 
@@ -789,7 +789,7 @@
 	}
 	s->saveLoadArrayOf(_actors, _numActors, sizeof(_actors[0]), actorEntries);
 
-	
+
 	//
 	// Save/load sound data
 	//
@@ -920,7 +920,7 @@
 		s->saveLoadArrayOf(_palManipPalette, 0x300, 1, sleByte);
 		s->saveLoadArrayOf(_palManipIntermediatePal, 0x600, 1, sleByte);
 	}
-	
+
 	// darkenPalette was not saved before V53
 	if (s->isLoading() && savegameVersion < VER(53)) {
 		memcpy(_darkenPalette, _currentPalette, 768);

Index: saveload.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/saveload.h,v
retrieving revision 1.62
retrieving revision 1.63
diff -u -d -r1.62 -r1.63
--- saveload.h	26 May 2005 10:07:37 -0000	1.62
+++ saveload.h	30 Jul 2005 21:11:27 -0000	1.63
@@ -34,7 +34,7 @@
 
 /**
  * The current savegame format version.
- * Our save/load system uses an elaborate scheme to allow us to modify the 
+ * Our save/load system uses an elaborate scheme to allow us to modify the
  * savegame while keeping full backward compatibility, in the sense that newer
  * ScummVM versions always are able to load old savegames.
  * In order to achieve that, we store a version in the savegame files, and whenever
@@ -57,7 +57,7 @@
 
 /**
  * The OFFS macro essentially provides the functionality of offsetof(), that
- * is, it determines the offset of a struct/class member within instances of 
+ * is, it determines the offset of a struct/class member within instances of
  * that class.
  *
  * This is a place where we cheat a bit and sacrifice some potential portability
@@ -68,7 +68,7 @@
  * versions have a heuristic built in to detect "offset-of" patterns - which is exactly
  * what our OFFS macro does. Now, for non-POD types this is not really legal, because
  * member need not be at a fixed offset relative to the variable, even if they are in
- * current reality (many of our complex structs are non-POD; for an explanation of 
+ * current reality (many of our complex structs are non-POD; for an explanation of
  * what POD means refer to http://www-cpd.fnal.gov/personal/wb/boost/ISOcxx/doc/POD.html)
  */
 #define OFFS(type,item) (((long)(&((type*)42)->type::item))-42)
@@ -155,7 +155,7 @@
 
 	void saveBytes(void *b, int len);
 	void loadBytes(void *b, int len);
-	
+
 protected:
 	Common::InSaveFile *_loadStream;
 	Common::OutSaveFile *_saveStream;

Index: script.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script.cpp,v
retrieving revision 1.226
retrieving revision 1.227
diff -u -d -r1.226 -r1.227
--- script.cpp	7 Jul 2005 09:52:04 -0000	1.226
+++ script.cpp	30 Jul 2005 21:11:27 -0000	1.227
@@ -52,7 +52,7 @@
 		scriptOffs = _resourceHeaderSize;
 		scriptType = WIO_GLOBAL;
 
-		debugC(DEBUG_SCRIPTS, "runScript(Global-%d) from %d-%d", script, 
+		debugC(DEBUG_SCRIPTS, "runScript(Global-%d) from %d-%d", script,
 				       vm.slot[_currentScript].number, _roomResource);
 	} else {
 		scriptOffs = _localScriptOffsets[script - _numGlobalScripts];
@@ -60,7 +60,7 @@
 			error("Local script %d is not in room %d", script, _roomResource);
 		scriptType = WIO_LOCAL;
 
-		debugC(DEBUG_SCRIPTS, "runScript(%d) from %d-%d", script, 
+		debugC(DEBUG_SCRIPTS, "runScript(%d) from %d-%d", script,
 				       vm.slot[_currentScript].number, _roomResource);
 	}
 
@@ -104,7 +104,7 @@
 	}
 
 	obcd = getOBCDOffs(object);
-	
+
 	// Find a free object slot, unless one was specified
 	if (slot == -1)
 		slot = getScriptSlot();
@@ -189,7 +189,7 @@
 				break;
 			verbptr += 2;
 		} while (1);
-	
+
 		return *(verbptr + 1);
 	} else {
 		do {
@@ -199,7 +199,7 @@
 				break;
 			verbptr += 3;
 		} while (1);
-	
+
 		if (_features & GF_SMALL_HEADER)
 			return READ_LE_UINT16(verbptr + 1);
 		else
@@ -322,7 +322,7 @@
 	}
 
 	vm.numNestedScripts++;
-	
+
 	if (vm.numNestedScripts > ARRAYSIZE(vm.nest))
 		error("Too many nested scripts");
 
@@ -420,7 +420,7 @@
 	default:
 		error("Bad type while getting base address");
 	}
-	
+
 	// The following fixes bug #1202487. Confirmed against disasm.
 	if (_version <= 2 && _scriptOrgPointer == NULL) {
 		ss->status = ssDead;
@@ -439,11 +439,11 @@
 void ScummEngine::executeScript() {
 	int c;
 	while (_currentScript != 0xFF) {
-		
+
 		if (_showStack == 1) {
 			printf("Stack:");
 			for (c=0; c < _scummStackPos; c++) {
-				printf(" %d", _vmStack[c]); 
+				printf(" %d", _vmStack[c]);
 			}
 			printf("\n");
 		}
@@ -513,11 +513,11 @@
 
 		if (VAR_SUBTITLES != 0xFF && var == VAR_SUBTITLES) {
 			return ConfMan.getBool("subtitles");
-		} 
+		}
 		if (VAR_NOSUBTITLES != 0xFF && var == VAR_NOSUBTITLES) {
-			return !ConfMan.getBool("subtitles");	
+			return !ConfMan.getBool("subtitles");
 		}
-		
+
 		checkRange(_numVariables - 1, 0, var, "Variable %d out of range(r)");
 		return _scummVars[var];
 	}
@@ -528,7 +528,7 @@
 			checkRange(_numRoomVariables - 1, 0, var, "Room variable %d out of range(w)");
 			return _roomVars[var];
 
-		} else if ((_gameId == GID_ZAK256) || (_features & GF_OLD_BUNDLE) || 
+		} else if ((_gameId == GID_ZAK256) || (_features & GF_OLD_BUNDLE) ||
 			(_gameId == GID_LOOM && (_platform == Common::kPlatformFMTowns))) {
 			int bit = var & 0xF;
 			var = (var >> 4) & 0xFF;
@@ -629,7 +629,7 @@
 		} else {
 			var &= 0x7FFF;
 			checkRange(_numBitVariables - 1, 0, var, "Bit variable %d out of range(w)");
-	
+
 			if (value)
 				_bitVars[var >> 3] |= (1 << (var & 7));
 			else
@@ -767,7 +767,7 @@
 		}
 		return;
 	}
-	
+
 	for (i = 0; i < NUM_SCRIPT_SLOT; i++) {
 		if (vm.slot[i].status & 0x80) {
 			if (!--vm.slot[i].freezeCount) {
@@ -933,7 +933,7 @@
 
 		if (_sentenceNum) {
 			st = &_sentence[_sentenceNum - 1];
-			
+
 			// Check if this doSentence request is identical to the previous one;
 			// if yes, ignore this invocation.
 			if (_sentenceNum && st->verb == verb && st->objectA == objectA && st->objectB == objectB)
@@ -1196,7 +1196,7 @@
 	// why we record the current script position in vm.cutScenePtr).
 	fetchScriptByte();
 	fetchScriptWord();
-	
+
 	// This is based on disassembly
 	VAR(VAR_OVERRIDE) = 0;
 }
@@ -1207,7 +1207,7 @@
 
 	vm.cutScenePtr[idx] = 0;
 	vm.cutSceneScript[idx] = 0;
-	
+
 	if (_version > 3)
 		VAR(VAR_OVERRIDE) = 0;
 }

Index: script_c64.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_c64.cpp,v
retrieving revision 2.10
retrieving revision 2.11
diff -u -d -r2.10 -r2.11
--- script_c64.cpp	24 Jun 2005 15:23:14 -0000	2.10
+++ script_c64.cpp	30 Jul 2005 21:11:27 -0000	2.11
@@ -557,10 +557,10 @@
 	// 1 Flashlight
 	// 2 Lighted area
 	if (a == 2)
-		VAR(VAR_CURRENT_LIGHTS) = 11; 
+		VAR(VAR_CURRENT_LIGHTS) = 11;
 	else if (a == 1)
 		VAR(VAR_CURRENT_LIGHTS) = 4;
-	else 
+	else
 		VAR(VAR_CURRENT_LIGHTS) = 0;
 
 	_fullRedraw = 1;

Index: script_v100he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v100he.cpp,v
retrieving revision 2.169
retrieving revision 2.170
diff -u -d -r2.169 -r2.170
--- script_v100he.cpp	24 Jun 2005 17:08:20 -0000	2.169
+++ script_v100he.cpp	30 Jul 2005 21:11:28 -0000	2.170
@@ -413,7 +413,7 @@
 		a->_needRedraw = true;
 		a->_needBgReset = true;
 		break;
-	case 9:		
+	case 9:
 		a->drawActorToBackBuf(a->_pos.x, a->_pos.y);
 		break;
 	case 14:
@@ -742,7 +742,7 @@
 	case 42:		// SO_INT_ARRAY
 		data = kIntArray;
 		break;
-	case 43:		
+	case 43:
 		data = kDwordArray;
 		break;
 	case 44:		// SO_NIBBLE_ARRAY
@@ -1621,7 +1621,7 @@
 }
 
 void ScummEngine_v100he::o100_startSound() {
-	byte filename[260];	
+	byte filename[260];
 	int var, value;
 
 	byte subOp = fetchScriptByte();
@@ -1699,7 +1699,7 @@
 	case 0:
 		_curMaxSpriteId = pop();
 		_curSpriteId = pop();
-		
+
 		if (_curSpriteId > _curMaxSpriteId)
 			SWAP(_curSpriteId, _curMaxSpriteId);
 		break;
@@ -1767,7 +1767,7 @@
 				int code = *p;
 				if (code == 0) {
 					for (int i = _curSpriteId; i <= _curMaxSpriteId; ++i) {
-						_sprite->setSpriteResetClass(i);					
+						_sprite->setSpriteResetClass(i);
 					}
 				} else if (code & 0x80) {
 					for (int i = _curSpriteId; i <= _curMaxSpriteId; ++i) {
@@ -2410,7 +2410,7 @@
 
 	byte subOp = fetchScriptByte();
 	subOp -= 20;
-	
+
 	switch (subOp) {
 	case 0:
 		y = pop();
@@ -2418,7 +2418,7 @@
 		state = pop();
 		resId = pop();
 		push(_wiz->getWizPixelColor(resId, state, x, y, 0));
-		break;		
+		break;
 	case 6:
 		resId = pop();
 		push(_wiz->getWizImageStates(resId));
@@ -2442,7 +2442,7 @@
 		pop();
 		push(0);
 		warning("o100_getWizData() case 34 unhandled");
-		break;		
+		break;
 	case 64:
 		state = pop();
 		resId = pop();
@@ -2454,7 +2454,7 @@
 		resId = pop();
 		_wiz->loadImgSpot(resId, state, x, y);
 		push(x);
-		break;	
+		break;
 	case 66:
 		state = pop();
 		resId = pop();
@@ -2479,8 +2479,8 @@
 			_wiz->getWizImageDim(resId, state, w, h);
 			x = 0;
 			y = 0;
-		}		
-		push(computeWizHistogram(resId, state, x, y, w, h));		
+		}
+		push(computeWizHistogram(resId, state, x, y, w, h));
 		break;
 	default:
 		error("o100_getWizData: Unknown case %d", subOp);
@@ -2870,7 +2870,7 @@
 		colors = pop();
 		if (colors == 1) {
 			_string[m].color = pop();
-		} else {	
+		} else {
 			push(colors);
 			getStackList(args, ARRAYSIZE(args));
 			for (i = 0; i < 16; i++)

Index: script_v2.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v2.cpp,v
retrieving revision 2.279
retrieving revision 2.280
diff -u -d -r2.279 -r2.280
--- script_v2.cpp	24 Jun 2005 15:23:14 -0000	2.279
+++ script_v2.cpp	30 Jul 2005 21:11:28 -0000	2.280
@@ -407,7 +407,7 @@
 
 		if (insertSpace)
 			*ptr++ = ' ';
-		
+
 	}
 	*ptr = 0;
 
@@ -525,7 +525,7 @@
 void ScummEngine_v2::o2_setObjPreposition() {
 	int obj = getVarOrDirectWord(PARAM_1);
 	int unk = fetchScriptByte();
-	
+
 	if (_platform == Common::kPlatformNES)
 		return;
 
@@ -663,7 +663,7 @@
 }
 
 void ScummEngine_v2::o2_waitForMessage() {
-	
+
 	if (VAR(VAR_HAVE_MSG)) {
 		_scriptPointer--;
 		o5_breakHere();
@@ -800,7 +800,7 @@
 void ScummEngine_v2::o2_verbOps() {
 	int verb = fetchScriptByte();
 	int slot, state;
-	
+
 	switch (verb) {
 	case 0:		// SO_DELETE_VERBS
 		slot = getVarOrDirectByte(PARAM_1) + 1;
@@ -809,14 +809,14 @@
 		//printf("o2_verbOps delete slot = %d\n", slot);
 		killVerb(slot);
 		break;
-	
+
 	case 0xFF:	// Verb On/Off
 		verb = fetchScriptByte();
 		state = fetchScriptByte();
 		slot = getVerbSlot(verb, 0);
 
 		//printf("o2_verbOps Verb On/Off: verb = %d, slot = %d, state = %d\n", verb, slot, state);
-		
+
 		_verbs[slot].curmode = state;
 
 		break;
@@ -861,7 +861,7 @@
 		vs->center = 0;
 		vs->imgindex = 0;
 		vs->prep = prep;
-		
+
 		vs->curRect.left = x;
 		vs->curRect.top = y;
 
@@ -919,7 +919,7 @@
 	case 1:
 		// Execute the sentence
 		_sentenceNum--;
-		
+
 		if (st->verb == 254) {
 			ScummEngine::stopObjectScript(st->objectA);
 		} else {
@@ -927,7 +927,7 @@
 			bool isSpecialVerb;
 			if (st->verb != 253 && st->verb != 250) {
 				VAR(VAR_ACTIVE_VERB) = st->verb;
-				VAR(VAR_ACTIVE_OBJECT1) = st->objectA;	
+				VAR(VAR_ACTIVE_OBJECT1) = st->objectA;
 				VAR(VAR_ACTIVE_OBJECT2) = st->objectB;
 
 				isBackgroundScript = false;
@@ -997,7 +997,7 @@
 			strcat(sentence, " ");
 			strcat(sentence, (const char*)temp);
 		}
-	
+
 		// For V1 games, the engine must compute the preposition.
 		// In all other Scumm versions, this is done by the sentence script.
 		if ((_gameId == GID_MANIAC && _version == 1 && !(_platform == Common::kPlatformNES)) && (VAR(VAR_SENTENCE_PREPOSITION) == 0)) {
@@ -1050,7 +1050,7 @@
 		_string[2].color = 0;
 	} else if (_version == 1)
 		_string[2].color = 16;
-	else 
+	else
 		_string[2].color = 13;
 
 	char *ptr = sentence;
@@ -1307,10 +1307,10 @@
 			// 1 Flashlight
 			// 2 Lighted area
 			if (a == 2)
-				VAR(VAR_CURRENT_LIGHTS) = 11; 
+				VAR(VAR_CURRENT_LIGHTS) = 11;
 			else if (a == 1)
 				VAR(VAR_CURRENT_LIGHTS) = 4;
-			else 
+			else
 				VAR(VAR_CURRENT_LIGHTS) = 0;
 		} else
 			VAR(VAR_CURRENT_LIGHTS) = a;
@@ -1450,12 +1450,12 @@
 	VAR(VAR_OVERRIDE) = 0;
 	vm.cutSceneScript[0] = 0;
 	vm.cutScenePtr[0] = 0;
-	
+
 	VAR(VAR_CURSORSTATE) = vm.cutSceneData[1];
 
 	// Reset user state to values before cutscene
 	setUserState(vm.cutSceneData[0] | 7);
-	
+
 	if ((_gameId == GID_MANIAC) && !(_platform == Common::kPlatformNES)) {
 		camera._mode = (byte) vm.cutSceneData[3];
 		if (camera._mode == kFollowActorCameraMode) {

Index: script_v5.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v5.cpp,v
retrieving revision 1.290
retrieving revision 1.291
diff -u -d -r1.290 -r1.291
--- script_v5.cpp	7 Jul 2005 06:45:33 -0000	1.290
+++ script_v5.cpp	30 Jul 2005 21:11:28 -0000	1.291
@@ -607,7 +607,7 @@
 	if (_gameId == GID_INDY4 && vm.slot[_currentScript].number == 206 && _currentRoom == 17 && (act == 31 || act == 86)) {
 		return;
 	}
-	
+
 	Actor *a = derefActor(act, "o5_animateActor");
 	a->animateActor(anim);
 }
@@ -860,14 +860,14 @@
 void ScummEngine_v5::o5_getStringWidth() {
 	int string, width = 0;
 	byte *ptr;
-	
+
 	getResultPos();
 	string = getVarOrDirectByte(PARAM_1);
 	ptr = getResourceAddress(rtString, string);
 	assert(ptr);
 
 	width = _charset->getStringWidth(0, ptr);
-	
+
 	setResult(width);
 	warning("o5_getStringWidth, result %d", width);
 }
@@ -1056,14 +1056,14 @@
 		setResult(0);
 		return;
 	}
-	
+
 	Actor *a = derefActor(act, "o5_getActorRoom");
 	setResult(a->_room);
 }
 
 void ScummEngine_v5::o5_getActorScale() {
 	Actor *a;
-	
+
 	// INDY3 uses this opcode for waitForActor
 	if (_gameId == GID_INDY3) {
 		const byte *oldaddr = _scriptPointer - 1;
@@ -1130,7 +1130,7 @@
 	byte a = getVarOrDirectByte(PARAM_1);
 	byte slot = (a & 0x1F) + 1;
 	byte result = 0;
-		
+
 	if ((_gameId == GID_MANIAC) && (_version == 1)) {
 		// Convert older load/save screen
 		// 1 Load
@@ -1187,13 +1187,13 @@
 
 	setResult(result);
 }
-		
+
 void ScummEngine_v5::o5_getAnimCounter() {
 	if (_version == 3) {
 		o5_saveLoadGame();
 		return;
 	}
-		
+
 	getResultPos();
 
 	int act = getVarOrDirectByte(PARAM_1);
@@ -1477,7 +1477,7 @@
 	int room;
 
 	room = getVarOrDirectByte(PARAM_1);
-	
+
 	if (!_copyProtection) {
 		// Skip copy protection scheme
 		if (_gameId == GID_INDY3 && (_features & GF_OLD_BUNDLE) && room == 92) {
@@ -1672,7 +1672,7 @@
 	int room = getVarOrDirectByte(PARAM_2);
 
 	a = derefActor(act, "o5_putActorInRoom");
-	
+
 	if (a->_visible && _currentRoom != room && getTalkingActor() == a->_number) {
 		stopTalk();
 	}
@@ -1807,14 +1807,14 @@
 		warning("o5_resourceRoutines %d not yet handled (script %d)", op,  vm.slot[_currentScript].number);
 		break;
 	case 36:
-		// TODO: Sets the loudness of a sound resource. Used in Indy3 and Zak. 
+		// TODO: Sets the loudness of a sound resource. Used in Indy3 and Zak.
 		foo = getVarOrDirectByte(PARAM_2);
 		bar = fetchScriptByte();
 		warning("o5_resourceRoutines %d not yet handled (script %d)", op,  vm.slot[_currentScript].number);
 		break;
 	case 37:
 		// TODO: Sets the pitch of a sound resource (pitch = foo - center semitones.
-		// "center" is at 0x32 in the sfx resource (always 0x3C in zak256, but sometimes different in Indy3). 
+		// "center" is at 0x32 in the sfx resource (always 0x3C in zak256, but sometimes different in Indy3).
 		foo = getVarOrDirectByte(PARAM_2);
 		warning("o5_resourceRoutines %d not yet handled (script %d)", op,  vm.slot[_currentScript].number);
 		break;
@@ -2158,8 +2158,8 @@
 			break;
 		default:
 			// TODO: return track length in seconds. We'll have to extend Sound and OSystem for this.
-			// To check scummvm returns the right track length you 
-			// can look at the global script #9 (0x888A in 49.LFL). 
+			// To check scummvm returns the right track length you
+			// can look at the global script #9 (0x888A in 49.LFL).
 			break;
 		}
 		debugC(DEBUG_GENERAL,"o5_startMusic(%d)", b);
@@ -2570,7 +2570,7 @@
 		warning("Bypassing Indy4 bug");
 		return;
 	}
-	
+
 	if (_gameId == GID_LOOM256 && nr == 1 && nr2 == 0 &&
 		dist == 255 && vm.slot[_currentScript].number == 98) {
 		// WORKAROUND bug #743615: LoomCD script 98 contains this:
@@ -2719,7 +2719,7 @@
 						// Slightly increase the delay (5 frames = 1/25 of a second).
 						// This noticably improves the experience in Loom CD.
 						delay = (int)(delay * 7.5 + 5);
-						
+
 						_sound->playCDTrack(1, 0, offset, delay);
 					}
 				} else {
@@ -2779,7 +2779,7 @@
 			// some stubs here, but somebody with a full IDA or more knowledge
 			// about this will have to fill in the gaps. At least now we know
 			// that something is missing here :-)
-		
+
 			if (a == 4) {
 				printf("o5_oldRoomEffect ODDBALL: _opcode = 0x%x, a = 0x%x\n", _opcode, a);
 				// No idea what byte_2FCCF is, but it's a globale boolean flag.
@@ -2788,38 +2788,38 @@
 				// how it is used? It might also correspond to _screenEffectFlag.
 				int byte_2FCCF = 0;
 
-				// For now, we force a redraw of the screen background. This 
+				// For now, we force a redraw of the screen background. This
 				// Makes the Zak end credits work more or less correctly.
 				VirtScreen *vs = &virtscr[0];
 				restoreBG(Common::Rect(0,vs->topline, vs->w, vs->topline + vs->h));
 				vs->setDirtyRange(0, vs->h);
 				updateDirtyScreen(kMainVirtScreen);
-				
+
 				if (byte_2FCCF) {
 					// Here now "sub_1C44" is called, which sets byte_2FCCF to 0 then
 					// calls yet another sub (which also reads byte_2FCCF):
 
 					byte_2FCCF = 0;
 					//call sub_0BB3
-					
-					
-					// Now sub_085C is called. This is quite simply: it sets 
+
+
+					// Now sub_085C is called. This is quite simply: it sets
 					// 0xF000 bytes. starting at 0x40000 to 0. No idea what that
 					// buffer is, maybe a screen buffer, though. Note that
 					// 0xF000 = 320*192.
 					// Maybe this is also the charset mask being cleaned?
-					
+
 					// call sub_085C
 
-					
+
 					// And then sub_1C54 is called, which is almost identical to
 					// the above sub_1C44, only it sets byte_2FCCF to 1:
-					
+
 					byte_2FCCF = 1;
 					// call sub_0BB3
 
 				} else {
-					// Here only sub_085C is called (see comment above) 
+					// Here only sub_085C is called (see comment above)
 
 					// call sub_085C
 				}

Index: script_v6.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v6.cpp,v
retrieving revision 1.446
retrieving revision 1.447
diff -u -d -r1.446 -r1.447
--- script_v6.cpp	24 Jun 2005 16:14:38 -0000	1.446
+++ script_v6.cpp	30 Jul 2005 21:11:28 -0000	1.447
@@ -399,10 +399,10 @@
 	int id;
 	int size;
 	ArrayHeader *ah;
-	
+
 	assert(0 <= type && type <= 5);
 
-	
+
 	if (_heversion >= 61) {
 		if (type == kBitArray || type == kNibbleArray)
 			type = kByteArray;
@@ -424,7 +424,7 @@
 	if (_version == 8) {
 		if (array & 0x40000000) {
 		}
-	
+
 		if (array & 0x80000000) {
 			error("Can't define bit variable as array pointer");
 		}
@@ -433,7 +433,7 @@
 	} else {
 		if (array & 0x4000) {
 		}
-	
+
 		if (array & 0x8000) {
 			error("Can't define bit variable as array pointer");
 		}
@@ -486,7 +486,7 @@
 	ArrayHeader *ah = (ArrayHeader *)getResourceAddress(rtString, readVar(array));
 	if (!ah)
 		return 0;
-	
+
 	// Workaround for a long standing bug where we save array headers in native
 	// endianness, instead of a fixed endianness. We try to detect savegames
 	// which were created on a big endian system and convert them to little
@@ -496,7 +496,7 @@
 		SWAP16(ah->dim2);
 		SWAP16(ah->type);
 	}
-	
+
 	return ah;
 }
 
@@ -505,7 +505,7 @@
 
 	if (ah == NULL || ah->data == NULL)
 		error("readArray: invalid array %d (%d)", array, readVar(array));
-	
+
 	// WORKAROUND bug #645711. This is clearly a script bug, as this script
 	// excerpt shows nicely:
 	// ...
@@ -814,10 +814,10 @@
 	getStackList(args, ARRAYSIZE(args));
 	script = pop();
 	flags = pop();
-	
+
 	// WORKAROUND bug #556558: At Dino Bungee National Memorial, the buttons for
-	// the Wally and Rex dinosaurs will always restart their speech, instead of 
-	// stopping and starting their speech. This was a script bug in the original 
+	// the Wally and Rex dinosaurs will always restart their speech, instead of
+	// stopping and starting their speech. This was a script bug in the original
 	// game.
 	if (_gameId == GID_SAMNMAX && _roomResource == 59 &&
 		vm.slot[_currentScript].number == 201 && script == 48) {
@@ -841,7 +841,7 @@
 
 		return;
 	}
-	
+
 	runScript(script, (flags & 1) != 0, (flags & 2) != 0, args);
 }
 
@@ -1090,7 +1090,7 @@
 #ifndef DISABLE_SCUMM_7_8
 	if (_features & GF_DIGI_IMUSE)
 		_imuseDigital->startSfx(pop(), 64);
-	else 
+	else
 #endif
 		_sound->addSoundToQueue(pop(), offset);
 }
@@ -2117,7 +2117,7 @@
 	if (_version == 8) {
 		subOp = (subOp - 141) + 0xB4;
 	}
-	
+
 	switch (subOp) {
 	case 141:		// SO_SAVE_VERBS
 		while (a <= b) {
@@ -2298,7 +2298,7 @@
 		// FIXME - are we really measuring minutes here?
 		delay = delay * 60;
 	else
-		// FIXME - Is this the same in ComI? Seem to need a 1.5 minute 
+		// FIXME - Is this the same in ComI? Seem to need a 1.5 minute
 		// multiplier for correct timing - see patch 664893
 		delay = delay * 90;
 
@@ -2495,7 +2495,7 @@
 			break;
 #ifndef DISABLE_SCUMM_7_8
 		case 6: {
-				if (_smushFrameRate == 0) 
+				if (_smushFrameRate == 0)
 					_smushFrameRate = 14;
 
 				// SMUSH movie playback
@@ -2514,7 +2514,7 @@
 						sp->play((char *)getStringAddressVar(VAR_VIDEONAME));
 					delete sp;
 				} else if (_gameId == GID_FT) {
-					const int insaneVarNum = ((_features & GF_DEMO) && (_platform == Common::kPlatformPC)) 
+					const int insaneVarNum = ((_features & GF_DEMO) && (_platform == Common::kPlatformPC))
 						? 232 : 233;
 
 					_insaneRunning = true;
@@ -2825,7 +2825,7 @@
 				_keyDownMap[0x36]) ? 1 : 0;
 		break;
 	case 0x14E: // Gray+
-		return (_keyDownMap[0x10e] || 
+		return (_keyDownMap[0x10e] ||
 				(_keyDownMap[0x13d] && _keyDownMap[0x12f])) ? 1 : 0;
 		break;
 	case 0x14F: // End
@@ -2927,7 +2927,7 @@
 		a->drawActorCostume();
 		return;
 	}
-	
+
 	if (state == 0)
 		state = 1;
 
@@ -2957,12 +2957,12 @@
 	writeVar(0, 0);
 	defineArray(0, kIntArray, 0, _numLocalObjects + 1);
 	writeArray(0, 0, 0, _numLocalObjects);
-	
+
 	while (i < _numLocalObjects) {
 		writeArray(0, 0, i, _objs[i].obj_nr);
 		i++;
 	}
-	
+
 	push(readVar(0));
 }
 
@@ -2975,7 +2975,7 @@
 		// Determine two random elements...
 		int rand1 = _rnd.getRandomNumber(range) + minIdx;
 		int rand2 = _rnd.getRandomNumber(range) + minIdx;
-		
+
 		// ...and swap them
 		int val1 = readArray(num, 0, rand1);
 		int val2 = readArray(num, 0, rand2);
@@ -3035,7 +3035,7 @@
 void ScummEngine_v6::o6_getDateTime() {
 	struct tm *t;
 	time_t now = time(NULL);
-	
+
 	t = localtime(&now);
 
 	VAR(VAR_TIMEDATE_YEAR) = t->tm_year;
@@ -3043,7 +3043,7 @@
 	VAR(VAR_TIMEDATE_DAY) = t->tm_mday;
 	VAR(VAR_TIMEDATE_HOUR) = t->tm_hour;
 	VAR(VAR_TIMEDATE_MINUTE) = t->tm_min;
-	
+
 	if (_version == 8)
 		VAR(VAR_TIMEDATE_SECOND) = t->tm_sec;
 }

Index: script_v6he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v6he.cpp,v
retrieving revision 2.163
retrieving revision 2.164
diff -u -d -r2.163 -r2.164
--- script_v6he.cpp	24 Jun 2005 17:08:20 -0000	2.163
+++ script_v6he.cpp	30 Jul 2005 21:11:28 -0000	2.164
@@ -555,7 +555,7 @@
 
 void ScummEngine_v60he::swapObjects(int object1, int object2) {
 	int idx1 = -1, idx2 = -1;
-	
+
 	for (int i = 0; i < _numObjectsInRoom; i++) {
 		if (_objs[i].obj_nr == object1)
 			idx1 = i;
@@ -563,7 +563,7 @@
 		if (_objs[i].obj_nr == object2)
 			idx2 = i;
 	}
-	
+
 	if (idx1 == -1 || idx2 == -1 || idx1 >= idx2)
 		return;
 
@@ -711,7 +711,7 @@
 	case 217:		// SO_ACTOR_NEW
 		a->initActor(2);
 		break;
-	case 218:		
+	case 218:
 		a->drawActorToBackBuf(a->_pos.x, a->_pos.y);
 		break;
 	case 219:
@@ -881,7 +881,7 @@
 
 	for (int j = y1; j <= y2; ++j) {
 		uint8 *p = vs.getBackPixels(x1, j - vs.topline);
-		
+
 		int size = virtScreenSavePack(dst, p, x2 - x1 + 1, 0);
 		if (dst != 0) {
 			dst += size;
@@ -901,10 +901,10 @@
 	int flag = 0;
 	int iend = 1;
 	int ibeg = 0;
-	
+
 	for (--len; len != 0; --len, prevByte = curByte) {
 		bool pass = false;
-		
+
 		assert(iend < 0x100);
 		ctx.buf[iend] = curByte = *src++;
 		++iend;
@@ -975,7 +975,7 @@
 	if (dst) {
 		*dst++ = b;
 	}
-	++ctx->size;	
+	++ctx->size;
 }
 
 void ScummEngine_v60he::o60_openFile() {
@@ -986,12 +986,12 @@
 
 	len = resStrLen(_scriptPointer);
 	_scriptPointer += len + 1;
-	
+
 	for (r = strlen((char*)filename); r != 0; r--) {
 		if (filename[r - 1] == '\\')
 			break;
 	}
-	
+
 	mode = pop();
 	slot = -1;
 	for (l = 0; l < 17; l++) {
@@ -1290,7 +1290,7 @@
 		colors = pop();
 		if (colors == 1) {
 			_string[m].color = pop();
-		} else {	
+		} else {
 			push(colors);
 			getStackList(args, ARRAYSIZE(args));
 			for (i = 0; i < 16; i++)

Index: script_v72he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v72he.cpp,v
retrieving revision 2.301
retrieving revision 2.302
diff -u -d -r2.301 -r2.302
--- script_v72he.cpp	24 Jun 2005 15:23:16 -0000	2.301
+++ script_v72he.cpp	30 Jul 2005 21:11:29 -0000	2.302
@@ -384,12 +384,12 @@
 	int id;
 	int size;
 	ArrayHeader *ah;
-	
+
 	assert(dim2start >= 0 && dim2start <= dim2end);
 	assert(dim1start >= 0 && dim1start <= dim1end);
 	assert(0 <= type && type <= 6);
 
-	
+
 	if (type == kBitArray || type == kNibbleArray)
 		type = kByteArray;
 
@@ -433,7 +433,7 @@
 	if (ah == NULL || ah->data == NULL)
 		error("readArray: invalid array %d (%d)", array, readVar(array));
 
-	if (idx2 < (int)FROM_LE_32(ah->dim2start) || idx2 > (int)FROM_LE_32(ah->dim2end) || 
+	if (idx2 < (int)FROM_LE_32(ah->dim2start) || idx2 > (int)FROM_LE_32(ah->dim2end) ||
 		idx1 < (int)FROM_LE_32(ah->dim1start) || idx1 > (int)FROM_LE_32(ah->dim1end)) {
 		error("readArray: array %d out of bounds: [%d, %d] exceeds [%d..%d, %d..%d]",
 			  array, idx1, idx2, FROM_LE_32(ah->dim1start), FROM_LE_32(ah->dim1end),
@@ -469,7 +469,7 @@
 	if (!ah)
 		error("writeArray: Invalid array (%d) reference", readVar(array));
 
-	if (idx2 < (int)FROM_LE_32(ah->dim2start) || idx2 > (int)FROM_LE_32(ah->dim2end) || 
+	if (idx2 < (int)FROM_LE_32(ah->dim2start) || idx2 > (int)FROM_LE_32(ah->dim2end) ||
 		idx1 < (int)FROM_LE_32(ah->dim1start) || idx1 > (int)FROM_LE_32(ah->dim1end)) {
 		error("writeArray: array %d out of bounds: [%d, %d] exceeds [%d..%d, %d..%d]",
 			  array, idx1, idx2, FROM_LE_32(ah->dim1start), FROM_LE_32(ah->dim1end),
@@ -555,7 +555,7 @@
 	}
 
 	return r;
-}	
+}
 
 void ScummEngine_v72he::copyScriptString(byte *dst, int dstSize) {
 	byte string[1024];
@@ -709,7 +709,7 @@
 
 		size = getResourceDataSize(offs) / 4;
 		assert((uint32)state <= (uint32)size);
-			
+
 
 		offs += READ_LE_UINT32(offs + state * sizeof(uint32));
 		offs = heFindResourceData(tag, offs - 8);
@@ -859,7 +859,7 @@
 	grab.right = pop() + 1;
 	grab.top = pop();
 	grab.left = pop();
-	_wiz->captureWizImage(pop(), grab, false, true);	
+	_wiz->captureWizImage(pop(), grab, false, true);
 }
 
 void ScummEngine_v72he::o72_getTimer() {
@@ -1291,7 +1291,7 @@
 	case 217:		// SO_ACTOR_NEW
 		a->initActor(2);
 		break;
-	case 218:		
+	case 218:
 		a->drawActorToBackBuf(a->_pos.x, a->_pos.y);
 		break;
 	case 219:
@@ -1680,7 +1680,7 @@
 	case 5:		// SO_INT_ARRAY
 		data = kIntArray;
 		break;
-	case 6:		
+	case 6:
 		data = kDwordArray;
 		break;
 	case 7:		// SO_STRING_ARRAY
@@ -1894,11 +1894,11 @@
 	writeVar(0, 0);
 	defineArray(0, kDwordArray, 0, 0, 0, _numLocalObjects);
 	writeArray(0, 0, 0, _numLocalObjects);
-	
+
 	for (i = 1; i < _numLocalObjects; i++) {
 		writeArray(0, 0, i, _objs[i].obj_nr);
 	}
-	
+
 	push(readVar(0));
 }
 
@@ -2009,7 +2009,7 @@
 	}
 }
 
-void ScummEngine_v72he::redimArray(int arrayId, int newDim2start, int newDim2end, 
+void ScummEngine_v72he::redimArray(int arrayId, int newDim2start, int newDim2end,
 								   int newDim1start, int newDim1end, int type) {
 	int newSize, oldSize;
 
@@ -2055,7 +2055,7 @@
 	}
 }
 
-void ScummEngine_v72he::copyArray(int array1, int a1_dim2start, int a1_dim2end, int a1_dim1start, int a1_dim1end, 
+void ScummEngine_v72he::copyArray(int array1, int a1_dim2start, int a1_dim2end, int a1_dim1start, int a1_dim1end,
 				int array2, int a2_dim2start, int a2_dim2end, int a2_dim1start, int a2_dim1end)
 {
 	debug(5, "ScummEngine_v72he::copyArray(%d, [%d,%d,%d,%d], %d, [%d,%d,%d,%d])", array1, a1_dim2start, a1_dim2end, a1_dim1start, a1_dim1end, array2, a2_dim2start, a2_dim2end, a2_dim1start, a2_dim1end);
@@ -2065,12 +2065,12 @@
 	checkArrayLimits(array1, a1_dim2start, a1_dim2end, a1_dim1start, a1_dim1end);
 	checkArrayLimits(array2, a2_dim2start, a2_dim2end, a2_dim1start, a2_dim1end);
 	int a12_num = a1_dim2end - a1_dim2start + 1;
-	int a11_num = a1_dim1end - a1_dim1start + 1;	
+	int a11_num = a1_dim1end - a1_dim1start + 1;
 	int a22_num = a2_dim2end - a2_dim2start + 1;
 	int a21_num = a2_dim1end - a2_dim1start + 1;
 	if (a22_num != a12_num || a21_num != a11_num) {
 		warning("Operation size mismatch (%d vs %d)(%d vs %d)", a12_num, a22_num, a11_num, a21_num);
-	}	
+	}
 
 	if (array1 != array2) {
 		ArrayHeader *ah1 = (ArrayHeader *)getResourceAddress(rtString, readVar(array1));
@@ -2104,7 +2104,7 @@
 				copyArrayHelper(ah, a2_dim2start, a2_dim1start, a2_dim1end, &src, &srcPitch, &rowSize);
 			} else {
 				copyArrayHelper(ah, a1_dim2end, a1_dim1start, a1_dim1end, &dst, &dstPitch, &rowSize);
-				copyArrayHelper(ah, a2_dim2end, a2_dim1start, a2_dim1end, &src, &srcPitch, &rowSize);				
+				copyArrayHelper(ah, a2_dim2end, a2_dim1start, a2_dim1end, &src, &srcPitch, &rowSize);
 			}
 			for (; a1_dim2start <= a1_dim2end; ++a1_dim2start) {
 				memcpy(dst, src, rowSize);
@@ -2238,7 +2238,7 @@
 		if (!strcmp((char *)option, "DownLoadPath") || !strcmp((char *)option, "GameResourcePath") || !strcmp((char *)option, "SaveGamePath"))
 			return;
 
-		ConfMan.set((char *)option, (char *)string); 
+		ConfMan.set((char *)option, (char *)string);
 		break;
 	default:
 		error("o72_writeINI: default type %d", type);
@@ -2359,7 +2359,7 @@
 		colors = pop();
 		if (colors == 1) {
 			_string[m].color = pop();
-		} else {	
+		} else {
 			push(colors);
 			getStackList(args, ARRAYSIZE(args));
 			for (i = 0; i < 16; i++)

Index: script_v7he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v7he.cpp,v
retrieving revision 2.164
retrieving revision 2.165
diff -u -d -r2.164 -r2.165
--- script_v7he.cpp	24 Jun 2005 16:14:38 -0000	2.164
+++ script_v7he.cpp	30 Jul 2005 21:11:29 -0000	2.165
@@ -387,7 +387,7 @@
 	if (offs) {
 		spacing = ptr[offs] + (signed char)ptr[offs + 2];
 	}
-	
+
 	return spacing;
 }
 
@@ -946,7 +946,7 @@
 	int type, value;
 	byte option[256], string[256];
 	int len;
-	
+
 	type = pop();
 	value = pop();
 
@@ -956,13 +956,13 @@
 
 	switch (type) {
 	case 1: // number
-		ConfMan.set((char *)option, value); 
+		ConfMan.set((char *)option, value);
 		break;
 	case 2: // string
 		convertMessageToString(_scriptPointer, string, sizeof(string));
 		len = resStrLen(_scriptPointer);
 		_scriptPointer += len + 1;
-		ConfMan.set((char *)option, (char *)string); 
+		ConfMan.set((char *)option, (char *)string);
 		break;
 	default:
 		error("o70_writeINI: default type %d", type);

Index: script_v8.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v8.cpp,v
retrieving revision 2.297
retrieving revision 2.298
diff -u -d -r2.297 -r2.298
--- script_v8.cpp	24 Jun 2005 15:23:16 -0000	2.297
+++ script_v8.cpp	30 Jul 2005 21:11:29 -0000	2.298
@@ -362,7 +362,7 @@
 		OPCODE(o6_invalid),
 		OPCODE(o6_invalid),
 	};
-	
+
 	_opcodesV8 = opcodes;
 }
 
@@ -522,7 +522,7 @@
 	while ((num = _fileHandle->readUint32LE()) != 0) {
 		a = _fileHandle->readUint32LE();
 		b = _fileHandle->readUint32LE();
-		
+
 		if (b != 0)
 			defineArray(num, kIntArray, b, a);
 		else
@@ -591,7 +591,7 @@
 void ScummEngine_v8::o8_dimArray() {
 	byte subOp = fetchScriptByte();
 	int array = fetchScriptWord();
-	
+
 	switch (subOp) {
 	case 0x0A:		// SO_ARRAY_SCUMMVAR
 		defineArray(array, kIntArray, 0, pop());
@@ -610,7 +610,7 @@
 void ScummEngine_v8::o8_dim2dimArray() {
 	byte subOp = fetchScriptByte();
 	int array = fetchScriptWord(), a, b;
-	
+
 	switch (subOp) {
 	case 0x0A:		// SO_ARRAY_SCUMMVAR
 		b = pop();
@@ -636,7 +636,7 @@
 	int b, c, d, len;
 	ArrayHeader *ah;
 	int list[128];
-	
+
 	switch (subOp) {
 	case 0x14:		// SO_ASSIGN_STRING
 		b = pop();
@@ -822,7 +822,7 @@
 void ScummEngine_v8::o8_roomOps() {
 	byte subOp = fetchScriptByte();
 	int a, b, c, d, e;
-	
+
 	switch (subOp) {
 	case 0x52:		// SO_ROOM_PALETTE Set room palette
 		d = pop();
@@ -1477,7 +1477,7 @@
 	int width;
 	const byte *msg = _scriptPointer;
 	byte transBuf[512];
-	
+
 	// Skip to the next instruction
 	_scriptPointer += resStrLen(_scriptPointer) + 1;
 

Index: script_v80he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v80he.cpp,v
retrieving revision 2.123
retrieving revision 2.124
diff -u -d -r2.123 -r2.124
--- script_v80he.cpp	24 Jun 2005 16:14:39 -0000	2.123
+++ script_v80he.cpp	30 Jul 2005 21:11:29 -0000	2.124
@@ -517,7 +517,7 @@
 
 	Common::ConfigFile ConfFile;
 	ConfFile.loadFromFile((const char *)filename);
-	ConfFile.setKey((char *)option, (char *)section, (char *)string); 
+	ConfFile.setKey((char *)option, (char *)section, (char *)string);
 	ConfFile.saveToFile((const char *)filename);
 	debug(0,"o80_writeConfigFile: Filename %s Section %s Option %s String %s", filename, section, option, string);
 }
@@ -595,7 +595,7 @@
 	wi.resNum = pop();
 	wi.state = 0;
 	wi.flags = kWIFIsPolygon;
-	_wiz->displayWizImage(&wi);	
+	_wiz->displayWizImage(&wi);
 }
 
 /**
@@ -611,7 +611,7 @@
  * @param id	the id of an actor, wizimage or color (low bit) & flag (high bit)
  */
 void ScummEngine_v80he::drawLine(int x1, int y1, int x, int y, int step, int type, int id) {
-	debug(0,"drawLine: x1 %d y1 %d x %d y %d, step %d type %d id %d", x1, y1, x, y, step, type, id);	
+	debug(0,"drawLine: x1 %d y1 %d x %d y %d, step %d type %d id %d", x1, y1, x, y, step, type, id);
 
 	if (step < 0) {
 		step = -step;
@@ -697,7 +697,7 @@
 		} else {
 			drawPixel(x, y, id);
 		}
-	}		
+	}
 }
 
 void ScummEngine_v80he::drawPixel(int x, int y, int flags) {

Index: script_v90he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v90he.cpp,v
retrieving revision 2.277
retrieving revision 2.278
diff -u -d -r2.277 -r2.278
--- script_v90he.cpp	24 Jun 2005 17:08:20 -0000	2.277
+++ script_v90he.cpp	30 Jul 2005 21:11:29 -0000	2.278
@@ -410,12 +410,12 @@
 
 void ScummEngine_v90he::o90_sin() {
 	double a = pop() * PI / 180.;
-	push((int)(sin(a) * 100000));	
+	push((int)(sin(a) * 100000));
 }
 
 void ScummEngine_v90he::o90_cos() {
 	double a = pop() * PI / 180.;
-	push((int)(cos(a) * 100000));	
+	push((int)(cos(a) * 100000));
 }
 
 void ScummEngine_v90he::o90_sqrt() {
@@ -846,7 +846,7 @@
 			push(d);
 		} else {
 			push((int)sqrt((double)(d + 1)));
-		}		
+		}
 		break;
 	default:
 		error("o90_getDistanceBetweenPoints: Unknown case %d", subOp);
@@ -1234,7 +1234,7 @@
 		if (_features & GF_HE_985 || _heversion >= 99) {
 			_curMaxSpriteId = pop();
 			_curSpriteId = pop();
-			
+
 			if (_curSpriteId > _curMaxSpriteId)
 				SWAP(_curSpriteId, _curMaxSpriteId);
 		} else {
@@ -1373,7 +1373,7 @@
 				int code = *p;
 				if (code == 0) {
 					for (int i = _curSpriteId; i <= _curMaxSpriteId; ++i) {
-						_sprite->setSpriteResetClass(i);					
+						_sprite->setSpriteResetClass(i);
 					}
 				} else if (code & 0x80) {
 					for (int i = _curSpriteId; i <= _curMaxSpriteId; ++i) {
@@ -1740,14 +1740,14 @@
 			_wiz->getWizImageDim(resId, state, w, h);
 			x = 0;
 			y = 0;
-		}		
-		push(computeWizHistogram(resId, state, x, y, w, h));		
+		}
+		push(computeWizHistogram(resId, state, x, y, w, h));
 		break;
 	case 109:
 		pop();
 		pop();
 		push(0);
-		break;		
+		break;
 	case 111:
 		pop();
 		copyScriptString(filename, sizeof(filename));
@@ -1850,7 +1850,7 @@
 	}
 
 	writeArray(0, 0, 0, numObjs);
-	
+
 	push(readVar(0));
 }
 
@@ -1890,7 +1890,7 @@
 		{
 			Common::Rect r1(args1[0], args1[1], args1[2] + 1, args1[3] + 1);
 			Common::Rect r2(args2[0], args2[1], args2[2] + 1, args2[3] + 1);
-			push(r2.intersects(r1) ? 1 : 0);			
+			push(r2.intersects(r1) ? 1 : 0);
 		}
 		break;
 	case 4:
@@ -1934,13 +1934,13 @@
 				break;
 			}
 
-			if (n2 == 3) { 
+			if (n2 == 3) {
 				r2.left += args2[1];
 				r2.right += args2[1];
 				r2.top += args2[2];
 				r2.bottom += args2[2];
 			}
-			if (n1 == 3) { 
+			if (n1 == 3) {
 				r1.left += args1[1];
 				r1.right += args1[1];
 				r1.top += args1[2];
@@ -1959,7 +1959,7 @@
 				break;
 			}
 
-			if (n2 == 3) { 
+			if (n2 == 3) {
 				r2.left += args2[1];
 				r2.right += args2[1];
 				r2.top += args2[2];
@@ -1979,13 +1979,13 @@
 				break;
 			}
 
-			if (n2 == 3) { 
+			if (n2 == 3) {
 				r2.left += args2[1];
 				r2.right += args2[1];
 				r2.top += args2[2];
 				r2.bottom += args2[2];
 			}
-			if (n1 == 3) { 
+			if (n1 == 3) {
 				r1.left += args1[1];
 				r1.right += args1[1];
 				r1.top += args1[2];
@@ -2004,7 +2004,7 @@
 				break;
 			}
 
-			if (n2 == 3) { 
+			if (n2 == 3) {
 				r2.left += args2[1];
 				r2.right += args2[1];
 				r2.top += args2[2];
@@ -2105,14 +2105,14 @@
 	int line1_x2 = pop();
 	int line1_y1 = pop();
 	int line1_x1 = pop();
-	
+
 	int result = 0;
 	int ix = 0;
 	int iy = 0;
-	
+
 	bool isLine1Point = (line1_x1 == line1_x2 && line1_y1 == line1_y2);
 	bool isLine2Point = (line2_x1 == line2_x2 && line2_y1 == line2_y2);
-	
+
 	if (isLine1Point) {
 		if (isLine2Point) {
 			if (line1_x1 == line2_x1 && line1_y1 == line2_y2) {
@@ -2179,7 +2179,7 @@
 						}
 					}
 				}
-			}			
+			}
 		} else {
 			// 2 lines
 			int dy1 = line1_y2 - line1_y1;
@@ -2316,7 +2316,7 @@
 	switch (subOp) {
 	case 129:
 	case 134: // HE100
-		{	
+		{
 			int array = fetchScriptWord();
 			int sortOrder = pop();
 			int dim1end = pop();

Index: scumm.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scumm.cpp,v
retrieving revision 1.555
retrieving revision 1.556
diff -u -d -r1.555 -r1.556
--- scumm.cpp	20 Jul 2005 20:22:37 -0000	1.555
+++ scumm.cpp	30 Jul 2005 21:11:29 -0000	1.556
@@ -271,7 +271,7 @@
 	{"zoodemo", "Putt-Putt Saves the Zoo (Demo)", GID_HEGAME, 6, 72, MDT_NONE,
 	 GF_USE_KEY | GF_NEW_COSTUMES, Common::kPlatformWindows, 0, 0},
 
-	// Humongous Entertainment Scumm Version 8.0 ?  Scummsrc.80 
+	// Humongous Entertainment Scumm Version 8.0 ?  Scummsrc.80
 	{"ff2-demo", "Freddi Fish 2: The Case of the Haunted Schoolhouse (Demo)", GID_FREDDI2, 6, 80, MDT_NONE,
 	GF_USE_KEY | GF_NEW_COSTUMES | GF_MULTIPLE_VERSIONS, Common::kPlatformWindows, 0, 0},
 	{"freddi2", "Freddi Fish 2: The Case of the Haunted Schoolhouse", GID_FREDDI2, 6, 80, MDT_NONE,
@@ -344,7 +344,7 @@
 	{"f4-demo", "Freddi Fish 4: The Case of the Hogfish Rustlers of Briny Gulch (Demo)", GID_HEGAME, 6, 98, MDT_NONE,
 	 GF_USE_KEY | GF_NEW_COSTUMES | GF_HE_985 | GF_MULTIPLE_VERSIONS, Common::kPlatformWindows, 0, 0},
 
-	// Engine moved to c++ 
+	// Engine moved to c++
 	// Humongous Entertainment Scumm Version 9.9 ?  Scummsys.99
 	{"smaller", "Pajama Sam's Lost & Found (Test)", GID_HEGAME, 6, 99, MDT_NONE,
 	 GF_USE_KEY | GF_NEW_COSTUMES | GF_HE_CURSORLESS, Common::kPlatformWindows, 0, 0},
@@ -1277,7 +1277,7 @@
 
 	free(_palManipPalette);
 	free(_palManipIntermediatePal);
-	
+
 	res.freeResources();
 
 	free(_objectStateTable);
@@ -1299,7 +1299,7 @@
 	delete _debugger;
 }
 
-ScummEngine_v4::ScummEngine_v4(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16], int substResFileNameIndex) 
+ScummEngine_v4::ScummEngine_v4(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16], int substResFileNameIndex)
 	: ScummEngine_v5(detector, syst, gs, md5sum, substResFileNameIndex) {
 	_resourceHeaderSize = 6;
 }
@@ -1313,11 +1313,11 @@
 	_resourceHeaderSize = 4;
 }
 
-ScummEngine_v2::ScummEngine_v2(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16], int substResFileNameIndex) 
+ScummEngine_v2::ScummEngine_v2(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16], int substResFileNameIndex)
 	: ScummEngine_v3old(detector, syst, gs, md5sum, substResFileNameIndex) {
 }
 
-ScummEngine_c64::ScummEngine_c64(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16], int substResFileNameIndex) 
+ScummEngine_c64::ScummEngine_c64(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16], int substResFileNameIndex)
 	: ScummEngine_v2(detector, syst, gs, md5sum, substResFileNameIndex) {
 }
 
@@ -1345,7 +1345,7 @@
 #ifndef DISABLE_HE
 ScummEngine_v70he::ScummEngine_v70he(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16], int substResFileNameIndex)
 	: ScummEngine_v60he(detector, syst, gs, md5sum, substResFileNameIndex) {
-	if (_platform == Common::kPlatformMacintosh && (_heversion >= 72 && _heversion <= 73)) 
+	if (_platform == Common::kPlatformMacintosh && (_heversion >= 72 && _heversion <= 73))
 		_resExtractor = new MacResExtractor(this);
 	else
 		_resExtractor = new Win32ResExtractor(this);
@@ -1477,7 +1477,7 @@
 
 	// Create the sound manager
 	_sound = new Sound(this);
-	
+
 	// Setup the music engine
 	setupMusic(_midi);
 
@@ -1498,7 +1498,7 @@
 		_charset = new CharsetRendererV2(this, _language);
 	else if (_version == 3)
 		_charset = new CharsetRendererV3(this);
-#ifndef DISABLE_SCUMM_7_8		
+#ifndef DISABLE_SCUMM_7_8
 	else if (_version == 8)
 		_charset = new CharsetRendererNut(this);
 #endif
@@ -1551,7 +1551,7 @@
 		_numActors = 62;
 	else if (_heversion >= 72)
 		_numActors = 30;
-	else 
+	else
 		_numActors = 13;
 
 	if (_version >= 7)
@@ -1688,13 +1688,13 @@
 
 	if (_version > 3 && _version < 8)
 		loadCharset(1);
-	
+
 	if (_features & GF_OLD_BUNDLE)
 		loadCharset(0);	// FIXME - HACK ?
 
 	setShake(0);
 	setupCursor();
-	
+
 	// Allocate and Initialize actors
 	Actor::initActorClass(this);
 	_actors = new Actor[_numActors];
@@ -1702,7 +1702,7 @@
 	for (i = 0; i < _numActors; i++) {
 		_actors[i]._number = i;
 		_actors[i].initActor(1);
-	
+
 		// this is from IDB
 		if ((_version == 1) || (_gameId == GID_MANIAC && _demoMode))
 			_actors[i].setActorCostume(i);
@@ -1848,7 +1848,7 @@
 	ScummEngine::scummInit();
 
 	// HACK cursor hotspot is wrong
-	// Original games used 
+	// Original games used
 	// setCursorHotspot(8, 7);
 	if (_gameId == GID_FUNPACK)
 		setCursorHotspot(16, 16);
@@ -1916,7 +1916,7 @@
 	// FIXME: MD_TOWNS should not be _midi_native in the first place!! iMuse code needs to be restructured.
 	if ((_gameId == GID_TENTACLE) || (_gameId == GID_SAMNMAX) || (_midiDriver == MD_TOWNS))
 		_enable_gs = false;
-	else 
+	else
 		_enable_gs = ConfMan.getBool("enable_gs");
 
 #ifndef __GP32__ //ph0x FIXME, "quick dirty hack"
@@ -2013,7 +2013,7 @@
 	if (_saveLoadFlag != 2 || !loadState(_saveLoadSlot, _saveTemporaryState)) {
 		int args[16];
 		memset(args, 0, sizeof(args));
-		args[0] = _bootParam;	
+		args[0] = _bootParam;
 
 		_saveLoadFlag = 0;
 #ifndef DISABLE_HE
@@ -2050,7 +2050,7 @@
 			// TODO: Maybe perform an autosave on exit?
 		}
 	}
-	
+
 	return 0;
 }
 
@@ -2217,7 +2217,7 @@
 			// Display "Save successful" message, except for auto saves
 			char buf[256];
 			snprintf(buf, sizeof(buf), "Successfully saved game state in file:\n\n%s", filename);
-	
+
 			GUI::TimedMessageDialog dialog(buf, 1500);
 			runDialog(dialog);
 		}
@@ -2274,7 +2274,7 @@
 	if (_saveLoadFlag && _saveLoadFlag != 1) {
 		goto load_game;
 	}
-	
+
 	if (_currentRoom == 0) {
 		if (_version > 3)
 			CHARSET_1();
@@ -2306,7 +2306,7 @@
 			((ScummEngine_v90he *)this)->_sprite->sortActiveSprites();
 		}
 #endif
-	
+
 		setActorRedrawFlags();
 		resetActorBgs();
 
@@ -2318,7 +2318,7 @@
 		}
 
 		processActors();
-		
+
 		_fullRedraw = false;
 
 		if (_version >= 4 && _heversion <= 61)
@@ -2357,7 +2357,7 @@
 	}
 
 	animateCursor();
-	
+
 	/* show or hide mouse */
 	_system->showMouse(_cursor.state > 0);
 
@@ -2428,7 +2428,7 @@
 	// Re-run bootscript
 	int args[16];
 	memset(args, 0, sizeof(args));
-	args[0] = _bootParam;	
+	args[0] = _bootParam;
 	if (_gameId == GID_MANIAC && _demoMode)
 		runScript(9, 0, 0, args);
 	else
@@ -2460,7 +2460,7 @@
 	// Resume sound & video
 	_sound->pauseSounds(old_soundsPaused);
 	_smushPaused = oldSmushPaused;
-	
+
 	// Return the result
 	return result;
 }
@@ -2577,7 +2577,7 @@
 	StringSet fileSet;
 
 	for (g = scumm_settings; g->name; ++g) {
-		// Determine the 'detectname' for this game, that is, the name of a 
+		// Determine the 'detectname' for this game, that is, the name of a
 		// file that *must* be presented if the directory contains the data
 		// for this game. For example, FOA requires atlantis.000
 		const char *base = g->baseFilename ? g->baseFilename : g->name;
@@ -2622,15 +2622,15 @@
 							if (!tmp.open(file->path().c_str()))
 								break;
 							tmp.read(buf, 6);
-	
+
 							if (buf[0] == 0xCE && buf[1] == 0xF5) {
 								// Looks like V1. However, we currently do not distinguish between V1 and V2
 								// in the scumm_settings list.
 								if (g->version != 1 && g->version != 2)
 									break;
-	
+
 								// Candidates: maniac clasic, zak classic
-								
+
 								// TODO: Maybe we can use the filesize to distinguish these two?
 								// English V1 Zak: 1896 bytes
 								// English V1 MM:  1972 bytes
@@ -2644,35 +2644,35 @@
 								/*
 								TODO: MIght be possible to distinguish those by the script count.
 								Specifically, my versions of these games have this in their headers:
-	
+
 								Loom (en; de; en demo; en MAC):
 								_numGlobalObjects 1000
 								_numRooms 100
 								_numCostumes 200
 								_numScripts 200
 								_numSounds 80
-								
+
 								Indy3EGA (en PC; en Mac; en demo):
 								_numGlobalObjects 1000
 								_numRooms 99
 								_numCostumes 129
 								_numScripts 139
 								_numSounds 84
-								
+
 								MM (en; de):
 								_numGlobalObjects 780
 								_numRooms 61
 								_numCostumes 40
 								_numScripts 179
 								_numSounds 120
-								
+
 								Zak (de; en demo):
 								_numGlobalObjects 780
 								_numRooms 61
 								_numCostumes 40
 								_numScripts 155
 								_numSounds 120
-								
+
 								So, they all have a different number of scripts.
 								*/
 							} else if (buf[4] == '0' && buf[5] == 'R') {
@@ -2685,23 +2685,23 @@
 								and know their MD5s, we could simply rely on this and
 								if we find something which has an unknown MD5, assume
 								that it is an (so far unknown) version of Indy3.
-								
+
 								We can combin this with a look at the resource headers:
-								
+
 								Indy3:
 								_numGlobalObjects 1000
 								_numRooms 99
 								_numCostumes 129
 								_numScripts 139
 								_numSounds 84
-								
+
 								Indy3Towns, ZakTowns, ZakLoom demo:
 								_numGlobalObjects 1000
 								_numRooms 99
 								_numCostumes 199
 								_numScripts 199
 								_numSounds 199
-								
+
 								Assuming that all the town variants look like the latter, we can
 								do the chceck like this:
 								  if (numScripts == 139)
@@ -2746,25 +2746,25 @@
 								break;
 							}
 						}
-					
+
 						// Match found, add to list of candidates, then abort inner loop.
 						if (substLastIndex > 0 && // HE Mac versions.
 							(substResFileNameTable[substLastIndex].genMethod == kGenMac ||
 							 substResFileNameTable[substLastIndex].genMethod == kGenMacNoParens)) {
-							detectedGames.push_back(DetectedGame(g->toGameSettings(), 
-																 Common::UNK_LANG, 
+							detectedGames.push_back(DetectedGame(g->toGameSettings(),
+																 Common::UNK_LANG,
 																 Common::kPlatformMacintosh));
 							fileSet[file->path()] = true;
-						} else if (substLastIndex == 0 && g->id == GID_MANIAC && 
+						} else if (substLastIndex == 0 && g->id == GID_MANIAC &&
 								   (buf[0] == 0xbc || buf[0] == 0xa0)) {
-							detectedGames.push_back(DetectedGame(g->toGameSettings(), 
-																 Common::UNK_LANG, 
+							detectedGames.push_back(DetectedGame(g->toGameSettings(),
+																 Common::UNK_LANG,
 																 Common::kPlatformNES));
-						} else if ((g->id == GID_MANIAC || g->id == GID_ZAK) && 
+						} else if ((g->id == GID_MANIAC || g->id == GID_ZAK) &&
 								   ((buf[0] == 0x31 && buf[1] == 0x0a) ||
 									(buf[0] == 0xcd && buf[1] == 0xfe))) {
-							detectedGames.push_back(DetectedGame(g->toGameSettings(), 
-																 Common::UNK_LANG, 
+							detectedGames.push_back(DetectedGame(g->toGameSettings(),
+																 Common::UNK_LANG,
 																 Common::kPlatformC64));
 						} else {
 							detectedGames.push_back(g->toGameSettings());
@@ -2824,13 +2824,13 @@
 		return -1;
 
 	char num = filename[strlen(filename) - 1];
-	
+
 	// In some cases we have .(a) and .(b) extensions
 	if (num == ')')
 		num = filename[strlen(filename) - 2];
 
 	const char *ext = strrchr(filename, '.');
-	size_t len = (ext > 0) ? ext - filename : strlen(filename);	
+	size_t len = (ext > 0) ? ext - filename : strlen(filename);
 
 	for (int i = index; i < ARRAYSIZE(substResFileNameTable); i++) {
 		if (!scumm_strnicmp(filename, substResFileNameTable[i].winName, len)) {
@@ -2843,7 +2843,7 @@
 				} else {
 					if (substResFileNameTable[i].genMethod == kGenMac)
 						snprintf(buf, bufsize, "%s (%c)", substResFileNameTable[i].macName, num);
-					else 
+					else
 						snprintf(buf, bufsize, "%s %c", substResFileNameTable[i].macName, num);
 				}
 				break;
@@ -2870,7 +2870,7 @@
 Engine *Engine_SCUMM_create(GameDetector *detector, OSystem *syst) {
 	Engine *engine;
 
-	
+
 	const ScummGameSettings *g = scumm_settings;
 	while (g->name) {
 		if (!scumm_stricmp(detector->_game.name, g->name))
@@ -2917,7 +2917,7 @@
 
 		substLastIndex = generateSubstResFileName_(tempName, detectName, sizeof(detectName), substLastIndex + 1);
 	}
-	
+
 	// Unable to locate game data
 	if (!found) {
 		return 0;
@@ -2937,7 +2937,7 @@
 	}
 
 	// Use MD5 to determine specific game version, if required.
-	if (game.features & GF_MULTIPLE_VERSIONS) {	
+	if (game.features & GF_MULTIPLE_VERSIONS) {
 		g = multiple_versions_md5_settings;
 		while (g->name) {
 			if (!scumm_stricmp(gameMD5, g->name))

Index: scumm.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scumm.h,v
retrieving revision 1.638
retrieving revision 1.639
diff -u -d -r1.638 -r1.639
--- scumm.h	30 Jul 2005 05:58:48 -0000	1.638
+++ scumm.h	30 Jul 2005 21:11:29 -0000	1.639
@@ -89,7 +89,7 @@
 
 	/** Games using XOR encrypted data files. */
 	GF_USE_KEY             = 1 << 4,
-	
+
 	/** Small header games (ScummEngine_v4 and subclasses). */
 	GF_SMALL_HEADER        = 1 << 5,
 
@@ -120,7 +120,7 @@
 	/** HE games for which localized versions exist */
 	GF_HE_LOCALIZED        = 1 << 13,
 
-	/** 
+	/**
 	 *  HE Games with more global scripts and different sprite handling
 	 *  i.e. read it as HE version 9.85. Used for HE98 only.
 	 */
@@ -131,7 +131,7 @@
 
 	/** Games with multiple versions */
 	GF_MULTIPLE_VERSIONS   = 1 << 16,
-	
+
 	/** A demo, not a full blown game. */
 	GF_DEMO                = 1 << 17
 };
@@ -296,14 +296,14 @@
 struct AuxBlock {
 	bool visible;
 	Common::Rect r;
-	
+
 	void reset() {
 		visible = false;
 		r.left = r.top = 0;
 		r.right = r.bottom = -1;
 	}
 };
-	
+
 struct AuxEntry {
 	int actorNum;
 	int subIndex;
@@ -334,7 +334,7 @@
 	ResourceManager(ScummEngine *vm);
 
 	byte *createResource(int type, int index, uint32 size);
-	void nukeResource(int type, int i);	
+	void nukeResource(int type, int i);
 
 	void freeResources();
 
@@ -357,7 +357,7 @@
 	friend class Insane;
 	friend class CharsetRenderer;
 	friend class ResourceManager;
-	
+
 	void errorString(const char *buf_input, char *buf_output);
 public:
 	/* Put often used variables at the top.
@@ -385,7 +385,7 @@
 
 	/** Graphics manager */
 	Gdi gdi;
-	
+
 	/** Central resource data. */
 	ResourceManager res;
 
@@ -470,7 +470,7 @@
 	byte _numActors;
 	Actor *_actors;	// Has _numActors elements
 	Actor **_sortedActors;
-	
+
 	byte *_arraySlot;
 	uint16 *_inventory;
 	uint16 *_newNames;
@@ -521,7 +521,7 @@
 	byte _NESPatTable[2][4096];
 	byte _NESPalette[2][16];
 	byte _NESBaseTiles;
-	
+
 	int _NESStartStrip;
 
 protected:
@@ -552,7 +552,7 @@
 
 	/** The bootparam, to be passed to the script 1, the bootscript. */
 	int _bootParam;
-	
+
 	// Various options useful for debugging
 	bool _dumpScripts;
 	bool _hexdumpScripts;
@@ -578,7 +578,7 @@
 public:
 	bool getSavegameName(int slot, char *desc);
 	void listSavegames(bool *marks, int num);
-	
+
 	void requestSave(int slot, const char *name, bool temporary = false);
 	void requestLoad(int slot);
 
@@ -600,7 +600,7 @@
 	int _resultVarNumber, _scummStackPos;
 	int _vmStack[150];
 	int _keyScriptKey, _keyScriptNo;
-	
+
 	virtual void setupOpcodes() = 0;
 	virtual void executeOpcode(byte i) = 0;
 	virtual const char *getOpcodeDesc(byte i) = 0;
@@ -655,7 +655,7 @@
 	int pop();
 	virtual int readVar(uint var);
 	virtual void writeVar(uint var, int value);
-	
+
 	void beginCutscene(int *args);
 	void endCutscene();
 	void abortCutscene();
@@ -672,7 +672,7 @@
 public:
 	/** The name of the (macintosh/rescumm style) container file, if any. */
 	Common::String _containerFile;
-	
+
 	bool openFile(BaseScummFile &file, const char *filename);
 
 protected:
@@ -698,7 +698,7 @@
 	void allocResTypeData(int id, uint32 tag, int num, const char *name, int mode);
 //	byte *createResource(int type, int index, uint32 size);
 	int loadResource(int type, int i);
-//	void nukeResource(int type, int i);	
+//	void nukeResource(int type, int i);
 	int getResourceSize(int type, int idx);
 
 public:
@@ -780,7 +780,7 @@
 	int getObjectImageCount(int object);
 	int whereIsObject(int object) const;
 	int findObject(int x, int y);
-	void findObjectInRoom(FindObjectInRoom *fo, byte findWhat, uint object, uint room);	
+	void findObjectInRoom(FindObjectInRoom *fo, byte findWhat, uint object, uint room);
 public:
 	int getObjectOrActorXY(int object, int &x, int &y);	// Used in actor.cpp, hence public
 protected:
@@ -915,17 +915,17 @@
 	bool _doEffect;
 
 	byte *_scrollBuffer;
-	
+
 	struct {
 		int x, y, w, h;
 		byte *buffer;
 		uint16 xStrips, yStrips;
 		bool isDrawn;
 	} _flashlight;
-	
+
 public:
 	bool isLightOn() const;
-	
+
 protected:
 	void initScreens(int b, int h);
 	void initVirtScreen(VirtScreenNumber slot, int top, int width, int height, bool twobufs, bool scrollable);
@@ -934,15 +934,15 @@
 
 	void decodeNESBaseTiles();
 
-	void drawObject(int obj, int arg);	
+	void drawObject(int obj, int arg);
 	void drawRoomObjects(int arg);
 	void drawRoomObject(int i, int arg);
 	void drawBox(int x, int y, int x2, int y2, int color);
 
 	void restoreBG(Common::Rect rect, byte backcolor = 0);
-	void redrawBGStrip(int start, int num);	
+	void redrawBGStrip(int start, int num);
 	virtual void redrawBGAreas();
-	
+
 	void cameraMoved();
 	void setCameraAtEx(int at);
 	virtual void setCameraAt(int pos_x, int pos_y);
@@ -1006,7 +1006,7 @@
 
 protected:
 	void drawFlashlight();
-	
+
 	void fadeIn(int effect);
 	void fadeOut(int effect);
 
@@ -1027,20 +1027,20 @@
 
 	int _drawObjectQueNr;
 	byte _drawObjectQue[200];
-	
+
 	/* For each of the 410 screen strips, gfxUsageBits contains a
 	 * bitmask. The lower 80 bits each correspond to one actor and
 	 * signify if any part of that actor is currently contained in
 	 * that strip.
-	 * 
+	 *
 	 * If the leftmost bit is set, the strip (background) is dirty
 	 * needs to be redrawn.
-	 * 
+	 *
 	 * The second leftmost bit is set by removeBlastObject() and
 	 * restoreBG(), but I'm not yet sure why.
 	 */
 	uint32 gfxUsageBits[410 * 3];
-	
+
 	void upgradeGfxUsageBits();
 	void setGfxUsageBit(int strip, int bit);
 	void clearGfxUsageBit(int strip, int bit);
@@ -1092,7 +1092,7 @@
 	bool inBoxQuickReject(int box, int x, int y, int threshold);
 	int getClosestPtOnBox(int box, int x, int y, int16& outX, int16& outY);
 	int getSpecialBox(int param1, int param2);
-	
+
 	void setBoxFlags(int box, int val);
 	void setBoxScale(int box, int b);
 

Index: sound.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/sound.cpp,v
retrieving revision 1.469
retrieving revision 1.470
diff -u -d -r1.469 -r1.470
--- sound.cpp	24 Jun 2005 15:23:18 -0000	1.469
+++ sound.cpp	30 Jul 2005 21:11:30 -0000	1.470
@@ -78,7 +78,7 @@
 	_soundsPaused(false),
 	_sfxMode(0),
 	_heMusicTracks(0) {
-	
+
 	memset(_soundQue, 0, sizeof(_soundQue));
 	memset(_soundQue2, 0, sizeof(_soundQue2));
 	memset(_mouthSyncTimes, 0, sizeof(_mouthSyncTimes));
@@ -203,7 +203,7 @@
 			} else {
 				musicFile.seek(+13, SEEK_CUR);
 			}
-		}	
+		}
 
 		musicFile.close();
 	}
@@ -277,7 +277,7 @@
 		// This pointer will be freed at the end of the function
 		mallocedPtr = ptr;
 	} else {
-		debugC(DEBUG_SOUND, "playSound #%d (room %d)", soundID, 
+		debugC(DEBUG_SOUND, "playSound #%d (room %d)", soundID,
 			_vm->getResourceRoomNr(rtSound, soundID));
 
 		ptr = _vm->getResourceAddress(rtSound, soundID);
@@ -337,7 +337,7 @@
 			// Occurs when making fireworks in puttmoon
 			warning("playSound: Invalid sound offset (%d) in sound %d", heOffset, soundID);
 			heOffset = 0;
-		} 
+		}
 		size -= heOffset;
 
 		if (_overrideFreq) {
@@ -372,17 +372,17 @@
 		_vm->_mixer->stopID(_currentMusic);
 		_currentMusic = soundID;
 		_vm->_mixer->playRaw(NULL, sound, size, rate, flags, soundID);
-	}	
+	}
 	// Support for sampled sound effects in Monkey Island 1 and 2
 	else if (READ_UINT32(ptr) == MKID('SBL ')) {
 		debugC(DEBUG_SOUND, "Using SBL sound effect");
-		
+
 		// SBL resources essentially contain VOC sound data.
 		// There are at least two main variants: in one,
 		// there are two subchunks AUhd and AUdt, in the other
 		// the chunks are called WVhd and WVdt. Besides that,
 		// the two variants seem pretty similiar.
-		
+
 		// The first subchunk (AUhd resp. WVhd) seems to always
 		// contain three bytes (00 00 80) of unknown meaning.
 		// After that, a second subchunk contains VOC data.
@@ -428,7 +428,7 @@
 				}
 			}
 		}
-		
+
 		// TODO: It would be nice if we could use readVOCFromMemory() here.
 		// We'd have to add the 'Creative Voice File' header for this, though,
 		// or make readVOCFromMemory() less strict.
@@ -559,7 +559,7 @@
 		_vm->_mixer->playRaw(NULL, sound, size, rate, Audio::Mixer::FLAG_AUTOFREE, soundID, vol, 0);
 	}
 	else {
-		
+
 		if (_vm->_gameId == GID_MONKEY_VGA || _vm->_gameId == GID_MONKEY_EGA
 			|| (_vm->_gameId == GID_MONKEY && _vm->_platform == Common::kPlatformMacintosh)) {
 			// Sound is currently not supported at all in the amiga versions of these games
@@ -581,7 +581,7 @@
 				}
 				return;
 			}
-	
+
 			// Works around the fact that in some places in MonkeyEGA/VGA,
 			// the music is never explicitly stopped.
 			// Rather it seems that starting a new music is supposed to
@@ -591,7 +591,7 @@
 					_vm->_imuse->stopAllSounds();
 			}
 		}
-	
+
 		if (_vm->_musicEngine) {
 			_vm->_musicEngine->startSound(soundID);
 		}
@@ -748,7 +748,7 @@
 
 		if (_offsetTable != NULL) {
 			MP3OffsetTable *result = NULL, key;
-	
+
 			key.org_offset = offset;
 			result = (MP3OffsetTable *)bsearch(&key, _offsetTable, _numSoundEffects,
 													sizeof(MP3OffsetTable), compareMP3OffsetTable);
@@ -774,7 +774,7 @@
 		assert(num + 1 < (int)ARRAYSIZE(_mouthSyncTimes));
 		for (i = 0; i < num; i++)
 			_mouthSyncTimes[i] = _sfxFile->readUint16BE();
-	
+
 		_mouthSyncTimes[i] = 0xFFFF;
 		_sfxMode |= mode;
 		_curSoundPos = 0;
@@ -783,7 +783,7 @@
 
 	if (!_soundsPaused && _vm->_mixer->isReady()) {
 		AudioStream *input = NULL;
-		
+
 		switch (_soundMode) {
 		case kMP3Mode:
 	#ifdef USE_MAD
@@ -806,12 +806,12 @@
 		default:
 			input = makeVOCStream(*_sfxFile);
 		}
-		
+
 		if (!input) {
 			error("startSfxSound failed to load sound");
 			return;
 		}
-	
+
 		if (_vm->_imuseDigital) {
 #ifndef DISABLE_SCUMM_7_8
 			//_vm->_imuseDigital->stopSound(kTalkSoundID);
@@ -1042,7 +1042,7 @@
 		processSound();
 	} else {
 		_soundQue[_soundQuePos++] = num;
-		
+
 		for (i = 0; i < num; i++) {
 			_soundQue[_soundQuePos++] = list[i];
 		}
@@ -1118,7 +1118,7 @@
 		const char *ext;
 		SoundMode mode;
 	};
-	
+
 	static const SoundFileExtensions extensions[] = {
 		{ "sou", kVOCMode },
 	#ifdef USE_FLAC
@@ -1136,15 +1136,15 @@
 	char buf[256];
 	ScummFile *file = new ScummFile();
 	_offsetTable = NULL;
-	
+
 	/* Try opening the file <_gameName>.sou first, e.g. tentacle.sou.
 	 * That way, you can keep .sou files for multiple games in the
 	 * same directory */
-	
+
 	const char *basename[3] = { 0, 0, 0 };
 	basename[0] = _vm->getGameName();
 	basename[1] = "monster";
-	
+
 	for (int j = 0; basename[j] && !file->isOpen(); ++j) {
 		for (int i = 0; extensions[i].ext; ++i) {
 			sprintf(buf, "%s.%s", basename[j], extensions[i].ext);
@@ -1168,11 +1168,11 @@
 			_vm->generateSubstResFileName(buf, buf1, sizeof(buf1));
 			strcpy(buf, buf1);
 		}
-		if (file->open(buf) && _vm->_heversion <= 73) 
+		if (file->open(buf) && _vm->_heversion <= 73)
 			file->setEnc(0x69);
 		_soundMode = kVOCMode;
 	}
-	
+
 	if (_soundMode != kVOCMode) {
 		/* Now load the 'offset' index in memory to be able to find the MP3 data
 
@@ -1236,7 +1236,7 @@
 
 	if (_vm->_gameId == GID_LOOM256)
 		timer_interval = 100;
-	else 
+	else
 		timer_interval = 101;
 
 	_vm->_timer->removeTimerProc(&cd_timer_handler);
@@ -1290,7 +1290,7 @@
 
 /*
  * TODO: The way we handle sound/music resources really is one huge hack.
- * We probably should reconsider how we do this, and maybe come up with a 
+ * We probably should reconsider how we do this, and maybe come up with a
  * better/cleaner solution. Even if we keep the existing code, it really
  * could stand a thorough cleanup!
  */
@@ -1415,7 +1415,7 @@
 		char buffer[128];
 		debugC(DEBUG_SOUND, "Found base tag FMUS in sound %d, size %d", idx, total_size);
 		debugC(DEBUG_SOUND, "It was at position %d", _fileHandle->pos());
-		
+
 		_fileHandle->seek(4, SEEK_CUR);
 		// HSHD size
 		tmpsize = _fileHandle->readUint32BE();
@@ -1423,12 +1423,12 @@
 		_fileHandle->seek(tmpsize - 4, SEEK_CUR);
 		// SDAT size
 		tmpsize = _fileHandle->readUint32BE();
-		
+
 		// SDAT contains name of file we want
 		_fileHandle->read(buffer, tmpsize - 8);
 		// files seem to be 11 chars (8.3) unused space is replaced by spaces
 		*(strstr(buffer, " ")) = '\0';
-		
+
 		debugC(DEBUG_SOUND, "FMUS file %s", buffer);
 		if (dmuFile.open(buffer) == false) {
 			error("Can't open music file %s*", buffer);
@@ -1462,27 +1462,27 @@
 static byte ADLIB_INSTR_MIDI_HACK[95] = {
 	0x00, 0xf0, 0x14, 0x7d, 0x00,  // sysex 00: part on/off
 	0x00, 0x00, 0x03,              // part/channel  (offset  5)
-	0x00, 0x00, 0x07, 0x0f, 0x00, 0x00, 0x08, 0x00, 
+	0x00, 0x00, 0x07, 0x0f, 0x00, 0x00, 0x08, 0x00,
 	0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0xf7,
 	0x00, 0xf0, 0x41, 0x7d, 0x10,  // sysex 16: set instrument
 	0x00, 0x01,                    // part/channel  (offset 28)
-	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+	0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
 	0x00, 0x00, 0xf7,
 	0x00, 0xb0, 0x07, 0x64        // Controller 7 = 100 (offset 92)
 };
-			
+
 static const byte map_param[7] = {
 	0, 2, 3, 4, 8, 9, 0,
 };
 
 static const byte freq2note[128] = {
-	/*128*/	6, 6, 6, 6,  
+	/*128*/	6, 6, 6, 6,
 	/*132*/ 7, 7, 7, 7, 7, 7, 7,
 	/*139*/ 8, 8, 8, 8, 8, 8, 8, 8, 8,
 	/*148*/ 9, 9, 9, 9, 9, 9, 9, 9, 9,
@@ -1496,7 +1496,7 @@
 	/*235*/ 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
 	/*249*/ 18, 18, 18, 18, 18, 18, 18
 };
-			
+
 static const uint16 num_steps_table[] = {
 	1, 2, 4, 5,
 	6, 7, 8, 9,
@@ -1531,7 +1531,7 @@
 	  v1 = v1 * 2 + 31;
 	  v2 = v2 * 2 + 31;
 	}
-	
+
 	/* flags a */
 	if ((flags & 0x7) == 6)
 		ptr[0] = 0;
@@ -1561,13 +1561,13 @@
 	time = num_steps_table[t1] + num_steps_table[t2]
 		+ num_steps_table[t3 & 0x7f] + num_steps_table[t4];
 	if (flags & 0x20) {
-		int playtime = ((src_ptr[4] >> 4) & 0xf) * 118 + 
+		int playtime = ((src_ptr[4] >> 4) & 0xf) * 118 +
 			(src_ptr[4] & 0xf) * 8;
 		if (playtime > time)
 			time = playtime;
 	}
 	/*
-	time = ((src_ptr[4] >> 4) & 0xf) * 118 + 
+	time = ((src_ptr[4] >> 4) & 0xf) * 118 +
 		(src_ptr[4] & 0xf) * 8;
 	*/
 	return time;
@@ -1576,7 +1576,7 @@
 #define kMIDIHeaderSize		46
 static inline byte *writeMIDIHeader(byte *ptr, const char *type, int ppqn, int total_size) {
 	uint32 dw = TO_BE_32(total_size);
-	
+
 	memcpy(ptr, type, 4); ptr += 4;
 	memcpy(ptr, &dw, 4); ptr += 4;
 	memcpy(ptr, "MDhd", 4); ptr += 4;
@@ -1588,7 +1588,7 @@
 	ptr += 4;
 	ptr[0] = 0; ptr[1] = 0; ptr[2] = 0; ptr[3] = 1; // MIDI format 0 with 1 track
 	ptr += 4;
-	
+
 	*ptr++ = ppqn >> 8;
 	*ptr++ = ppqn & 0xFF;
 
@@ -1640,28 +1640,28 @@
 	---
 	   4 bytes - 'SOUN'
 	BE 4 bytes - block length
-	
+
 		   4 bytes  - 'Mac0'
 		BE 4 bytes  - (blockLength - 27)
 		   28 bytes - ???
-	
+
 		   do this three times (once for each channel):
 			  4 bytes  - 'Chan'
 		   BE 4 bytes  - channel length
 			  4 bytes  - instrument name (e.g. 'MARI')
-	
+
 			  do this for ((chanLength-24)/4) times:
 				 2 bytes  - note duration
 				 1 byte   - note value
 				 1 byte   - note velocity
-	
+
 			  4 bytes - ???
 			  4 bytes - 'Loop'/'Done'
 			  4 bytes - ???
-	
+
 	   1 byte - 0x09
 	---
-	
+
 	Instruments (General Midi):
 	"MARI" - Marimba (12)
 	"PLUC" - Pizzicato Strings (45)
@@ -1677,8 +1677,8 @@
 	"ORGA" - Drawbar Organ (16; but could also be 17-20)
 	"BONG" - Woodblock? (115)
 	"BASS" - Bass (32-39)
-	
-	
+
+
 	Now the task could be to convert this into MIDI, to be fed into iMuse.
 	Or we do something similiar to what is done in Player_V3, assuming
 	we can identify SFX in the MI datafiles for each of the instruments
@@ -1691,14 +1691,14 @@
 #else
 	const int ppqn = 480;
 	byte *ptr, *start_ptr;
-	
+
 	int total_size = 0;
 	total_size += kMIDIHeaderSize; // Header
 	total_size += 7;               // Tempo META
 	total_size += 3 * 3;           // Three program change mesages
 	total_size += 22;              // Possible jump SysEx
 	total_size += 5;               // EOT META
-	
+
 	int i, len;
 	byte track_instr[3];
 	byte *track_data[3];
@@ -1719,17 +1719,17 @@
 		track_data[i] = src_ptr + 12;
 		src_ptr += len;
 		looped = (*((uint32*)(src_ptr - 8)) == MKID('Loop'));
-		
+
 		// For each note event, we need up to 6 bytes for the
 		// Note On (3 VLQ, 3 event), and 6 bytes for the Note
 		// Off (3 VLQ, 3 event). So 12 bytes total.
 		total_size += 12 * track_len[i];
 	}
 	assert(*src_ptr == 0x09);
-	
+
 	// Create sound resource
 	start_ptr = res.createResource(type, idx, total_size);
-	
+
 	// Insert MIDI header
 	ptr = writeMIDIHeader(start_ptr, "GMD ", ppqn, total_size);
 
@@ -1751,7 +1751,7 @@
 	*ptr++ = 0; // VLQ
 	*ptr++ = 0xC2;
 	*ptr++ = track_instr[2];
-	
+
 	// And now, the actual composition. Please turn all cell phones
 	// and pagers off during the performance. Thank you.
 	uint16 nextTime[3] = { 1, 1, 1 };
@@ -1815,9 +1815,9 @@
 
 	// Insert end of song META
 	memcpy(ptr, "\x00\xff\x2f\x00\x00", 5); ptr += 5;
-	
+
 	assert(ptr <= start_ptr + total_size);
-	
+
 	// Rewrite MIDI header, this time with true size
 	total_size = ptr - start_ptr;
 	ptr = writeMIDIHeader(start_ptr, "GMD ", ppqn, total_size);
@@ -1834,7 +1834,7 @@
 	byte *ptr;
 	int total_size = kMIDIHeaderSize + 7 + 8 * sizeof(ADLIB_INSTR_MIDI_HACK) + size;
 	total_size += 24;	// Up to 24 additional bytes are needed for the jump sysex
-	
+
 	ptr = res.createResource(type, idx, total_size);
 
 	src_ptr += 2;
@@ -1850,26 +1850,26 @@
 
 		// The "speed" of the song
 		ticks = *(src_ptr + 1);
-		
+
 		// Flag that tells us whether we should loop the song (0) or play it only once (1)
 		play_once = *(src_ptr + 2);
-		
+
 		// Number of instruments used
 		num_instr = *(src_ptr + 8);	// Normally 8
-		
+
 		// copy the pointer to instrument data
 		channel = src_ptr + 9;
 		instr   = src_ptr + 0x11;
-		
+
 		// skip over the rest of the header and copy the MIDI data into a buffer
 		src_ptr  += 0x11 + 8 * 16;
 		size -= 0x11 + 8 * 16;
 
-		CHECK_HEAP 
-			
+		CHECK_HEAP
+
 		track = src_ptr;
-		
-		// Convert the ticks into a MIDI tempo. 
+
+		// Convert the ticks into a MIDI tempo.
 		// Unfortunate LOOM and INDY3 have different interpretation
 		// of the ticks value.
 		if (_gameId == GID_INDY3) {
@@ -1881,18 +1881,18 @@
 			dw = 500000 * 256 / ticks;
 		}
 		debugC(DEBUG_SOUND, "  ticks = %d, speed = %ld", ticks, dw);
-			
+
 		// Write a tempo change Meta event
 		memcpy(ptr, "\x00\xFF\x51\x03", 4); ptr += 4;
 		*ptr++ = (byte)((dw >> 16) & 0xFF);
 		*ptr++ = (byte)((dw >> 8) & 0xFF);
 		*ptr++ = (byte)(dw & 0xFF);
-		
+
 		// Copy our hardcoded instrument table into it
 		// Then, convert the instrument table as given in this song resource
 		// And write it *over* the hardcoded table.
 		// Note: we deliberately.
-		
+
 		/* now fill in the instruments */
 		for (i = 0; i < num_instr; i++) {
 			ch = channel[i] - 1;
@@ -1961,7 +1961,7 @@
 			*ptr++ = (ppqn / 3 >> 7) | 0x80;
 		*ptr++ = ppqn / 3 & 0x7f;
 
-		// Now copy the actual music data 
+		// Now copy the actual music data
 		memcpy(ptr, track, size);
 		ptr += size;
 
@@ -2054,7 +2054,7 @@
 			int mintime = -1;
 			ch = -1;
 			for (i = 0; i < 3; i++) {
-				if (track_time[i] >= 0 && 
+				if (track_time[i] >= 0 &&
 					(mintime == -1 || mintime > track_time[i])) {
 					mintime = track_time[i];
 					ch = i;
@@ -2085,7 +2085,7 @@
 
 			case 2:
 				/* tone/parammodulation */
-				memcpy(ptr, ADLIB_INSTR_MIDI_HACK, 
+				memcpy(ptr, ADLIB_INSTR_MIDI_HACK,
 					   sizeof(ADLIB_INSTR_MIDI_HACK));
 
 				ptr[5]  += ch;
@@ -2175,14 +2175,14 @@
 						note = 0;
 					else
 						note += freq2note[freq - 0x80];
-	
+
 					debugC(DEBUG_SOUND, "Note: %d", note);
 					if (note <= 0)
 						note = 1;
 					else if (note > 127)
 						note = 127;
 
-					// Insert a note on event 
+					// Insert a note on event
 					*ptr++ = 0x90 + ch; // key on channel
 					*ptr++ = note;
 					*ptr++ = 63;
@@ -2305,7 +2305,7 @@
 			convertADResource(type, idx, ptr, ad_size - 6);
 			free(ptr);
 			return 1;
-		} 
+		}
 	} else if (((_midiDriver == MD_PCJR) || (_midiDriver == MD_PCSPK)) && wa_offs != 0) {
 		if (_features & GF_OLD_BUNDLE) {
 			_fileHandle->seek(wa_offs, SEEK_SET);
@@ -2412,7 +2412,7 @@
 		assert((len & 3) == 0);
 	else if (is16Bit || stereo)
 		assert((len & 1) == 0);
-	
+
 	// Verify that the stream has not yet been finalized (by a call to finish())
 	assert(!_finalized);
 
@@ -2452,7 +2452,7 @@
 	const bool is16Bit = (_flags & Audio::Mixer::FLAG_16BITS) != 0;
 	const bool isUnsigned = (_flags & Audio::Mixer::FLAG_UNSIGNED) != 0;
 	const bool isLE       = (_flags & Audio::Mixer::FLAG_LITTLE_ENDIAN) != 0;
-	
+
 	if (isStereo) {
 		if (isUnsigned) {
 			MAKE_WRAPPED(true, true);

Index: sound.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/sound.h,v
retrieving revision 1.90
retrieving revision 1.91
diff -u -d -r1.90 -r1.91
--- sound.h	4 Jun 2005 06:30:35 -0000	1.90
+++ sound.h	30 Jul 2005 21:11:31 -0000	1.91
@@ -70,7 +70,7 @@
 	} _soundQue2[10];
 
 	ScummFile *_sfxFile;
-	SoundMode _soundMode;	
+	SoundMode _soundMode;
 	MP3OffsetTable *_offsetTable;	// For compressed audio
 	int _numSoundEffects;		// For compressed audio
 

Index: sprite_he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/sprite_he.cpp,v
retrieving revision 1.151
retrieving revision 1.152
diff -u -d -r1.151 -r1.152
--- sprite_he.cpp	23 Jul 2005 16:11:20 -0000	1.151
+++ sprite_he.cpp	30 Jul 2005 21:11:31 -0000	1.152
@@ -219,7 +219,7 @@
 	int code, classId;
 
 	if (num == 0)
-		return _spriteTable[spriteId].classFlags; 
+		return _spriteTable[spriteId].classFlags;
 
 	for (int i = 0; i < num; i++) {
 		code = classId = args[i];
@@ -437,7 +437,7 @@
 	writeVar(0, 0);
 	defineArray(0, kDwordArray, 0, 0, 0, numSprites);
 	writeArray(0, 0, 0, numSprites);
-	
+
 	numSprites = 1;
 	for (i = (_sprite->_varNumSprites - 1); i > 0; i--) {
 		if (_sprite->_spriteTable[i].group == spriteGroupId) {
@@ -445,7 +445,7 @@
 			numSprites++;
 		}
 	}
-	
+
 	return readVar(0);
 }
 
@@ -526,7 +526,7 @@
 		int imageStateCount = _spriteTable[spriteId].imageStateCount - 1;
 		state = MAX(0, state);
 		state = MIN(state, imageStateCount);
-	
+
 		if (_spriteTable[spriteId].imageState != state) {
 			_spriteTable[spriteId].imageState = state;
 			_spriteTable[spriteId].flags |= kSFChanged | kSFNeedRedraw;
@@ -724,7 +724,7 @@
 void Sprite::setSpriteSetClass(int spriteId, int classId, int toggle) {
 	checkRange(_varNumSprites, 1, spriteId, "Invalid sprite %d");
 	checkRange(32, 1, classId, "class %d out of range in statement");
-	
+
 	if (toggle) {
 		_spriteTable[spriteId].classFlags |= (1 << (classId - 1));
 	} else {
@@ -1084,7 +1084,7 @@
 void Sprite::resetBackground() {
 	int xmin, xmax, ymin, ymax;
 	xmin = ymin = 1234;
-	xmax = ymax = -1234; 
+	xmax = ymax = -1234;
 	bool firstLoop = true;
 	bool refreshScreen = false;
 
@@ -1166,12 +1166,12 @@
 			spi->ty += spi->dy;
 			if (tx != spi->tx || ty != spi->ty) {
 				spi->flags |= kSFChanged | kSFNeedRedraw;
-			}			
+			}
 		}
 		if (spi->flags & kSFAutoAnim) {
 			if (spi->animSpeed) {
 				--spi->animProgress;
-				if (spi->animProgress) 
+				if (spi->animProgress)
 					continue;
 
 				spi->animProgress = spi->animSpeed;
@@ -1261,7 +1261,7 @@
 			if (spi->zorder < 0)
 				continue;
 		}
-		
+
 		spi->flags &= ~kSFNeedRedraw;
 		image = spi->image;
 		imageState = spi->imageState;
@@ -1360,7 +1360,7 @@
 		}
 		wiz.processFlags |= kWPFNewFlags;
 		wiz.img.flags |= spi->imgFlags;
-		
+
 		if (spr_flags & kSFRotated) {
 			wiz.processFlags |= kWPFRotate;
 			wiz.angle = spi->angle;
@@ -1370,7 +1370,7 @@
 			wiz.scale = spi->scale;
 		}
 		spi->curImgFlags = wiz.img.flags;
-		
+
 		if (spi->group && (_spriteGroups[spi->group].flags & kSGFClipBox)) {
 			Common::Rect &spgBbox = _spriteGroups[spi->group].bbox;
 			if (spgBbox.isValidRect() && spi->bbox.intersects(spgBbox)) {
@@ -1439,7 +1439,7 @@
 		MKLINE(SpriteInfo, field_90, sleInt32, VER(48)),
 		MKEND()
 	};
-	
+
 	static const SaveLoadEntry spriteGroupEntries[] = {
 		MKLINE(SpriteGroup, bbox.left, sleInt32, VER(48)),
 		MKLINE(SpriteGroup, bbox.top, sleInt32, VER(48)),

Index: sprite_he.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/sprite_he.h,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -d -r1.42 -r1.43
--- sprite_he.h	5 Jun 2005 08:22:09 -0000	1.42
+++ sprite_he.h	30 Jul 2005 21:11:31 -0000	1.43
@@ -1,6 +1,6 @@
 /* ScummVM - Scumm Interpreter
  * Copyright (C) 2001  Ludvig Strigeus
- * Copyright (C) 2001-2005 The ScummVM project 
+ * Copyright (C) 2001-2005 The ScummVM project
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
@@ -128,7 +128,7 @@
 	int getSpriteFlagActive(int spriteId);
 	int getSpriteFlagRemapPalette(int spriteId);
 	int getSpriteFlagAutoAnim(int spriteId);
-	int getSpriteFlagUpdateType(int spriteId);	
+	int getSpriteFlagUpdateType(int spriteId);
 	int getSpriteFlagEraseType(int spriteId);
 	int getSpriteImage(int spriteId);
 	int getSpriteImageState(int spriteId);

Index: string.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/string.cpp,v
retrieving revision 1.298
retrieving revision 1.299
diff -u -d -r1.298 -r1.299
--- string.cpp	2 Jul 2005 14:45:24 -0000	1.298
+++ string.cpp	30 Jul 2005 21:11:31 -0000	1.299
@@ -188,7 +188,7 @@
 		_talkDelay = 60;
 	else
 		_talkDelay = VAR(VAR_DEFAULT_TALK_DELAY);
-		
+
 	if (!_keepText) {
 		_charset->restoreCharsetBg();
 	}
@@ -222,7 +222,7 @@
 			_keepText = false;
 			break;
 		}
-		
+
 		// FIXME: This is a workaround for bug #864030: In COMI, some text
 		// contains ASCII character 11 = 0xB. It's not quite clear what it is
 		// good for; so for now we just ignore it, which seems to match the
@@ -333,7 +333,7 @@
 			case 9:
 				frme = *buffer++;
 				frme |= *buffer++ << 8;
-				if (a) 
+				if (a)
 					a->startAnimActor(frme);
 				break;
 			case 10:
@@ -341,7 +341,7 @@
 				talk_sound_a = buffer[0] | (buffer[1] << 8) | (buffer[4] << 16) | (buffer[5] << 24);
 				talk_sound_b = buffer[8] | (buffer[9] << 8) | (buffer[12] << 16) | (buffer[13] << 24);
 				buffer += 14;
-	
+
 				if (_heversion >= 60) {
 					_sound->startHETalkSound(talk_sound_a);
 				} else {
@@ -374,7 +374,7 @@
 				break;
 			case 14: {
 				int oldy = _charset->getFontHeight();
-	
+
 				_charset->setCurID(*buffer++);
 				buffer += 2;
 				for (i = 0; i < 4; i++)
@@ -410,7 +410,7 @@
 					// Special case for loomcd, since it only uses CD audio.for sound
 				} else if (!ConfMan.getBool("subtitles") && (_haveMsg == 0xFE || _mixer->isSoundHandleActive(_sound->_talkChannelHandle))) {
 					// Subtitles are turned off, and there is a voice version
-					// of this message -> don't print it. 
+					// of this message -> don't print it.
 				} else
 					_charset->printChar(c);
 			}
@@ -426,7 +426,7 @@
 				VAR(VAR_CHARCOUNT)++;
 			} else
 				_talkDelay += (int)VAR(VAR_CHARINC);
-			
+
 			// Handle line breaks for V1-V3
 			if (_version <= 3 && _charset->_nextLeft > _screenWidth) {
 				goto newLine;
@@ -681,7 +681,7 @@
 				*dst++ = chr;
 			}
 		}
-	
+
 		// Check for a buffer overflow
 		if (dst >= end)
 			error("convertMessageToString: buffer overflow!");
@@ -818,7 +818,7 @@
 				if (_charset->_left < 0)
 					_charset->_left = 0;
 			}
-	
+
 			do {
 				c = *buf++;
 				if (c != 0 && c != 0xFF && c != '\n') {
@@ -874,7 +874,7 @@
 		_existLanguageFile = false;
 		return;
 	}
-	
+
 	_existLanguageFile = true;
 
 	size = file.size();
@@ -909,7 +909,7 @@
 		int lineCount = _languageIndexSize;
 		const char *baseTag = "";
 		byte enc = 0;	// Initially assume the language file is not encoded
-	
+
 		// We'll determine the real index size as we go.
 		_languageIndexSize = 0;
 		for (i = 0; i < lineCount; i++) {
@@ -931,23 +931,23 @@
 					idx = idx * 10 + (*ptr - '0');
 					ptr++;
 				}
-	
+
 				// ...followed by a slash...
 				assert(*ptr == '/');
 				ptr++;
-	
+
 				// ...and then the translated message, possibly encoded
 				_languageIndex[_languageIndexSize].offset = ptr - _languageBuffer;
-	
+
 				// Decode string if necessary.
 				if (enc) {
 					while (*ptr != '\n' && *ptr != '\r')
 						*ptr++ ^= enc;
 				}
-	
+
 				// The tag is the basetag, followed by a dot and then the index
 				sprintf(_languageIndex[_languageIndexSize].tag, "%s.%03d", baseTag, idx);
-	
+
 				// That was another index entry
 				_languageIndexSize++;
 			} else {
@@ -968,14 +968,14 @@
 			for (j = 0; j < 8 && !isspace(*ptr); j++, ptr++)
 				_languageIndex[i].tag[j] = toupper(*ptr);
 			_languageIndex[i].tag[j] = 0;
-	
+
 			// After that follows a single space which we skip
 			assert(isspace(*ptr));
 			ptr++;
 
 			// Then comes the translated string: we record an offset to that.
 			_languageIndex[i].offset = ptr - _languageBuffer;
-	
+
 			// Skip over newlines (and turn them into null bytes)
 			ptr = strpbrk(ptr, "\n\r");
 			if (ptr == NULL)
@@ -1023,7 +1023,7 @@
 	LangIndexNode target;
 	LangIndexNode *found = NULL;
 	int i;
-	
+
 	trans_buff[0] = 0;
 	_lastStringTag[0] = 0;
 
@@ -1055,7 +1055,7 @@
 			text = (const byte *)"/NEW.014/lens slot";
 	}
 
-	
+
 	if (_version >= 7 && text[0] == '/') {
 		// Extract the string tag from the text: /..../
 		for (i = 0; (i < 12) && (text[i + 1] != '/'); i++)
@@ -1072,7 +1072,7 @@
 			// we're supposed to use it, but at least in the
 			// English version things will work so much better if
 			// we can't find translations for these.
-			
+
 			if (*text && strcmp(target.tag, "PU_M001") != 0 && strcmp(target.tag, "PU_M002") != 0)
 				found = (LangIndexNode *)bsearch(&target, _languageIndex, _languageIndexSize, sizeof(LangIndexNode), indexCompare);
 		}
@@ -1091,7 +1091,7 @@
 				while (*src && *src != 0xFF) {
 					src++;
 				}
-				
+
 				// Replace the %___ by the special code. Luckily, we can do
 				// that in-place.
 				if (*src == 0xFF) {

Index: thumbnail.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/thumbnail.cpp,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- thumbnail.cpp	27 Jun 2005 21:44:40 -0000	1.6
+++ thumbnail.cpp	30 Jul 2005 21:11:32 -0000	1.7
@@ -19,7 +19,7 @@
  * $Header$
  *
  */
- 
+
 #include "common/stdafx.h"
 #include "common/system.h"
 #include "common/savefile.h"
@@ -74,13 +74,13 @@
 	header.width = file->readUint16BE();
 	header.height = file->readUint16BE();
 	header.bpp = file->readByte();
-	
+
 	// TODO: support other bpp values than 2
 	if (header.bpp != 2) {
 		file->skip(header.size - 14);
 		return 0;
 	}
-	
+
 	Graphics::Surface *thumb = new Graphics::Surface();
 	thumb->create(header.width, header.height, sizeof(uint16));
 
@@ -90,7 +90,7 @@
 		for (int x = 0; x < thumb->w; ++x) {
 			uint8 r, g, b;
 			colorToRGB(file->readUint16BE(), r, g, b);
-			
+
 			// converting to current OSystem Color
 			*pixels++ = _system->RGBToColor(r, g, b);
 		}
@@ -101,12 +101,12 @@
 
 void ScummEngine::saveThumbnail(Common::OutSaveFile *file) {
 	Graphics::Surface thumb;
- 
+
 #if !defined(DISABLE_SCALERS) && !defined(DISABLE_HQ_SCALERS) // fcn has dep on HQ_SCALERS: thumbnail gets created as empty
 	if (!createThumbnailFromScreen(&thumb))
 #endif
 		thumb.create(kThumbnailWidth, kThumbnailHeight2, sizeof(uint16));
-	
+
 	ThumbnailHeader header;
 	header.type = MKID('THMB');
 	header.size = sizeof(header) + thumb.w*thumb.h*thumb.bytesPerPixel;
@@ -121,7 +121,7 @@
 	file->writeUint16BE(header.width);
 	file->writeUint16BE(header.height);
 	file->writeByte(header.bpp);
-	
+
 	// TODO: for later this shouldn't be casted to uint16...
 	uint16* pixels = (uint16 *)thumb.pixels;
 	for (uint16 p = 0; p < thumb.w*thumb.h; ++p, ++pixels)

Index: usage_bits.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/usage_bits.cpp,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- usage_bits.cpp	24 Jun 2005 15:23:19 -0000	1.15
+++ usage_bits.cpp	30 Jul 2005 21:11:32 -0000	1.16
@@ -31,7 +31,7 @@
 	for (i = 409; i >= 0; i--) {
 		bool dirty_bit = ((gfxUsageBits[i] & 0x80000000) != 0);
 		bool restored_bit = ((gfxUsageBits[i] & 0x40000000) != 0);
-		
+
 		gfxUsageBits[3 * i] = gfxUsageBits[i] & 0x3FFFFFFF;
 		if (dirty_bit)
 			setGfxUsageBit(i, USAGE_BIT_DIRTY);

Index: util.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/util.cpp,v
retrieving revision 2.12
retrieving revision 2.13
diff -u -d -r2.12 -r2.13
--- util.cpp	19 May 2005 14:15:33 -0000	2.12
+++ util.cpp	30 Jul 2005 21:11:32 -0000	2.13
@@ -78,7 +78,7 @@
 
 	// Get the length of the data file to use for consistency checks
 	const uint32 data_file_len = size();
-	
+
 	// Read offset and length to the file records */
 	const uint32 file_record_off = readUint32BE();
 	const uint32 file_record_len = readUint32BE();
@@ -104,12 +104,12 @@
 
 		assert(file_name[0]);
 		//debug(7, "  extracting \'%s\'", file_name);
-		
+
 		// Consistency check. make sure the file data is in the file
 		if (file_off + file_len > data_file_len) {
 			return false;
 		}
-		
+
 		if (scumm_stricmp(file_name, filename) == 0) {
 			// We got a match!
 			setSubfileRange(file_off, file_len);
@@ -155,7 +155,7 @@
 
 uint32 ScummFile::read(void *dataPtr, uint32 dataSize) {
 	uint32 realLen;
-	
+
 	if (_subFileLen) {
 		// Limit the amount we read by the subfile boundaries.
 		const uint32 curPos = pos();
@@ -166,10 +166,10 @@
 			_ioFailed = true;
 		}
 	}
-	
+
 	realLen = File::read(dataPtr, dataSize);
-	
-	
+
+
 	// If an encryption byte was specified, XOR the data we just read by it.
 	// This simple kind of "encryption" was used by some of the older SCUMM
 	// games.
@@ -281,7 +281,7 @@
 	NES_UNKNOWN,
 	NES_GLOBDATA,
 	NES_ROOM,
-	NES_SCRIPT, 
+	NES_SCRIPT,
 	NES_SOUND,
 	NES_COSTUME,
 	NES_ROOMGFX,
@@ -292,7 +292,7 @@
 	NES_SPROFFS,
 	NES_SPRDATA,
 	NES_CHARSET,
-	NES_PREPLIST 
+	NES_PREPLIST
 };
 
 struct ScummNESFile::Resource {
@@ -936,7 +936,7 @@
 }
 
 // based on structure of Classic PC Maniac Mansion LFL files
-// (roomgfx resources are arranged in order, one per file, 
+// (roomgfx resources are arranged in order, one per file,
 // after the room blocks) */
 static ScummNESFile::Resource *lfl_01[] = { &res_rooms[1], &res_roomgfx[1], &res_scripts[57], &res_scripts[61], &res_scripts[76], &res_scripts[105], &res_scripts[111], &res_sounds[5], &res_scripts[132], &res_scripts[148], &res_scripts[155], &res_scripts[156], &res_sounds[39], NULL };
 static ScummNESFile::Resource *lfl_02[] = { &res_rooms[2], &res_roomgfx[2], NULL };
@@ -1109,7 +1109,7 @@
 
 		for (j = 0; lfl->entries[j] != NULL; j++) {
 			Resource *entry = lfl->entries[j];
-			
+
 			switch (entry->type) {
 			case NES_ROOM:
 				lfl_index.room_lfl[entry - res_rooms] = lfl->num;
@@ -1259,7 +1259,7 @@
 	const char *ext = strrchr(filename, '.');
 	char resNum[3];
 	int res;
-	
+
 	// We always have file name in form of XX.lfl
 	resNum[0] = ext[-2];
 	resNum[1] = ext[-1];
@@ -1472,7 +1472,7 @@
 	};
 	int i;
 	uint16 reslen = 0;
-		
+
 	openDisk(_roomDisks[res]);
 
 	File::seek((SectorOffset[_roomTracks[res]] + _roomSectors[res]) * 256);
@@ -1528,7 +1528,7 @@
 	const char *ext = strrchr(filename, '.');
 	char resNum[3];
 	int res;
-	
+
 	// We always have file name in form of XX.lfl
 	resNum[0] = ext[-2];
 	resNum[1] = ext[-1];

Index: util.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/util.h,v
retrieving revision 2.13
retrieving revision 2.14
diff -u -d -r2.13 -r2.14
--- util.h	19 May 2005 14:15:34 -0000	2.13
+++ util.h	30 Jul 2005 21:11:32 -0000	2.14
@@ -32,7 +32,7 @@
 class BaseScummFile : public Common::File {
 public:
 	virtual void setEnc(byte value) = 0;
-	
+
 	virtual bool open(const char *filename, AccessMode mode = kFileReadMode) = 0;
 	virtual bool openSubFile(const char *filename) = 0;
 
@@ -52,7 +52,7 @@
 public:
 	ScummFile();
 	void setEnc(byte value);
-	
+
 	void setSubfileRange(uint32 start, uint32 len);
 	void resetSubfile();
 
@@ -74,7 +74,7 @@
 		kROMsetEurope,
 		kROMsetSweden,
 		kROMsetFrance,
-		kROMsetNum 
+		kROMsetNum
 	};
 
 	struct Resource;
@@ -97,7 +97,7 @@
 public:
 	ScummNESFile();
 	void setEnc(byte value);
-	
+
 	bool open(const char *filename, AccessMode mode = kFileReadMode);
 	bool openSubFile(const char *filename);
 
@@ -143,7 +143,7 @@
 public:
 	ScummC64File(char *disk1, char *disk2, bool maniac);
 	void setEnc(byte value);
-	
+
 	bool open(const char *filename, AccessMode mode = kFileReadMode);
 	bool openSubFile(const char *filename);
 

Index: vars.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/vars.cpp,v
retrieving revision 1.141
retrieving revision 1.142
diff -u -d -r1.141 -r1.142
--- vars.cpp	24 Jun 2005 16:14:39 -0000	1.141
+++ vars.cpp	30 Jul 2005 21:11:32 -0000	1.142
@@ -166,7 +166,7 @@
 	VAR_ROOM_WIDTH = 41;
 	VAR_ROOM_HEIGHT = 54;
 
-	if (_heversion >= 60 && _heversion <= 61) {	
+	if (_heversion >= 60 && _heversion <= 61) {
 		VAR_NOSUBTITLES = 60;
 	} else {
 		VAR_SUBTITLES = 60;
@@ -182,7 +182,7 @@
 
 	VAR_V6_EMSSPACE = 76;
 	VAR_RANDOM_NR = 118;
-	
+
 	VAR_TIMEDATE_YEAR = 119;
 	VAR_TIMEDATE_MONTH = 129;
 	VAR_TIMEDATE_DAY = 128;
@@ -451,7 +451,7 @@
 	VAR_VOICE_MODE = 39; // 0 is voice, 1 is voice+text, 2 is text only
 	VAR_GAME_LOADED = 40;
 	VAR_LANGUAGE = 41;
-	
+
 	VAR_CURRENTDISK = 42;
 	VAR_MUSIC_BUNDLE_LOADED = 45;
 	VAR_VOICE_BUNDLE_LOADED = 46;
@@ -523,7 +523,7 @@
 		// Setup light
 		VAR(VAR_CURRENT_LIGHTS) = LIGHTMODE_actor_base | LIGHTMODE_actor_color | LIGHTMODE_screen;
 	}
-	
+
 	if (_gameId == GID_MONKEY || _gameId == GID_MONKEY_SEGA)
 		_scummVars[74] = 1225;
 }
@@ -607,7 +607,7 @@
 		case MD_PCSPK:
 		case MD_PCJR:  VAR(VAR_SOUNDCARD) = 1; break;
 		case MD_ADLIB: VAR(VAR_SOUNDCARD) = 3; break;
-		default:       
+		default:
 			if ((_gameId == GID_MONKEY_EGA || _gameId == GID_MONKEY_VGA || _gameId == GID_LOOM)
 			   &&  (_platform == Common::kPlatformPC)) {
 				if (_gameId == GID_LOOM) {
@@ -667,7 +667,7 @@
 				VAR(39) = 80;
 			}
 			VAR(VAR_HEAPSPACE) = 1400;
-		} 
+		}
 		if (_version >= 4) {
 			VAR(VAR_HEAPSPACE) = 1400;
 			VAR(VAR_FIXEDDISK) = true;
@@ -677,10 +677,10 @@
 		if (_version == 6)
 			VAR(VAR_V6_EMSSPACE) = 10000;
 	}
-	
+
 	if (VAR_FADE_DELAY != 0xFF)
 		VAR(VAR_FADE_DELAY) = 3;
-		
+
 	VAR(VAR_CHARINC) = 4;
 	setTalkingActor(0);
 }

Index: verbs.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/verbs.cpp,v
retrieving revision 1.139
retrieving revision 1.140
diff -u -d -r1.139 -r1.140
--- verbs.cpp	24 Jun 2005 15:23:19 -0000	1.139
+++ verbs.cpp	30 Jul 2005 21:11:32 -0000	1.140
@@ -226,7 +226,7 @@
 
 	y -= virtscr[kVerbVirtScreen].topline;
 
-	if ((y < inventoryArea) || !(_mouseAndKeyboardStat & MBS_LEFT_CLICK)) 
+	if ((y < inventoryArea) || !(_mouseAndKeyboardStat & MBS_LEFT_CLICK))
 		return;
 
 	if (_mouseOverBoxesV2[kInventoryUpArrow].rect.contains(x, y)) {
@@ -286,7 +286,7 @@
 		int obj = findInventory(_scummVars[VAR_EGO], i + 1 + _inventoryOffset);
 		if (obj == 0)
 			break;
-		
+
 		_string[1].ypos = _mouseOverBoxesV2[i].rect.top + vs->topline;
 		_string[1].xpos = _mouseOverBoxesV2[i].rect.left;
 
@@ -397,7 +397,7 @@
 				}
 			}
 		}
-		
+
 		if ((_gameId == GID_INDY4 || _gameId == GID_PASS) && _mouseAndKeyboardStat >= '0' && _mouseAndKeyboardStat <= '9') {
 			// To support keyboard fighting in FOA, we need to remap the number keys.
 			// FOA apparently expects PC scancode values (see script 46 if you want
@@ -412,7 +412,7 @@
 				};
 			_mouseAndKeyboardStat = numpad[_mouseAndKeyboardStat - '0'];
 		}
-		
+
 		// Generic keyboard input
 		runInputScript(4, _mouseAndKeyboardStat, 1);
 	} else if (_mouseAndKeyboardStat & MBS_MOUSE_MASK) {
@@ -521,7 +521,7 @@
 			msg += 4;
 
 		enqueueText(msg, vs->curRect.left, vs->curRect.top, color, vs->charset_nr, vs->center);
-		
+
 		// Set the specified charset id
 		_charset->setCurID(vs->charset_nr);
 
@@ -557,7 +557,7 @@
 			drawVerbBitmap(verb, vs->curRect.left, vs->curRect.top);
 			return;
 		}
-		
+
 		restoreVerbBG(verb);
 
 		_string[4].charset = vs->charset_nr;
@@ -575,7 +575,7 @@
 
 		// FIXME For the future: Indy3 and under inv scrolling
 		/*
-		   if (verb >= 31 && verb <= 36) 
+		   if (verb >= 31 && verb <= 36)
 		   verb += _inventoryOffset;
 		 */
 

Index: wiz_he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/wiz_he.cpp,v
retrieving revision 2.91
retrieving revision 2.92
diff -u -d -r2.91 -r2.92
--- wiz_he.cpp	13 Jul 2005 12:22:08 -0000	2.91
+++ wiz_he.cpp	30 Jul 2005 21:11:32 -0000	2.92
@@ -97,7 +97,7 @@
 	wp->vert[4].y = vert1y;
 	wp->id = id;
 	wp->numVerts = 5;
-	wp->flag = flag;	
+	wp->flag = flag;
 
 	polygonCalcBoundBox(wp->vert, wp->numVerts, wp->bound);
 }
@@ -215,12 +215,12 @@
 void Wiz::copyAuxImage(uint8 *dst1, uint8 *dst2, const uint8 *src, int dstw, int dsth, int srcx, int srcy, int srcw, int srch) {
 	Common::Rect dstRect(srcx, srcy, srcx + srcw, srcy + srch);
 	dstRect.clip(dstw, dsth);
-	
+
 	int rw = dstRect.width();
 	int rh = dstRect.height();
 	if (rh <= 0 || rw <= 0)
 		return;
-	
+
 	uint8 *dst1Ptr = dst1 + dstRect.left + dstRect.top * dstw;
 	uint8 *dst2Ptr = dst2 + dstRect.left + dstRect.top * dstw;
 	const uint8 *dataPtr = src;
@@ -413,7 +413,7 @@
 	uint8 databit;
 	int h, w, xoff;
 	uint16 off;
-	
+
 	byte imagePal[256];
 	if (!palPtr) {
 		for (int i = 0; i < 256; i++) {
@@ -424,7 +424,7 @@
 
 	dstPtr = dst;
 	dataPtr = src;
-	
+
 	// Skip over the first 'srcRect->top' lines in the data
 	h = srcRect.top;
 	while (h--) {
@@ -434,7 +434,7 @@
 	w = srcRect.width();
 	if (h <= 0 || w <= 0)
 		return;
-		
+
 	while (h--) {
 		xoff = srcRect.left;
 		off = READ_LE_UINT16(dataPtr);
@@ -741,17 +741,17 @@
 	debug(1, "wizPackType1(%d, [%d,%d,%d,%d])", tColor, rCapt.left, rCapt.top, rCapt.right, rCapt.bottom);
 	wizPackCtx ctx;
 	memset(&ctx, 0, sizeof(ctx));
-	
+
 	src += rCapt.top * srcPitch + rCapt.left;
 	int w = rCapt.width();
 	int h = rCapt.height();
-	
+
 	uint8 *nextDstPtr, *curDstPtr;
 	uint8 curColor, prevColor;
 	int saveBufPos;
-	
+
 	nextDstPtr = curDstPtr = 0;
-	
+
 	int dataSize = 0;
 	while (h--) {
 		if (dst) {
@@ -761,7 +761,7 @@
 		}
 		dataSize += 2;
 		int numBytes = 0;
-		
+
 		int i, code;
 		for (i = 0; i < w; ++i) {
 			if (src[i] != tColor)
@@ -993,7 +993,7 @@
 	uint32 width  = READ_LE_UINT32(wizh + 0x4);
 	uint32 height = READ_LE_UINT32(wizh + 0x8);
 	debug(2, "wiz_header.comp = %d wiz_header.w = %d wiz_header.h = %d", comp, width, height);
-	
+
 	uint8 *wizd = _vm->findWrappedBlock(MKID('WIZD'), dataPtr, state, 0);
 	assert(wizd);
 
@@ -1130,17 +1130,17 @@
 	Common::Point pto;
 	InterArea *ia;
 	int areasNum;
-	
+
 	PolygonDrawData(int n) {
 		areasNum = n;
 		ia = new InterArea[areasNum];
 		memset(ia, 0, sizeof(InterArea) * areasNum);
 	}
-	
+
 	~PolygonDrawData() {
 		delete[] ia;
 	}
-	
+
 	void calcIntersection(const Common::Point *p1, const Common::Point *p2, const Common::Point *p3, const Common::Point *p4) {
 		int32 x1_acc = p1->x << 0x10;
 		int32 x3_acc = p3->x << 0x10;
@@ -1157,7 +1157,7 @@
   			int32 tx1 = x1_acc >> 0x10;
   			int32 tx3 = x3_acc >> 0x10;
   			int32 ty3 = y3_acc >> 0x10;
-  			
+
   			if (!pia->valid || pia->xmin > tx1) {
   				pia->xmin = tx1;
   				pia->x1 = tx3;
@@ -1173,12 +1173,12 @@
   			x1_acc += x1_step;
   			x3_acc += x3_step;
   			y3_acc += y3_step;
-  			
+
   			if (p2->y <= p1->y) {
   				--iaidx;
   			} else {
   				++iaidx;
-  			}  			
+  			}
   		}
 	}
 };
@@ -1309,7 +1309,7 @@
   			ymin_p = MIN(wp->vert[i].y, ymin_p);
   			ymax_p = MAX(wp->vert[i].y, ymax_p);
   		}
-  		
+
   		int16 xmin_b, xmax_b, ymin_b, ymax_b;
   		xmin_b = 0;
   		xmax_b = wizW - 1;
@@ -1319,12 +1319,12 @@
 		PolygonDrawData pdd(ymax_p - ymin_p + 1);
 		pdd.pto.x = xmin_p;
 		pdd.pto.y = ymin_p;
-		
+
 		for (i = 0; i < 3; ++i) {
 			pdd.calcIntersection(&wp->vert[i], &wp->vert[i + 1], &bbox[i], &bbox[i + 1]);
 		}
 		pdd.calcIntersection(&wp->vert[3], &wp->vert[0], &bbox[3], &bbox[0]);
-				
+
 		uint yoff = pdd.pto.y * pvs->w;
 		for (i = 0; i < pdd.areasNum; ++i) {
 			PolygonDrawData::InterArea *pia = &pdd.ia[i];
@@ -1396,7 +1396,7 @@
 
 	const Common::Rect *r = NULL;
 	uint8 *cursor = drawWizImage(resId, 0, 0, 0, 0, 0, 0, r, kWIFBlitToMemBuffer, 0, 0);
-	int32 cw, ch;	
+	int32 cw, ch;
 	getWizImageDim(resId, 0, cw, ch);
 	_vm->setCursorFromBuffer(cursor, cw, ch, cw);
 	_vm->setCursorHotspot(x, y);
@@ -1527,7 +1527,7 @@
 		res_size += 0x10C;
 	}
 	res_size += 8 + img_w * img_h;
-	
+
 	const uint8 *palPtr;
 	if (_vm->_heversion >= 99) {
 		palPtr = _vm->_hePalettes + 1024;
@@ -1549,7 +1549,7 @@
 		if (flags & 1) {
 			WRITE_BE_UINT32(res_data, 'RGBS'); res_data += 4;
 			WRITE_BE_UINT32(res_data, 0x308); res_data += 4;
-			memcpy(res_data, palPtr, 0x300); res_data += 0x300;			
+			memcpy(res_data, palPtr, 0x300); res_data += 0x300;
 		}
 		if (flags & 2) {
 			WRITE_BE_UINT32(res_data, 'SPOT'); res_data += 4;
@@ -1576,7 +1576,7 @@
 		state = params->img.state;
 	}
 	uint8 *dataPtr = _vm->getResourceAddress(rtImage, params->img.resNum);
-	if (dataPtr) {	
+	if (dataPtr) {
 		uint8 *wizh = _vm->findWrappedBlock(MKID('WIZH'), dataPtr, state, 0);
 		assert(wizh);
 		int c = READ_LE_UINT32(wizh + 0x0);
@@ -1609,7 +1609,7 @@
 	}
 }
 
-void Wiz::fillWizLine(const WizParameters *params) {	
+void Wiz::fillWizLine(const WizParameters *params) {
 	if (params->processFlags & kWPFClipBox2) {
 		int state = 0;
 		if (params->processFlags & kWPFNewState) {
@@ -1640,7 +1640,7 @@
 			int y1 = params->box2.top;
 			int x2 = params->box2.right;
 			int y2 = params->box2.bottom;
-			
+
 			int dx = x2 - x1;
 			int incx = 0;
 			if (dx > 0) {
@@ -1655,11 +1655,11 @@
 			} else if (dy < 0) {
 				incy = -1;
 			}
-			
+
 			if (r1.contains(x1, y1)) {
 				*(wizd + y1 * w + x1) = color;
 			}
-			
+
 			if (dx >= dy) {
 				int step1_y = (dy - dx) * 2;
 				int step2_y = dy * 2;
@@ -1690,7 +1690,7 @@
 					y1 += incy;
 					if (r1.contains(x1, y1)) {
 						*(wizd + y1 * w + x1) = color;
-					}					
+					}
 				}
 			}
 		}

Index: wiz_he.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/wiz_he.h,v
retrieving revision 2.27
retrieving revision 2.28
diff -u -d -r2.27 -r2.28
--- wiz_he.h	13 Jul 2005 12:22:08 -0000	2.27
+++ wiz_he.h	30 Jul 2005 21:11:32 -0000	2.28
@@ -1,6 +1,6 @@
 /* ScummVM - Scumm Interpreter
  * Copyright (C) 2001  Ludvig Strigeus
- * Copyright (C) 2001-2005 The ScummVM project 
+ * Copyright (C) 2001-2005 The ScummVM project
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
@@ -19,7 +19,7 @@
  * $Header$
  *
  */
- 
+
 #if !defined(WIZ_HE_H) && !defined(DISABLE_HE)
 #define WIZ_HE_H
 
@@ -144,7 +144,7 @@
 	WizImage _images[NUM_IMAGES];
 	uint16 _imagesNum;
 	WizPolygon _polygons[NUM_POLYGONS];
-	
+
 	Wiz(ScummEngine_v70he *vm);
 
 	void clearWizBuffer();
@@ -166,7 +166,7 @@
 	void fillWizLine(const WizParameters *params);
 
 	void getWizImageDim(int resNum, int state,  int32 &w, int32 &h);
-	int getWizImageStates(int resnum);	
+	int getWizImageStates(int resnum);
 	int isWizPixelNonTransparent(int resnum, int state, int x, int y, int flags);
 	uint8 getWizPixelColor(int resnum, int state, int x, int y, int flags);
 
@@ -183,7 +183,7 @@
 	void drawWizComplexPolygon(int resNum, int state, int po_x, int po_y, int shadow, int angle, int zoom, const Common::Rect *r, int flags, int dstResNum, int palette);
 	void processWizImage(const WizParameters *params);
 
-	static void copyAuxImage(uint8 *dst1, uint8 *dst2, const uint8 *src, int dstw, int dsth, int srcx, int srcy, int srcw, int srch);	
+	static void copyAuxImage(uint8 *dst1, uint8 *dst2, const uint8 *src, int dstw, int dsth, int srcx, int srcy, int srcw, int srch);
 	static void copyWizImage(uint8 *dst, const uint8 *src, int dstw, int dsth, int srcx, int srcy, int srcw, int srch, const Common::Rect *rect, const uint8 *palPtr = NULL);
 	static void copyRawWizImage(uint8 *dst, const uint8 *src, int dstw, int dsth, int srcx, int srcy, int srcw, int srch, const Common::Rect *rect, int flags, const uint8 *palPtr, int transColor);
 	static void copyRaw16BitWizImage(uint8 *dst, const uint8 *src, int dstw, int dsth, int srcx, int srcy, int srcw, int srch, const Common::Rect *rect, int flags, const uint8 *palPtr, int transColor);





More information about the Scummvm-git-logs mailing list