[Scummvm-cvs-logs] SF.net SVN: scummvm: [29836] scummvm/trunk/engines/lure/surface.cpp

dreammaster at users.sourceforge.net dreammaster at users.sourceforge.net
Wed Dec 12 10:45:52 CET 2007


Revision: 29836
          http://scummvm.svn.sourceforge.net/scummvm/?rev=29836&view=rev
Author:   dreammaster
Date:     2007-12-12 01:45:51 -0800 (Wed, 12 Dec 2007)

Log Message:
-----------
Dynamic fix for several incorrect accented characters in the Italian version

Modified Paths:
--------------
    scummvm/trunk/engines/lure/surface.cpp

Modified: scummvm/trunk/engines/lure/surface.cpp
===================================================================
--- scummvm/trunk/engines/lure/surface.cpp	2007-12-12 08:56:34 UTC (rev 29835)
+++ scummvm/trunk/engines/lure/surface.cpp	2007-12-12 09:45:51 UTC (rev 29836)
@@ -44,10 +44,21 @@
 static uint8 fontSize[256];
 int numFontChars;
 
+const byte char8A[8] = {0x40, 0x20, 0x00, 0x90, 0x90, 0x90, 0x68, 0x00}; // accented `u
+const byte char8D[8] = {0x80, 0x40, 0x00, 0xc0, 0x40, 0x40, 0x60, 0x00}; // accented `i
+const byte char95[8] = {0x40, 0x20, 0x00, 0x60, 0x90, 0x90, 0x60, 0x00}; // accented `o
+
 void Surface::initialise() {
-	int_font = Disk::getReference().getEntry(FONT_RESOURCE_ID);
-	int_dialog_frame = Disk::getReference().getEntry(DIALOG_RESOURCE_ID);
+	Disk &disk = Disk::getReference();
+	int_font = disk.getEntry(FONT_RESOURCE_ID);
+	int_dialog_frame = disk.getEntry(DIALOG_RESOURCE_ID);
 
+	if (LureEngine::getReference().getLanguage() == IT_ITA) {
+		Common::copy(&char8A[0], &char8A[8], int_font->data() + (0x8A - 32) * 8);
+		Common::copy(&char8D[0], &char8D[8], int_font->data() + (0x8D - 32) * 8);
+		Common::copy(&char95[0], &char95[8], int_font->data() + (0x95 - 32) * 8);
+	}
+
 	numFontChars = int_font->size() / 8;
 	if (numFontChars > 256)
 		error("Font data exceeded maximum allowable size");


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