[Scummvm-cvs-logs] SF.net SVN: scummvm:[35821] scummvm/trunk/engines/scumm

Kirben at users.sourceforge.net Kirben at users.sourceforge.net
Sun Jan 11 07:51:17 CET 2009


Revision: 35821
          http://scummvm.svn.sourceforge.net/scummvm/?rev=35821&view=rev
Author:   Kirben
Date:     2009-01-11 06:51:17 +0000 (Sun, 11 Jan 2009)

Log Message:
-----------
Fix talkspeed settings again.

Modified Paths:
--------------
    scummvm/trunk/engines/scumm/script_v8.cpp
    scummvm/trunk/engines/scumm/scumm.cpp

Modified: scummvm/trunk/engines/scumm/script_v8.cpp
===================================================================
--- scummvm/trunk/engines/scumm/script_v8.cpp	2009-01-11 06:15:30 UTC (rev 35820)
+++ scummvm/trunk/engines/scumm/script_v8.cpp	2009-01-11 06:51:17 UTC (rev 35821)
@@ -423,7 +423,12 @@
 		assertRange(0, var, _numVariables - 1, "variable (writing)");
 
 		if (var == VAR_CHARINC) {
-			if (ConfMan.hasKey("talkspeed")) {
+			// Did the user override the talkspeed manually? Then use that.
+			// Otherwise, use the value specified by the game script.
+			// Note: To determine whether there was a user override, we only
+			// look at the target specific settings, assuming that any global
+			// value is likely to be bogus. See also bug #2251765.
+			if (ConfMan.hasKey("talkspeed", _targetName)) {
 				value = getTalkDelay();
 			} else {
 				// Save the new talkspeed value to ConfMan

Modified: scummvm/trunk/engines/scumm/scumm.cpp
===================================================================
--- scummvm/trunk/engines/scumm/scumm.cpp	2009-01-11 06:15:30 UTC (rev 35820)
+++ scummvm/trunk/engines/scumm/scumm.cpp	2009-01-11 06:51:17 UTC (rev 35821)
@@ -1706,9 +1706,11 @@
 	if (VAR_VOICE_MODE != 0xFF)
 		VAR(VAR_VOICE_MODE) = _voiceMode;
 
-	_defaultTalkDelay = getTalkDelay();
-	if (VAR_CHARINC != 0xFF)
-		VAR(VAR_CHARINC) = _defaultTalkDelay;
+	if (ConfMan.hasKey("talkspeed", _targetName)) {
+		_defaultTalkDelay = getTalkDelay();
+		if (VAR_CHARINC != 0xFF)
+			VAR(VAR_CHARINC) = _defaultTalkDelay;
+	}
 }
 
 void ScummEngine::setTalkDelay(int talkdelay) {


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