[Scummvm-cvs-logs] SF.net SVN: scummvm:[51459] scummvm/trunk/engines/sci

m_kiewitz at users.sourceforge.net m_kiewitz at users.sourceforge.net
Thu Jul 29 12:48:54 CEST 2010


Revision: 51459
          http://scummvm.svn.sourceforge.net/scummvm/?rev=51459&view=rev
Author:   m_kiewitz
Date:     2010-07-29 10:48:54 +0000 (Thu, 29 Jul 2010)

Log Message:
-----------
SCI: updating screen within kAnimate as well - fixes pseudo hang in eq1 credits (bug #3036154)

Modified Paths:
--------------
    scummvm/trunk/engines/sci/event.cpp
    scummvm/trunk/engines/sci/event.h
    scummvm/trunk/engines/sci/graphics/animate.cpp

Modified: scummvm/trunk/engines/sci/event.cpp
===================================================================
--- scummvm/trunk/engines/sci/event.cpp	2010-07-29 09:08:20 UTC (rev 51458)
+++ scummvm/trunk/engines/sci/event.cpp	2010-07-29 10:48:54 UTC (rev 51459)
@@ -343,17 +343,21 @@
 	return input;
 }
 
-SciEvent EventManager::getSciEvent(unsigned int mask) {
-	//sci_event_t error_event = { SCI_EVT_ERROR, 0, 0, 0 };
-	SciEvent event = { 0, 0, 0, 0 };
-
+void EventManager::updateScreen() {
 	// Update the screen here, since it's called very often.
 	// Throttle the screen update rate to 60fps.
 	if (g_system->getMillis() - g_sci->getEngineState()->_screenUpdateTime >= 1000 / 60) {
 		g_system->updateScreen();
 		g_sci->getEngineState()->_screenUpdateTime = g_system->getMillis();
 	}
+}
 
+SciEvent EventManager::getSciEvent(unsigned int mask) {
+	//sci_event_t error_event = { SCI_EVT_ERROR, 0, 0, 0 };
+	SciEvent event = { 0, 0, 0, 0 };
+
+	EventManager::updateScreen();
+
 	// Get all queued events from graphics driver
 	do {
 		event = getScummVMEvent();

Modified: scummvm/trunk/engines/sci/event.h
===================================================================
--- scummvm/trunk/engines/sci/event.h	2010-07-29 09:08:20 UTC (rev 51458)
+++ scummvm/trunk/engines/sci/event.h	2010-07-29 10:48:54 UTC (rev 51459)
@@ -114,6 +114,7 @@
 	EventManager(bool fontIsExtended);
 	~EventManager();
 
+	void updateScreen();
 	SciEvent getSciEvent(unsigned int mask);
 	bool getUsesNewKeyboardDirectionType();
 

Modified: scummvm/trunk/engines/sci/graphics/animate.cpp
===================================================================
--- scummvm/trunk/engines/sci/graphics/animate.cpp	2010-07-29 09:08:20 UTC (rev 51458)
+++ scummvm/trunk/engines/sci/graphics/animate.cpp	2010-07-29 10:48:54 UTC (rev 51459)
@@ -28,6 +28,7 @@
 #include "graphics/primitives.h"
 
 #include "sci/sci.h"
+#include "sci/event.h"
 #include "sci/engine/kernel.h"
 #include "sci/engine/state.h"
 #include "sci/engine/selector.h"
@@ -597,6 +598,10 @@
 	if (_lastCastData.size() > 1)
 		_s->_throttleTrigger = true;
 
+	// We update the screen here as well, some scenes like EQ1 credits run w/o calling kGetEvent thus we wouldn't update
+	//  screen at all
+	g_sci->getEventManager()->updateScreen();
+
 	_ports->setPort(oldPort);
 }
 


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