[Scummvm-cvs-logs] SF.net SVN: scummvm:[34047] scummvm/trunk/engines/parallaction

peres001 at users.sourceforge.net peres001 at users.sourceforge.net
Wed Aug 20 06:02:13 CEST 2008


Revision: 34047
          http://scummvm.svn.sourceforge.net/scummvm/?rev=34047&view=rev
Author:   peres001
Date:     2008-08-20 04:02:12 +0000 (Wed, 20 Aug 2008)

Log Message:
-----------
Engine now returns to the menu when intro is over.

Modified Paths:
--------------
    scummvm/trunk/engines/parallaction/gui_br.cpp
    scummvm/trunk/engines/parallaction/parallaction.h
    scummvm/trunk/engines/parallaction/parallaction_br.cpp

Modified: scummvm/trunk/engines/parallaction/gui_br.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/gui_br.cpp	2008-08-20 03:36:49 UTC (rev 34046)
+++ scummvm/trunk/engines/parallaction/gui_br.cpp	2008-08-20 04:02:12 UTC (rev 34047)
@@ -264,29 +264,24 @@
 
 
 
-void Parallaction_br::startGui() {
+void Parallaction_br::startGui(bool showSplash) {
 	_menuHelper = new MenuInputHelper;
-	new SplashInputState0_BR(this, _menuHelper);
-	new SplashInputState1_BR(this, _menuHelper);
+
 	new MainMenuInputState_BR(this, _menuHelper);
 
-	_menuHelper->setState("intro0");
-	_input->_inputMode = Input::kInputModeMenu;
+	if (showSplash) {
+		new SplashInputState0_BR(this, _menuHelper);
+		new SplashInputState1_BR(this, _menuHelper);
+		_menuHelper->setState("intro0");
+	} else {
+		_menuHelper->setState("mainmenu");
+	}
 
-	do {
-		_input->readInput();
-		if (!_menuHelper->run()) break;
-		_gfx->beginFrame();
-		_gfx->updateScreen();
-	} while (true);
-
-	delete _menuHelper;
-	_menuHelper = 0;
-
-	_input->_inputMode = Input::kInputModeGame;
+	_input->_inputMode = Input::kInputModeMenu;
 }
 
 
 
+
 } // namespace Parallaction
 

Modified: scummvm/trunk/engines/parallaction/parallaction.h
===================================================================
--- scummvm/trunk/engines/parallaction/parallaction.h	2008-08-20 03:36:49 UTC (rev 34046)
+++ scummvm/trunk/engines/parallaction/parallaction.h	2008-08-20 04:02:12 UTC (rev 34047)
@@ -667,7 +667,7 @@
 
 	static const char *_partNames[];
 
-	void startGui();
+	void startGui(bool showSplash);
 
 	static const Callable _dosCallables[6];
 

Modified: scummvm/trunk/engines/parallaction/parallaction_br.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/parallaction_br.cpp	2008-08-20 03:36:49 UTC (rev 34046)
+++ scummvm/trunk/engines/parallaction/parallaction_br.cpp	2008-08-20 04:02:12 UTC (rev 34047)
@@ -133,17 +133,21 @@
 
 int Parallaction_br::go() {
 
-	if (getFeatures() & GF_DEMO) {
-		startPart(1);
-	} else {
-		startGui();
-	}
+	bool splash = true;
 
 	while ((_engineFlags & kEngineQuit) == 0) {
 
+		if (getFeatures() & GF_DEMO) {
+			startPart(1);
+			_input->_inputMode = Input::kInputModeGame;
+		} else {
+			startGui(splash);
+			 // don't show splash after first time
+			splash = false;
+		}
+
 //		initCharacter();
 
-		_input->_inputMode = Input::kInputModeGame;
 		while ((_engineFlags & (kEngineReturn | kEngineQuit)) == 0) {
 			runGame();
 		}
@@ -151,7 +155,6 @@
 
 		freePart();
 //		freeCharacter();
-
 	}
 
 	return 0;


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