[Scummvm-cvs-logs] SF.net SVN: scummvm:[52961] scummvm/trunk/tools/skycpt

tdhs at users.sourceforge.net tdhs at users.sourceforge.net
Fri Oct 1 00:45:25 CEST 2010


Revision: 52961
          http://scummvm.svn.sourceforge.net/scummvm/?rev=52961&view=rev
Author:   tdhs
Date:     2010-09-30 22:45:24 +0000 (Thu, 30 Sep 2010)

Log Message:
-----------
TOOLS: Added engine patch for use with skycpt and updated skycpt README

This patch removes the description for required code modification to sky engine for generation of RESET.* files from the README and places it into a patch file. This patch also adds two modifications which are required to get RESET.* with current codebase not mentioned in the README.

Modified Paths:
--------------
    scummvm/trunk/tools/skycpt/README

Added Paths:
-----------
    scummvm/trunk/tools/skycpt/skycpt-engine.patch

Modified: scummvm/trunk/tools/skycpt/README
===================================================================
--- scummvm/trunk/tools/skycpt/README	2010-09-30 22:22:05 UTC (rev 52960)
+++ scummvm/trunk/tools/skycpt/README	2010-09-30 22:45:24 UTC (rev 52961)
@@ -32,12 +32,17 @@
 	v.0.00365: CD Demo
 	v.0.00368: Full CD version
 	v.0.00372: Final CD version
-4) Change scummvm/sky/logic.cpp, function fnSkipIntroCode
-	so that it calls _skyControl->doLoadSavePanel()
+4) Apply the supplied skycpt-engine.patch to a clean copy of the ScummVM
+   codebase. This modifies the sky engine to allow savefiles to be generated
+   containing the required data for the skycpt tool.
 5) Compile the patched ScummVM.
-6) Start each of the BASS versions, enjoy the intro over and over again.
+6) Start each of the BASS versions with this patched version, enjoy the intro 
+   over and over again.
 	Afterwards, it'll automatically show the load/save dialog where you save the game.
-7) Rename the Savegame files you created to "RESET.*", depending on the version.
+	Except for Demo (v0.00356) which lacks the dialog, so this will autosave to slot 1
+	at the end of the intro.
+7) Rename the Savegame files you created (SKY-VM.000 etc., not the ASD or SAV 
+   file) to "RESET.*", depending on the version.
 	e.g. RESET.288 for v.0.00288
 8) Rename each file with a ".gz" suffix and run gunzip on it.
    This removes the ScummVM gzip savefile compression.

Added: scummvm/trunk/tools/skycpt/skycpt-engine.patch
===================================================================
--- scummvm/trunk/tools/skycpt/skycpt-engine.patch	                        (rev 0)
+++ scummvm/trunk/tools/skycpt/skycpt-engine.patch	2010-09-30 22:45:24 UTC (rev 52961)
@@ -0,0 +1,54 @@
+Index: engines/sky/compact.cpp
+===================================================================
+--- engines/sky/compact.cpp	(revision 52957)
++++ engines/sky/compact.cpp	(working copy)
+@@ -138,11 +138,15 @@
+ 	if (fileVersion != 0)
+ 		error("unknown \"sky.cpt\" version");
+ 
++#if 0
++	// Disabled as sky.cpt / compact.dbg used during RESET.* generation is
++	// a different size from expected.
+ 	if (SKY_CPT_SIZE != _cptFile->size()) {
+ 		GUI::MessageDialog dialog("The \"sky.cpt\" file has an incorrect size.\nPlease (re)download it from www.scummvm.org", "OK", NULL);
+ 		dialog.runModal();
+ 		error("Incorrect sky.cpt size (%d, expected: %d)", _cptFile->size(), SKY_CPT_SIZE);
+ 	}
++#endif
+ 
+ 	// set the necessary data structs up...
+ 	_numDataLists = _cptFile->readUint16LE();
+Index: engines/sky/control.cpp
+===================================================================
+--- engines/sky/control.cpp	(revision 52957)
++++ engines/sky/control.cpp	(working copy)
+@@ -432,7 +432,8 @@
+ 	_lastButton = -1;
+ 	_curButtonText = 0;
+ 
+-	saveRestorePanel(false);
++	// Parameter modified to true to ensure save dialog, not load is shown
++	saveRestorePanel(true);
+ 
+ 	memset(_screenBuf, 0, GAME_SCREEN_WIDTH * FULL_SCREEN_HEIGHT);
+ 	_system->copyRectToScreen(_screenBuf, GAME_SCREEN_WIDTH, 0, 0, GAME_SCREEN_WIDTH, FULL_SCREEN_HEIGHT);
+Index: engines/sky/logic.cpp
+===================================================================
+--- engines/sky/logic.cpp	(revision 52957)
++++ engines/sky/logic.cpp	(working copy)
+@@ -2376,6 +2376,15 @@
+ 
+ bool Logic::fnSkipIntroCode(uint32 a, uint32 b, uint32 c) {
+ 	SkyEngine::_systemVars.pastIntro = true;
++	
++	// Demo (v0.0365) lacks Save/Load Panel resources, so
++	// automatically save to Slot 1, rather than displaying dialog
++	if (SkyEngine::isDemo()) {
++		_skyControl->_selectedGame = 1;
++		_skyControl->saveGameToFile();
++	} else {
++		_skyControl->doLoadSavePanel();
++	}
+ 	return true;
+ }
+ 


Property changes on: scummvm/trunk/tools/skycpt/skycpt-engine.patch
___________________________________________________________________
Added: svn:mime-type
   + text/plain
Added: svn:keywords
   + 
Added: svn:eol-style
   + native


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