diff options
| author | Arnaud Boutonné | 2010-10-25 13:31:01 +0000 | 
|---|---|---|
| committer | Arnaud Boutonné | 2010-10-25 13:31:01 +0000 | 
| commit | 35f220ace2ae1839f8a0706fc0e3de1ad39a6045 (patch) | |
| tree | e070ebf4e9e901c19e86b93711937dec63b3f322 | |
| parent | 4e9a2798ef9aef3b28e595adeaa0873fd1ce6171 (diff) | |
| download | scummvm-rg350-35f220ace2ae1839f8a0706fc0e3de1ad39a6045.tar.gz scummvm-rg350-35f220ace2ae1839f8a0706fc0e3de1ad39a6045.tar.bz2 scummvm-rg350-35f220ace2ae1839f8a0706fc0e3de1ad39a6045.zip | |
HUGO: cleanup: Suppress trailing spaces and tabs
svn-id: r53825
| -rw-r--r-- | engines/hugo/display.cpp | 6 | ||||
| -rw-r--r-- | engines/hugo/file.cpp | 2 | ||||
| -rw-r--r-- | engines/hugo/file_v3d.cpp | 14 | ||||
| -rw-r--r-- | engines/hugo/hugo.cpp | 2 | ||||
| -rw-r--r-- | engines/hugo/hugo.h | 2 | ||||
| -rw-r--r-- | engines/hugo/intro_v3d.cpp | 2 | ||||
| -rw-r--r-- | engines/hugo/object.cpp | 12 | ||||
| -rw-r--r-- | engines/hugo/object.h | 4 | ||||
| -rw-r--r-- | engines/hugo/object_v1d.cpp | 2 | ||||
| -rw-r--r-- | engines/hugo/parser.h | 2 | ||||
| -rw-r--r-- | engines/hugo/parser_v3d.cpp | 2 | ||||
| -rw-r--r-- | engines/hugo/route.cpp | 4 | ||||
| -rw-r--r-- | engines/hugo/schedule.h | 2 | ||||
| -rw-r--r-- | engines/hugo/schedule_v1d.cpp | 2 | ||||
| -rw-r--r-- | engines/hugo/schedule_v3d.cpp | 2 | ||||
| -rw-r--r-- | engines/hugo/sound.cpp | 4 | ||||
| -rw-r--r-- | engines/hugo/sound.h | 2 | ||||
| -rw-r--r-- | engines/hugo/util.cpp | 4 | 
18 files changed, 35 insertions, 35 deletions
| diff --git a/engines/hugo/display.cpp b/engines/hugo/display.cpp index 5a5069b06c..2380ab9f30 100644 --- a/engines/hugo/display.cpp +++ b/engines/hugo/display.cpp @@ -213,7 +213,7 @@ int16 Screen::mergeLists(rect_t *list, rect_t *blist, int16 len, int16 blen, int  				if (OVERLAP(list, bp))  					coalesce[c++] = b;  		} -		 +  		// Any overlapping blit rects?  		if (c == 0) {                               // None, add a new entry  			blist[blen++] = *list; @@ -377,7 +377,7 @@ void Screen::shadowStr(int16 sx, int16 sy, const char *s, byte color) {  void Screen::userHelp() {  // Introduce user to the game  // DOS versions Only -	Utils::Box(BOX_ANY , "%s",  +	Utils::Box(BOX_ANY , "%s",  	           "F1  - Press F1 again\n"  	           "      for instructions\n"  	           "F2  - Sound on/off\n" @@ -421,7 +421,7 @@ void Screen::drawShape(int x, int y, int color1, int color2) {  			_backBuffer[320 * (y + (2 * shapeSize - 1) - i) + (x + shapeSize + j)] = color2;  			_frontBuffer[320 * (y + (2 * shapeSize - 1) - i) + (x + shapeSize + j)] = color2;  		} -	}		 +	}  }  void Screen::drawRectangle(bool filledFl, uint16 x1, uint16 y1, uint16 x2, uint16 y2, int color) { diff --git a/engines/hugo/file.cpp b/engines/hugo/file.cpp index 5c3b72f1aa..691536eff4 100644 --- a/engines/hugo/file.cpp +++ b/engines/hugo/file.cpp @@ -97,7 +97,7 @@ seq_t *FileManager::readPCX(Common::File &f, seq_t *seqPtr, byte *imagePtr, bool  		if ((seqPtr = (seq_t *)malloc(sizeof(seq_t))) == 0)  			Utils::Error(HEAP_ERR, "%s", name);  	} -	 +  	// Find size of image data in 8-bit DIB format  	// Note save of x2 - marks end of valid data before garbage  	uint16 bytesPerLine4 = PCC_header.bytesPerLine * 4; // 4-bit bpl diff --git a/engines/hugo/file_v3d.cpp b/engines/hugo/file_v3d.cpp index 095a225a39..f1e4bf0a15 100644 --- a/engines/hugo/file_v3d.cpp +++ b/engines/hugo/file_v3d.cpp @@ -50,7 +50,7 @@ void FileManager_v3d::readBackground(int screenIndex) {  	debugC(1, kDebugFile, "readBackground(%d)", screenIndex);  	_sceneryArchive1.seek((uint32) screenIndex * sizeof(sceneBlock_t), SEEK_SET); -	 +  	sceneBlock_t sceneBlock;                        // Read a database header entry  	sceneBlock.scene_off = _sceneryArchive1.readUint32LE();  	sceneBlock.scene_len = _sceneryArchive1.readUint32LE(); @@ -101,7 +101,7 @@ void FileManager_v3d::readOverlay(int screenNum, image_pt image, ovl_t overlayTy  	image_pt     tmpImage = image;                  // temp ptr to overlay file  	_sceneryArchive1.seek((uint32)screenNum * sizeof(sceneBlock_t), SEEK_SET); -	 +  	sceneBlock_t sceneBlock;                        // Database header entry  	sceneBlock.scene_off = _sceneryArchive1.readUint32LE();  	sceneBlock.scene_len = _sceneryArchive1.readUint32LE(); @@ -113,7 +113,7 @@ void FileManager_v3d::readOverlay(int screenNum, image_pt image, ovl_t overlayTy  	sceneBlock.ob_len = _sceneryArchive1.readUint32LE();  	uint32 i = 0; -	 +  	if (screenNum < 20) {  		switch (overlayType) {  		case BOUNDARY: @@ -137,7 +137,7 @@ void FileManager_v3d::readOverlay(int screenNum, image_pt image, ovl_t overlayTy  				image[i] = 0;  			return;  		} -	 +  		// Read in the overlay file using MAC Packbits.  (We're not proud!)  		int16 k = 0;                                // byte count  		do { @@ -149,7 +149,7 @@ void FileManager_v3d::readOverlay(int screenNum, image_pt image, ovl_t overlayTy  					*tmpImage++ = _sceneryArchive1.readByte();  			} else {                            // Repeat next byte -data+1 times  				int16 j = _sceneryArchive1.readByte(); -	 +  				for (i = 0; i < (byte)(-data + 1); i++, k++)  					*tmpImage++ = j;  			} @@ -177,7 +177,7 @@ void FileManager_v3d::readOverlay(int screenNum, image_pt image, ovl_t overlayTy  				image[i] = 0;  			return;  		} -	 +  		// Read in the overlay file using MAC Packbits.  (We're not proud!)  		int16 k = 0;                                // byte count  		do { @@ -189,7 +189,7 @@ void FileManager_v3d::readOverlay(int screenNum, image_pt image, ovl_t overlayTy  					*tmpImage++ = _sceneryArchive2.readByte();  			} else {                                // Repeat next byte -data+1 times  				int16 j = _sceneryArchive2.readByte(); -	 +  				for (i = 0; i < (byte)(-data + 1); i++, k++)  					*tmpImage++ = j;  			} diff --git a/engines/hugo/hugo.cpp b/engines/hugo/hugo.cpp index e63284f475..ce44466918 100644 --- a/engines/hugo/hugo.cpp +++ b/engines/hugo/hugo.cpp @@ -64,7 +64,7 @@ command_t   _line;                              // Line of user text input  HugoEngine::HugoEngine(OSystem *syst, const HugoGameDescription *gd) : Engine(syst), _gameDescription(gd), _mouseX(0), _mouseY(0),  	_textData(0), _stringtData(0), _screenNames(0), _textEngine(0), _textIntro(0), _textMouse(0), _textParser(0), _textSchedule(0), _textUtil(0),  	_arrayNouns(0), _arrayVerbs(0), _arrayReqs(0), _hotspots(0), _invent(0), _uses(0), _catchallList(0), _backgroundObjects(0), -	_points(0), _cmdList(0), _screenActs(0), _actListArr(0), _heroImage(0), _defltTunes(0), _palette(0), _introX(0), _introY(0),  +	_points(0), _cmdList(0), _screenActs(0), _actListArr(0), _heroImage(0), _defltTunes(0), _palette(0), _introX(0), _introY(0),  	_maxInvent(0), _numBonuses(0), _numScreens(0), _tunesNbr(0), _soundSilence(0), _soundTest(0), _screenStates(0), _numObj(0),  	_score(0), _maxscore(0) diff --git a/engines/hugo/hugo.h b/engines/hugo/hugo.h index f398fdbb9d..af82e3e2bb 100644 --- a/engines/hugo/hugo.h +++ b/engines/hugo/hugo.h @@ -190,7 +190,7 @@ public:  		return _mouseY;  	} -	void boundaryCollision(object_t *obj);  +	void boundaryCollision(object_t *obj);  	void clearBoundary(int x1, int x2, int y);  	void endGame();  	void initStatus(); diff --git a/engines/hugo/intro_v3d.cpp b/engines/hugo/intro_v3d.cpp index cedd78e4c8..8e0c0cc22c 100644 --- a/engines/hugo/intro_v3d.cpp +++ b/engines/hugo/intro_v3d.cpp @@ -69,7 +69,7 @@ void intro_v3d::introInit() {  	_vm->_screen->displayBackground();  	g_system->updateScreen();  	g_system->delayMillis(5000); -	 +  	_vm->_file->readBackground(22); // display screen MAP_3d  	_vm->_screen->displayBackground();  	introTicks = 0; diff --git a/engines/hugo/object.cpp b/engines/hugo/object.cpp index 8f4374a7a1..2dd77075c4 100644 --- a/engines/hugo/object.cpp +++ b/engines/hugo/object.cpp @@ -104,9 +104,9 @@ void ObjectHandler::useObject(int16 objId) {  	} else {  		// Use status.objid on objid  		// Default to first cmd verb -		sprintf(_line, "%s %s %s", _vm->_arrayVerbs[_vm->_cmdList[_objects[_vm->getGameStatus().inventoryObjId].cmdIndex][1].verbIndex][0],  -			                       _vm->_arrayNouns[_objects[_vm->getGameStatus().inventoryObjId].nounIndex][0],  -								   _vm->_arrayNouns[obj->nounIndex][0]); +		sprintf(_line, "%s %s %s", _vm->_arrayVerbs[_vm->_cmdList[_objects[_vm->getGameStatus().inventoryObjId].cmdIndex][1].verbIndex][0], +			                       _vm->_arrayNouns[_objects[_vm->getGameStatus().inventoryObjId].nounIndex][0], +			                       _vm->_arrayNouns[obj->nounIndex][0]);  		// Check valid use of objects and override verb if necessary  		for (uses_t *use = _vm->_uses; use->objId != _vm->_numObj; use++) { @@ -116,9 +116,9 @@ void ObjectHandler::useObject(int16 objId) {  				for (target_t *target = use->targets; _vm->_arrayNouns[target->nounIndex] != 0; target++)  					if (_vm->_arrayNouns[target->nounIndex][0] == _vm->_arrayNouns[obj->nounIndex][0]) {  						foundFl = true; -						sprintf(_line, "%s %s %s", _vm->_arrayVerbs[target->verbIndex][0],  -							                       _vm->_arrayNouns[_objects[_vm->getGameStatus().inventoryObjId].nounIndex][0],  -												   _vm->_arrayNouns[obj->nounIndex][0]); +						sprintf(_line, "%s %s %s", _vm->_arrayVerbs[target->verbIndex][0], +							                       _vm->_arrayNouns[_objects[_vm->getGameStatus().inventoryObjId].nounIndex][0], +							                       _vm->_arrayNouns[obj->nounIndex][0]);  					}  				// No valid use of objects found, print failure string diff --git a/engines/hugo/object.h b/engines/hugo/object.h index 179bd0eb59..a30a2ed57d 100644 --- a/engines/hugo/object.h +++ b/engines/hugo/object.h @@ -63,7 +63,7 @@ public:  	void saveSeq(object_t *obj);  	void showTakeables();  	void useObject(int16 objId); -	 +  	static int y2comp(const void *a, const void *b);  	bool isCarried(int objIndex) { @@ -73,7 +73,7 @@ public:  	void setCarry(int objIndex, bool val) {  		_objects[objIndex].carriedFl = val;  	} -	 +  	void setVelocity(int objIndex, int8 vx, int8 vy) {  		_objects[objIndex].vx = vx;  		_objects[objIndex].vy = vy; diff --git a/engines/hugo/object_v1d.cpp b/engines/hugo/object_v1d.cpp index 6cee3d5dbe..0b59b9f39b 100644 --- a/engines/hugo/object_v1d.cpp +++ b/engines/hugo/object_v1d.cpp @@ -248,7 +248,7 @@ void ObjectHandler_v1d::moveObjects() {  							else  								obj->currImagePtr = obj->seqList[LEFT].seqPtr;  						} -	 +  						if (obj->vx || obj->vy)  							obj->cycling = CYCLE_FORWARD;  						else diff --git a/engines/hugo/parser.h b/engines/hugo/parser.h index 1d4678b3af..b98813c7bc 100644 --- a/engines/hugo/parser.h +++ b/engines/hugo/parser.h @@ -114,7 +114,7 @@ public:  	void lineHandler();  }; -	 +  class Parser_v3d : public Parser_v1w {  public:  	Parser_v3d(HugoEngine *vm); diff --git a/engines/hugo/parser_v3d.cpp b/engines/hugo/parser_v3d.cpp index e7cc387161..49c9ec2c08 100644 --- a/engines/hugo/parser_v3d.cpp +++ b/engines/hugo/parser_v3d.cpp @@ -189,7 +189,7 @@ void Parser_v3d::lineHandler() {  	// Nothing matches.  Report recognition success to user.  	char *verb = findVerb();  	char *noun = findNoun(); -	 +  	if (verb && noun) {                             // A combination I didn't think of  		Utils::Box(BOX_ANY, "%s", _vm->_textParser[kTBNoPoint]);  	} else if (noun) { diff --git a/engines/hugo/route.cpp b/engines/hugo/route.cpp index 2b372947cf..9e068171a2 100644 --- a/engines/hugo/route.cpp +++ b/engines/hugo/route.cpp @@ -309,13 +309,13 @@ bool Route::findRoute(int16 cx, int16 cy) {  				_boundaryMap[y][x * 8 + i] = ((_vm->getObjectBoundaryOverlay()[y * XBYTES + x] | _vm->getBoundaryOverlay()[y * XBYTES + x]) & (0x80 >> i)) ? kMapBound : 0;  		}  	} -	 +  	// Clear all object baselines from objbound  	for (i = 0, obj = _vm->_object->_objects; i < _vm->_numObj; i++, obj++) {  		if ((obj->screenIndex == *_vm->_screen_p) && (obj->cycling != INVISIBLE) && (obj->priority == FLOATING))  			_vm->clearBoundary(obj->oldx + obj->currImagePtr->x1, obj->oldx + obj->currImagePtr->x2, obj->oldy + obj->currImagePtr->y2);  	} -	 +  	// Search from hero to destination  	segment(herox1, heroy); diff --git a/engines/hugo/schedule.h b/engines/hugo/schedule.h index 39aa1504bb..0f6c07e562 100644 --- a/engines/hugo/schedule.h +++ b/engines/hugo/schedule.h @@ -79,7 +79,7 @@ private:  	event_t *getQueue();  	void     delQueue(event_t *curEvent);  	event_t *doAction(event_t *curEvent); -	 +  	virtual const char *getCypher() = 0;  }; diff --git a/engines/hugo/schedule_v1d.cpp b/engines/hugo/schedule_v1d.cpp index 3fc4b4c984..16f2480ff5 100644 --- a/engines/hugo/schedule_v1d.cpp +++ b/engines/hugo/schedule_v1d.cpp @@ -46,7 +46,7 @@ Scheduler_v1d::~Scheduler_v1d() {  }  const char *Scheduler_v1d::getCypher() { -	return "Copyright 1991, Gray Design Associates";  +	return "Copyright 1991, Gray Design Associates";  }  } // End of namespace Hugo diff --git a/engines/hugo/schedule_v3d.cpp b/engines/hugo/schedule_v3d.cpp index 41c60902a4..8027ce0a8d 100644 --- a/engines/hugo/schedule_v3d.cpp +++ b/engines/hugo/schedule_v3d.cpp @@ -46,6 +46,6 @@ Scheduler_v3d::~Scheduler_v3d() {  }  const char *Scheduler_v3d::getCypher() { -	return "Copyright 1992, Gray Design Associates";  +	return "Copyright 1992, Gray Design Associates";  }  } // End of namespace Hugo diff --git a/engines/hugo/sound.cpp b/engines/hugo/sound.cpp index d3c8fa0238..b8a5a3297e 100644 --- a/engines/hugo/sound.cpp +++ b/engines/hugo/sound.cpp @@ -248,7 +248,7 @@ SoundHandler::SoundHandler(HugoEngine *vm) : _vm(vm) {  void SoundHandler::setMusicVolume() {  	/* Set the FM music volume from config.mvolume (0..100%) */ -	 +  	_midiPlayer->setVolume(_config.musicVolume * 255 / 100);  } @@ -265,7 +265,7 @@ void SoundHandler::stopMusic() {  void SoundHandler::toggleMusic() {  // Turn music on and off  	_config.musicFl = !_config.musicFl; -	 +  	_midiPlayer->pause(_config.musicFl);  } diff --git a/engines/hugo/sound.h b/engines/hugo/sound.h index a4e9932901..ff38a7f70a 100644 --- a/engines/hugo/sound.h +++ b/engines/hugo/sound.h @@ -38,7 +38,7 @@  namespace Hugo {  class MidiPlayer; -	 +  class SoundHandler {  public:  	SoundHandler(HugoEngine *vm); diff --git a/engines/hugo/util.cpp b/engines/hugo/util.cpp index 8cca4b7d84..2def4a4dba 100644 --- a/engines/hugo/util.cpp +++ b/engines/hugo/util.cpp @@ -78,14 +78,14 @@ void Utils::reverseByte(byte *data) {  		if (*data & maskIn)  			result |= maskOut;  	} -	 +  	*data = result;  }  char *Utils::Box(box_t dismiss, const char *s, ...) {  	static char buffer[MAX_STRLEN + 1];             // Format text into this -	if (!s)  +	if (!s)  		return 0;                                   // NULL strings catered for  	if (s[0] == '\0') | 
