Added A_StopSounds(int chanmin, int chanmax).

- If both channels are 0, completely silences the actor.
- Adapted A_StopAllSounds to call A_StopSounds(0,0);
This commit is contained in:
Major Cooke 2020-03-01 12:35:19 -06:00 committed by Christoph Oelckers
commit 4cf7c6351d
6 changed files with 21 additions and 10 deletions

View file

@ -142,11 +142,12 @@ DEFINE_ACTION_FUNCTION_NATIVE(AActor, A_StopSound, NativeStopSound)
return 0;
}
DEFINE_ACTION_FUNCTION_NATIVE(AActor, A_StopAllSounds, S_StopAllActorSounds)
DEFINE_ACTION_FUNCTION_NATIVE(AActor, A_StopSounds, S_StopActorSounds)
{
PARAM_SELF_PROLOGUE(AActor);
S_StopAllActorSounds(self);
PARAM_INT(chanmin);
PARAM_INT(chanmax);
S_StopActorSounds(self, chanmin, chanmax);
return 0;
}