Add patch:

1367403 - Korean Fixes

svn-id: r19718
This commit is contained in:
Travis Howell 2005-11-27 10:32:21 +00:00
parent ee69f9317d
commit 8c45a9a3c0
2 changed files with 13 additions and 10 deletions

View File

@ -156,7 +156,7 @@ static int SJIStoFMTChunk(int f, int s) { //converts sjis code to fmt font offse
else if (kanjiType == EKANJI) chunk = 144;
break;
default:
error("Invalid Char! f %x s %x base %x c %d p %d", f, s, base, c, p);
debug(4, "Invalid Char! f %x s %x base %x c %d p %d", f, s, base, c, p);
return 0;
}

View File

@ -455,15 +455,7 @@ void ScummEngine::CHARSET_1() {
_charset->_left = _charset->_nextLeft;
_charset->_top = _charset->_nextTop;
if (c & 0x80 && _useCJKMode) {
if (_language == Common::JA_JPN && !checkSJISCode(c)) {
c = 0x20; //not in S-JIS
} else {
byte *buffer = _charsetBuffer + _charsetBufPos;
c += *buffer++ * 256; //LE
_charsetBufPos = buffer - _charsetBuffer;
}
}
if (_version >= 7) {
#ifndef DISABLE_SCUMM_7_8
if (subtitleLine == subtitleBuffer) {
@ -474,6 +466,15 @@ void ScummEngine::CHARSET_1() {
*subtitleLine = '\0';
#endif
} else {
if (c & 0x80 && _useCJKMode) {
if (_language == Common::JA_JPN && !checkSJISCode(c)) {
c = 0x20; //not in S-JIS
} else {
byte *buffer = _charsetBuffer + _charsetBufPos;
c += *buffer++ * 256; //LE
_charsetBufPos = buffer - _charsetBuffer;
}
}
if (_version <= 3) {
_charset->printChar(c);
} else {
@ -988,6 +989,8 @@ void ScummEngine_v7::loadLanguageBundle() {
for (i = 0; i < lineCount; i++) {
if (*ptr == '!') {
// Don't know what a line with '!' means, just ignore it
} else if (*ptr == 'h') {
// File contains Korean text (Hangul). just ignore it
} else if (*ptr == 'e') {
// File is encoded!
enc = 0x13;