From: <sag...@us...> - 2013-06-23 21:38:16
|
Revision: 2402 http://sourceforge.net/p/modplug/code/2402 Author: saga-games Date: 2013-06-23 21:38:01 +0000 (Sun, 23 Jun 2013) Log Message: ----------- [Fix] M15 modules with "hidden" patterns in their order list didn't play properly anymore (probably since v1.22.03, affected e.g. Bad Dudes soundtrack) [Mod] OpenMPT: Version is now 1.22.03.06 Modified Paths: -------------- trunk/OpenMPT/common/versionNumber.h trunk/OpenMPT/soundlib/Load_mod.cpp Modified: trunk/OpenMPT/common/versionNumber.h =================================================================== --- trunk/OpenMPT/common/versionNumber.h 2013-06-23 06:03:07 UTC (rev 2401) +++ trunk/OpenMPT/common/versionNumber.h 2013-06-23 21:38:01 UTC (rev 2402) @@ -17,7 +17,7 @@ #define VER_MAJORMAJOR 1 #define VER_MAJOR 22 #define VER_MINOR 03 -#define VER_MINORMINOR 05 +#define VER_MINORMINOR 06 //Version string. For example "1.17.02.28" #define MPT_VERSION_STR VER_STRINGIZE(VER_MAJORMAJOR)"."VER_STRINGIZE(VER_MAJOR)"."VER_STRINGIZE(VER_MINOR)"."VER_STRINGIZE(VER_MINORMINOR) Modified: trunk/OpenMPT/soundlib/Load_mod.cpp =================================================================== --- trunk/OpenMPT/soundlib/Load_mod.cpp 2013-06-23 06:03:07 UTC (rev 2401) +++ trunk/OpenMPT/soundlib/Load_mod.cpp 2013-06-23 21:38:01 UTC (rev 2402) @@ -791,6 +791,7 @@ } InitializeGlobals(); + m_nChannels = 4; STVersions minVersion = UST1_00; @@ -858,7 +859,7 @@ PATTERNINDEX numPatterns = GetNumPatterns(file, Order, fileHeader.numOrders, totalSampleLen, m_nChannels, false); // Let's see if the file is too small (including some overhead for broken files like sll7.mod) - if(file.BytesLeft() + 4096 < numPatterns * 64u * 4u + totalSampleLen) + if(file.BytesLeft() + 32767 < numPatterns * 64u * 4u + totalSampleLen) { return false; } @@ -870,12 +871,8 @@ // Now we can be pretty sure that this is a valid Soundtracker file. Set up default song settings. m_nType = MOD_TYPE_MOD; - m_nChannels = 4; - m_nInstruments = 0; - m_nDefaultSpeed = 6; // Sample 7 in echoing.mod won't "loop" correctly if we don't convert the VBlank tempo. m_nDefaultTempo = fileHeader.restartPos * 25 / 24; - m_nRestartPos = 0; if(fileHeader.restartPos != 0x78) { // Convert to CIA timing This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |