[Scummvm-cvs-logs] SF.net SVN: scummvm:[42658] scummvm/trunk/engines/agi/agi.cpp

sev at users.sourceforge.net sev at users.sourceforge.net
Wed Jul 22 13:48:51 CEST 2009


Revision: 42658
          http://scummvm.svn.sourceforge.net/scummvm/?rev=42658&view=rev
Author:   sev
Date:     2009-07-22 11:48:51 +0000 (Wed, 22 Jul 2009)

Log Message:
-----------
Fix bug #2823762: "AGI: PQ1 All function keys are broken after restart"

Modified Paths:
--------------
    scummvm/trunk/engines/agi/agi.cpp

Modified: scummvm/trunk/engines/agi/agi.cpp
===================================================================
--- scummvm/trunk/engines/agi/agi.cpp	2009-07-22 11:30:57 UTC (rev 42657)
+++ scummvm/trunk/engines/agi/agi.cpp	2009-07-22 11:48:51 UTC (rev 42658)
@@ -489,11 +489,6 @@
 
 	_game.mouseFence.setWidth(0); // Reset
 
-	_game.lastController = 0;
-	for (i = 0; i < MAX_DIRS; i++)
-		_game.controllerOccured[i] = false;
-
-
 	return ec;
 }
 
@@ -718,6 +713,12 @@
 	_predictiveDictLine = NULL;
 	_predictiveDictLineCount = 0;
 	_firstSlot = 0;
+
+	// NOTE: On game reload the keys do not get set again,
+	// thus it is incorrect to reset it in agiInit(). Fixes bug #2823762
+	_game.lastController = 0;
+	for (int i = 0; i < MAX_DIRS; i++)
+		_game.controllerOccured[i] = false;
 }
 
 void AgiEngine::initialize() {


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