Fixed modplay volume ramping terminating normal voices when something sets the volume to zero
parent
dcf97c1ede
commit
d3ba707339
|
@ -2800,7 +2800,7 @@ static void voiceSetVolume(PLAYER *p, uint8_t i, float vol, uint8_t sharp)
|
|||
{
|
||||
if (vol)
|
||||
p->voice[i].volume = 0;
|
||||
else if (sharp != 3)
|
||||
else if (i > 127)
|
||||
p->voice[i].rampTerminates = 1;
|
||||
}
|
||||
|
||||
|
|
|
@ -2830,7 +2830,7 @@ void voiceSetVolume(PLAYER *p, uint8_t voiceNumber, float volume, uint8_t sharp)
|
|||
{
|
||||
if (volume)
|
||||
p->voice[voiceNumber].volume = 0.0f;
|
||||
else if (sharp != 3)
|
||||
else if (voiceNumber > 31)
|
||||
p->voice[voiceNumber].rampTerminates = 1;
|
||||
}
|
||||
p->voice[voiceNumber].targetVol = volume;
|
||||
|
|
Loading…
Reference in New Issue