aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Kiewitz2015-08-07 22:00:42 +0200
committerMartin Kiewitz2015-08-07 22:00:42 +0200
commitd6347269eba08d0f7ad717df043a84b95e6836b0 (patch)
tree78ca40ee52a77437f6a997dcc635251cb8352141
parent2696be83c04ddb5042091a2c52db9ed9f4a4e439 (diff)
downloadscummvm-rg350-d6347269eba08d0f7ad717df043a84b95e6836b0.tar.gz
scummvm-rg350-d6347269eba08d0f7ad717df043a84b95e6836b0.tar.bz2
scummvm-rg350-d6347269eba08d0f7ad717df043a84b95e6836b0.zip
SHERLOCK: RT: impl. font-char mapping / bug #6882
Rose Tattoo did different font char mapping for at least the German version of the game (can't verify anything else). RT seems to map 0xE1 only, but to a different character and other upper characters (>= 0x80) are not mapped at all. this fixes broken special characters in RT.
-rw-r--r--engines/sherlock/fonts.cpp23
1 files changed, 15 insertions, 8 deletions
diff --git a/engines/sherlock/fonts.cpp b/engines/sherlock/fonts.cpp
index 440e31915c..482e795b6d 100644
--- a/engines/sherlock/fonts.cpp
+++ b/engines/sherlock/fonts.cpp
@@ -109,16 +109,23 @@ inline byte Fonts::translateChar(byte c) {
return 0; // translate to first actual character
case 225:
// This was done in the German interpreter
- // happens when talking to the kid in the 2nd room
- return 135; // special handling for 0xE1
+ // SH1: happens, when talking to the kid in the 2nd room
+ // SH2: happens, when looking at the newspaper right at the start in the backalley
+ // Special handling for 0xE1 (German Sharp-S character)
+ if (IS_ROSE_TATTOO) {
+ return 136; // it got translated to this for SH2
+ }
+ return 135; // and this for SH1
default:
- if (c >= 0x80) { // German SH1 version did this
- c--;
+ if (IS_SERRATED_SCALPEL) {
+ if (c >= 0x80) { // German SH1 version did this, but not German SH2
+ c--;
+ }
+ // Spanish SH1 did this (reverse engineered code)
+ //if ((c >= 0xA0) && (c <= 0xAD) || (c == 0x82)) {
+ // c--;
+ //}
}
- // Spanish SH1 did this (reverse engineered code)
- //if ((c >= 0xA0) && (c <= 0xAD) || (c == 0x82)) {
- // c--;
- //}
assert(c > 32); // anything above space is allowed
return c - 33;
}