[Scummvm-cvs-logs] SF.net SVN: scummvm:[41838] scummvm/trunk/engines/gob

drmccoy at users.sourceforge.net drmccoy at users.sourceforge.net
Wed Jun 24 23:48:27 CEST 2009


Revision: 41838
          http://scummvm.svn.sourceforge.net/scummvm/?rev=41838&view=rev
Author:   drmccoy
Date:     2009-06-24 21:48:27 +0000 (Wed, 24 Jun 2009)

Log Message:
-----------
Added the scriptEnd property

Modified Paths:
--------------
    scummvm/trunk/engines/gob/totfile.cpp
    scummvm/trunk/engines/gob/totfile.h

Modified: scummvm/trunk/engines/gob/totfile.cpp
===================================================================
--- scummvm/trunk/engines/gob/totfile.cpp	2009-06-24 21:48:13 UTC (rev 41837)
+++ scummvm/trunk/engines/gob/totfile.cpp	2009-06-24 21:48:27 UTC (rev 41838)
@@ -48,7 +48,7 @@
 	_stream = _vm->_dataIO->getDataStream(fileName.c_str());
 
 	if (!_stream)
-		// Trying to open from video video
+		// Trying to open from video
 		_stream = _vm->_vidPlayer->getExtraData(fileName.c_str());
 
 	if (!_stream)
@@ -97,6 +97,12 @@
 	for (int i = 0; i < 14; i++)
 		props.functions[i] = READ_LE_UINT16(_header + 100 + i * 2);
 
+	props.scriptEnd = _stream->size();
+	if (props.textsOffset > 0)
+		props.scriptEnd = MIN(props.scriptEnd, props.textsOffset);
+	if (props.resourcesOffset > 0)
+		props.scriptEnd = MIN(props.scriptEnd, props.resourcesOffset);
+
 	return true;
 }
 

Modified: scummvm/trunk/engines/gob/totfile.h
===================================================================
--- scummvm/trunk/engines/gob/totfile.h	2009-06-24 21:48:13 UTC (rev 41837)
+++ scummvm/trunk/engines/gob/totfile.h	2009-06-24 21:48:27 UTC (rev 41838)
@@ -52,6 +52,7 @@
 		uint8  exFileNumber;
 		uint8  communHandling;
 		uint16 functions[14];
+		uint32 scriptEnd;
 	};
 
 	TOTFile(GobEngine *vm);


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