[Scummvm-cvs-logs] SF.net SVN: scummvm:[43968] scummvm/trunk/engines/kyra/gui_lol.cpp

athrxx at users.sourceforge.net athrxx at users.sourceforge.net
Sun Sep 6 00:28:19 CEST 2009


Revision: 43968
          http://scummvm.svn.sourceforge.net/scummvm/?rev=43968&view=rev
Author:   athrxx
Date:     2009-09-05 22:28:18 +0000 (Sat, 05 Sep 2009)

Log Message:
-----------
LOL/Floppy: fix compass

Modified Paths:
--------------
    scummvm/trunk/engines/kyra/gui_lol.cpp

Modified: scummvm/trunk/engines/kyra/gui_lol.cpp
===================================================================
--- scummvm/trunk/engines/kyra/gui_lol.cpp	2009-09-05 22:00:17 UTC (rev 43967)
+++ scummvm/trunk/engines/kyra/gui_lol.cpp	2009-09-05 22:28:18 UTC (rev 43968)
@@ -45,7 +45,7 @@
 	if (_flagsTable[31] & 0x40) {
 		// copy compass shape
 		static const int cx[] = { 112, 152, 224 };
-		_screen->copyRegion(cx[_lang], 32, 288, 0, 32, 32, 2, 2, Screen::CR_NO_P_CHECK);
+		_screen->copyRegion(cx[_flags.isTalkie ? _lang : 0], 32, 288, 0, 32, 32, 2, 2, Screen::CR_NO_P_CHECK);
 		_compassDirection = -1;
 	}
 
@@ -576,10 +576,17 @@
 
 	const CompassDef *c = &_compassDefs[t];
 
-	_screen->drawShape(_screen->_curPage, _gameShapes[22 + _lang], 294, 3, 0, 0);
-	_screen->drawShape(_screen->_curPage, _gameShapes[(_flags.isTalkie ? 25 : 23) + c->shapeIndex], 298 + c->x, c->y + 9, 0, c->flags | 0x300, _screen->_paletteOverlay1, 1);
-	_screen->drawShape(_screen->_curPage, _gameShapes[(_flags.isTalkie ? 25 : 23)  + c->shapeIndex], 299 + c->x, c->y + 8, 0, c->flags);
+	int compassShp = 22;
+	int compassPtr = 23;
+	if (_flags.isTalkie) {
+		compassShp += _lang;
+		compassPtr = 25;
+	}
 
+	_screen->drawShape(_screen->_curPage, _gameShapes[compassShp], 294, 3, 0, 0);
+	_screen->drawShape(_screen->_curPage, _gameShapes[compassPtr + c->shapeIndex], 298 + c->x, c->y + 9, 0, c->flags | 0x300, _screen->_paletteOverlay1, 1);
+	_screen->drawShape(_screen->_curPage, _gameShapes[compassPtr + c->shapeIndex], 299 + c->x, c->y + 8, 0, c->flags);
+
 	if (!_screen->_curPage)
 		_screen->showMouse();
 }


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list