[Scummvm-cvs-logs] SF.net SVN: scummvm: [30654] scummvm/trunk/engines/kyra

lordhoto at users.sourceforge.net lordhoto at users.sourceforge.net
Sun Jan 27 16:53:09 CET 2008


Revision: 30654
          http://scummvm.svn.sourceforge.net/scummvm/?rev=30654&view=rev
Author:   lordhoto
Date:     2008-01-27 07:53:09 -0800 (Sun, 27 Jan 2008)

Log Message:
-----------
Fix for some problems introduced (like wrong text display) with last commit.

Modified Paths:
--------------
    scummvm/trunk/engines/kyra/kyra.cpp
    scummvm/trunk/engines/kyra/kyra_v1.cpp
    scummvm/trunk/engines/kyra/kyra_v2.cpp
    scummvm/trunk/engines/kyra/script_v2.cpp
    scummvm/trunk/engines/kyra/text_v2.cpp

Modified: scummvm/trunk/engines/kyra/kyra.cpp
===================================================================
--- scummvm/trunk/engines/kyra/kyra.cpp	2008-01-27 15:30:53 UTC (rev 30653)
+++ scummvm/trunk/engines/kyra/kyra.cpp	2008-01-27 15:53:09 UTC (rev 30654)
@@ -79,6 +79,8 @@
 }
 
 int KyraEngine::init() {
+	registerDefaultSettings();
+
 	// Setup mixer
 	if (!_mixer->isReady())
 		warning("Sound initialization failed.");

Modified: scummvm/trunk/engines/kyra/kyra_v1.cpp
===================================================================
--- scummvm/trunk/engines/kyra/kyra_v1.cpp	2008-01-27 15:30:53 UTC (rev 30653)
+++ scummvm/trunk/engines/kyra/kyra_v1.cpp	2008-01-27 15:53:09 UTC (rev 30654)
@@ -264,7 +264,6 @@
 	assert(_movFacingTable);
 	_movFacingTable[0] = 8;
 
-	registerDefaultSettings();
 	readSettings();
 
 	_skipFlag = false;

Modified: scummvm/trunk/engines/kyra/kyra_v2.cpp
===================================================================
--- scummvm/trunk/engines/kyra/kyra_v2.cpp	2008-01-27 15:30:53 UTC (rev 30653)
+++ scummvm/trunk/engines/kyra/kyra_v2.cpp	2008-01-27 15:53:09 UTC (rev 30654)
@@ -131,6 +131,8 @@
 
 	setupTimers();
 
+	readSettings();
+
 	_screen->loadFont(_screen->FID_6_FNT, "6.FNT");
 	_screen->loadFont(_screen->FID_8_FNT, "8FAT.FNT");
 	_screen->loadFont(_screen->FID_GOLDFONT_FNT, "GOLDFONT.FNT");
@@ -524,7 +526,7 @@
 	restorePage3();
 	drawAnimObjects();
 
-	if (1/*textEnabled()*/ && _chatText) {
+	if (textEnabled() && _chatText) {
 		int pageBackUp = _screen->_curPage;
 		_screen->_curPage = 2;
 		objectChatPrintText(_chatText, _chatObject);

Modified: scummvm/trunk/engines/kyra/script_v2.cpp
===================================================================
--- scummvm/trunk/engines/kyra/script_v2.cpp	2008-01-27 15:30:53 UTC (rev 30653)
+++ scummvm/trunk/engines/kyra/script_v2.cpp	2008-01-27 15:53:09 UTC (rev 30654)
@@ -760,7 +760,7 @@
 
 int KyraEngine_v2::o2_isVoiceEnabled(ScriptState *script) {
 	debugC(3, kDebugLevelScriptFuncs, "o2_isVoiceEnabled(%p) ()", (const void *)script);
-	return 1/*voiceEnabled()*/;
+	return speechEnabled() ? 1 : 0;
 }
 
 int KyraEngine_v2::o2_isVoicePlaying(ScriptState *script) {

Modified: scummvm/trunk/engines/kyra/text_v2.cpp
===================================================================
--- scummvm/trunk/engines/kyra/text_v2.cpp	2008-01-27 15:30:53 UTC (rev 30653)
+++ scummvm/trunk/engines/kyra/text_v2.cpp	2008-01-27 15:53:09 UTC (rev 30654)
@@ -126,7 +126,7 @@
 }
 
 int KyraEngine_v2::chatCalcDuration(const char *str) {
-	return MIN<int>(strlen(str) << 3, 120);
+	return MAX<int>(strlen(str) << 3, 120);
 }
 
 void KyraEngine_v2::objectChat(const char *str, int object, int vocHigh, int vocLow) {


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