[Scummvm-cvs-logs] SF.net SVN: scummvm:[50490] scummvm/trunk/engines/m4

dreammaster at users.sourceforge.net dreammaster at users.sourceforge.net
Tue Jun 29 13:09:34 CEST 2010


Revision: 50490
          http://scummvm.svn.sourceforge.net/scummvm/?rev=50490&view=rev
Author:   dreammaster
Date:     2010-06-29 11:09:33 +0000 (Tue, 29 Jun 2010)

Log Message:
-----------
Added loading of the correct DSR file at the start of each animation scene

Modified Paths:
--------------
    scummvm/trunk/engines/m4/animation.cpp
    scummvm/trunk/engines/m4/animation.h

Modified: scummvm/trunk/engines/m4/animation.cpp
===================================================================
--- scummvm/trunk/engines/m4/animation.cpp	2010-06-29 10:52:59 UTC (rev 50489)
+++ scummvm/trunk/engines/m4/animation.cpp	2010-06-29 11:09:33 UTC (rev 50490)
@@ -118,9 +118,13 @@
 	buffer[FILENAME_SIZE] = '\0';
 	_soundName = Common::String(buffer);
 
-	animStream->skip(26);
+	animStream->skip(13);
 	animStream->read(buffer, FILENAME_SIZE);
 	buffer[FILENAME_SIZE] = '\0';
+	_dsrName = Common::String(buffer);
+
+	animStream->read(buffer, FILENAME_SIZE);
+	buffer[FILENAME_SIZE] = '\0';
 	Common::String fontResource(buffer);
 
 	if (_animMode == 4)
@@ -220,6 +224,10 @@
 			warning("Attempted to set a font with an empty name");
 	}
 
+	// If a speech file is specified, then load it
+	if (!_dsrName.empty())
+		_vm->_sound->loadDSRFile(_dsrName.c_str());
+
 	// Load all the sprite sets for the animation
 	for (int i = 0; i < spriteListCount; ++i) {
 		if (_field12 && (i == _spriteListIndex))

Modified: scummvm/trunk/engines/m4/animation.h
===================================================================
--- scummvm/trunk/engines/m4/animation.h	2010-06-29 10:52:59 UTC (rev 50489)
+++ scummvm/trunk/engines/m4/animation.h	2010-06-29 11:09:33 UTC (rev 50490)
@@ -90,6 +90,7 @@
 	Common::String _lbmFilename;
 	Common::String _spritesFilename;
 	Common::String _soundName;
+	Common::String _dsrName;
 	Common::Array<int> _spriteListIndexes;
 
 	int _currentFrame, _oldFrameEntry;


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