[Scummvm-cvs-logs] scummvm master -> c5490b8ecc41eede03e5a27bc613bf262a83288d

dreammaster dreammaster at scummvm.org
Sun Jun 14 01:47:49 CEST 2015


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
c5490b8ecc SHERLOCK: SS: German and Spanish use an alternate opcode range


Commit: c5490b8ecc41eede03e5a27bc613bf262a83288d
    https://github.com/scummvm/scummvm/commit/c5490b8ecc41eede03e5a27bc613bf262a83288d
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2015-06-13T19:46:33-04:00

Commit Message:
SHERLOCK: SS: German and Spanish use an alternate opcode range

Changed paths:
    engines/sherlock/scalpel/scalpel_talk.cpp



diff --git a/engines/sherlock/scalpel/scalpel_talk.cpp b/engines/sherlock/scalpel/scalpel_talk.cpp
index 4b7a5c6..e53692c 100644
--- a/engines/sherlock/scalpel/scalpel_talk.cpp
+++ b/engines/sherlock/scalpel/scalpel_talk.cpp
@@ -156,8 +156,18 @@ ScalpelTalk::ScalpelTalk(SherlockEngine *vm) : Talk(vm) {
 		nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr, nullptr
 	};
 
-	_opcodes = SCALPEL_OPCODES;
 	_opcodeTable = OPCODE_METHODS;
+	_opcodes = SCALPEL_OPCODES;
+
+	if (vm->getLanguage() == Common::DE_DEU || vm->getLanguage() == Common::ES_ESP) {
+		// The German and Spanish versions use a different opcode range
+		static byte opcodes[sizeof(SCALPEL_OPCODES)];
+		for (int idx = 0; idx < sizeof(SCALPEL_OPCODES); ++idx)
+			opcodes[idx] = SCALPEL_OPCODES[idx] ? SCALPEL_OPCODES[idx] + 47 : 0;
+
+		_opcodes = opcodes;
+	}
+
 }
 
 void ScalpelTalk::talkInterface(const byte *&str) {






More information about the Scummvm-git-logs mailing list