This commit is contained in:
BrainFart17 2026-04-06 16:43:31 -07:00
commit 07ec2e93ee
2 changed files with 10 additions and 2 deletions

View file

@ -170,6 +170,14 @@ bool DLCAudioFile::processDLCDataFile(PBYTE pbData, DWORD dwLength)
for(unsigned int i=0;i<uiFileCount;i++)
{
EAudioType type = static_cast<EAudioType>(pFile->dwType);
//Bounds Checking
if (type < 0 || type >= e_AudioType_Max)
{
app.DebugPrintf("Error parser: EAudioType (%d) out of bounds!\n", type);
continue;
}
// Params
unsigned int uiParameterCount=*(unsigned int *)pbTemp;
pbTemp+=sizeof(int);
@ -182,7 +190,8 @@ bool DLCAudioFile::processDLCDataFile(PBYTE pbData, DWORD dwLength)
if(it != parameterMapping.end() )
{
addParameter(type,static_cast<EAudioParameterType>(pParams->dwType),(WCHAR *)pParams->wchData);
//addParameter(type,static_cast<EAudioParameterType>(pParams->dwType),(WCHAR *)pParams->wchData);
addParameter(type, it->second, (WCHAR *)pParams->wchData);
}
pbTemp+=sizeof(C4JStorage::DLC_FILE_PARAM)+(sizeof(WCHAR)*pParams->dwWchCount);
pParams = (C4JStorage::DLC_FILE_PARAM *)pbTemp;

View file

@ -25,7 +25,6 @@ Huge thanks to the following projects:
- [Legacy Minigame Restoration Project](https://discord.gg/bg2kmbzFzv) - for their immense help with our project's deep decompilation work
- [Patoke/LCERenewed](https://github.com/Patoke/LCERenewed) - for some of the patches that required deep decompilation
- [smartcmd/MinecraftConsoles](https://github.com/smartcmd/MinecraftConsoles) - for creating such a great repo
# Build & Run