[Scummvm-cvs-logs] SF.net SVN: scummvm: [20880] scummvm/trunk/engines/scumm
fingolfin at users.sourceforge.net
fingolfin at users.sourceforge.net
Sat Feb 25 10:17:06 CET 2006
Revision: 20880
Author: fingolfin
Date: 2006-02-25 10:16:24 -0800 (Sat, 25 Feb 2006)
ViewCVS: http://svn.sourceforge.net/scummvm?rev=20880&view=rev
Log Message:
-----------
Modified the workaround for bug #1407789 to not depend on MD5 detection
Modified Paths:
--------------
scummvm/trunk/engines/scumm/script.cpp
scummvm/trunk/engines/scumm/scumm.cpp
Modified: scummvm/trunk/engines/scumm/script.cpp
===================================================================
--- scummvm/trunk/engines/scumm/script.cpp 2006-02-25 17:36:32 UTC (rev 20879)
+++ scummvm/trunk/engines/scumm/script.cpp 2006-02-25 18:16:24 UTC (rev 20880)
@@ -600,6 +600,29 @@
if (!(var & 0xF000)) {
checkRange(_numVariables - 1, 0, var, "Variable %d out of range(w)");
+ if (var == VAR_SENTENCE_SCRIPT && _game.id == GID_FT && _defaultFTSentenceScript == -1) {
+ // WORKAROUND for bug #1407789. See checkAndRunSentenceScript()
+ // for the actual workaround.
+
+ // FIXME: We do not yet have all necessary information, but the
+ // following is known:
+ //
+ // * The US PC version uses scripts 28 and 103.
+ // * The French PC version uses scripts 29 and 104.
+ // * The German Mac version uses scripts 29 and 104.
+ // * The German, Italian, Portuguese and Spanish PC versions
+ // use script 29. The other script is not currently known.
+ // * The US Mac demo uses script 28.
+ //
+ // For now we assume that the very first time VAR_SENTENCE_SCRIPT
+ // is set, it is set to the default value (this happens in script 1).
+ // We furtermore assume that both scripts, if their IDs are shifted,
+ // are shifted by the same amount.
+
+ _defaultFTSentenceScript = value;
+ _buggyFTSentenceScript = 103 + (_defaultFTSentenceScript - 28);
+ }
+
if (VAR_SUBTITLES != 0xFF && var == VAR_SUBTITLES) {
// Ignore default setting in HE72-73 games
if (_game.heversion <= 73 && vm.slot[_currentScript].number == 1)
Modified: scummvm/trunk/engines/scumm/scumm.cpp
===================================================================
--- scummvm/trunk/engines/scumm/scumm.cpp 2006-02-25 17:36:32 UTC (rev 20879)
+++ scummvm/trunk/engines/scumm/scumm.cpp 2006-02-25 18:16:24 UTC (rev 20880)
@@ -1230,32 +1230,9 @@
if (!elem)
printf("Unknown MD5 (%s)! Please report the details (language, platform, etc.) of this game to the ScummVM team\n", md5str);
- if (_game.id == GID_FT) {
- // WORKAROUND for bug #1407789. See checkAndRunSentenceScript()
- // for the actual workaround.
+ _defaultFTSentenceScript = -1;
+ _buggyFTSentenceScript = -1;
- // FIXME: We do not yet have all necessary information, but the
- // following is known:
- //
- // * The US PC version uses scripts 28 and 103.
- // * The French PC version uses scripts 29 and 104.
- // * The German, Italian, Portuguese and Spanish PC versions
- // use script 29. The other script is not currently known.
- // * The US Mac demo uses script 28.
- //
- // For now, assume that the PC and Mac versions are the same,
- // that all localized versions use scripts 29 and 104, and that
- // any completely unknown version is localized.
-
- if (elem && elem->language == Common::EN_USA) {
- _defaultFTSentenceScript = 28;
- _buggyFTSentenceScript = 103;
- } else {
- _defaultFTSentenceScript = 29;
- _buggyFTSentenceScript = 104;
- }
- }
-
// Add default file directories.
if (((_game.platform == Common::kPlatformAmiga) || (_game.platform == Common::kPlatformAtariST)) && (_game.version <= 4)) {
// This is for the Amiga version of Indy3/Loom/Maniac/Zak
More information about the Scummvm-git-logs
mailing list