don't early out, *do* use case sensitive filename finding for the stringtable, and finally, don't even bother setting the mSoundpath here unless it's to clear it

This commit is contained in:
AzaezelX 2024-02-05 18:41:07 -06:00
parent ef858d726b
commit cea641b154

View file

@ -447,15 +447,10 @@ bool SoundAsset::_setSoundFile(void* object, const char* index, const char* data
if (index)
id = dAtoui(index);
if (pData->mSoundFile[id] == data)
return false;
// Update.
pData->mSoundFile[id] = data;
pData->mSoundFile[id] = StringTable->insert(data, true);
if (pData->mSoundFile[id] == StringTable->EmptyString())
pData->mSoundPath[id] = StringTable->EmptyString();
else
pData->mSoundPath[id] = pData->getOwned() ? pData->expandAssetFilePath(pData->mSoundFile[id]) : pData->mSoundFile[id];
// Refresh the asset.
pData->refreshAsset();