From e34eadf3cdf4b77bea8857ef796558f5b83bb8e3 Mon Sep 17 00:00:00 2001 From: louis <35883445+louist103@users.noreply.github.com> Date: Tue, 30 Apr 2024 20:50:22 -0400 Subject: [PATCH] fix it again --- ZAPD/ZAudio.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ZAPD/ZAudio.cpp b/ZAPD/ZAudio.cpp index 8c72cdd..3e61eda 100644 --- a/ZAPD/ZAudio.cpp +++ b/ZAPD/ZAudio.cpp @@ -229,7 +229,7 @@ void ZAudio::ParseSoundFont(std::vector codeData, std::vector int currentOffset = BitConverter::ToInt32BE(codeData, ptr) + ptr; for (int i = 0; i < numDrums; i++) { - DrumEntry drum; + DrumEntry drum = {0}; int samplePtr = BitConverter::ToInt32BE(codeData, currentOffset); @@ -245,8 +245,8 @@ void ZAudio::ParseSoundFont(std::vector codeData, std::vector drum.loaded = codeData[samplePtr + 2]; drum.tuning = BitConverter::ToFloatBE(codeData, samplePtr + 8); drum.env = ParseEnvelopeData(codeData, audioTable, BitConverter::ToInt32BE(codeData, samplePtr + 12) + ptr, ptr); - entry.drums.push_back(drum); } + entry.drums.push_back(drum); currentOffset += 4;