GoldenEye: Source Forums

Debriefing => Impressions & Feedback => Topic started by: Joe on April 05, 2013, 07:24:37 pm

Title: Scripting API Suggestion: Allow Sound Effects To Be Stopped
Post by: Joe on April 05, 2013, 07:24:37 pm
Hi,

DAD mode (http://forums.geshl2.com/index.php/topic,7378.0.html) will have a 5 second resurrection sound effect which will end when a resurrection has finished or when a resurrection fails.

Because I can't stop this sound when a resurrection fails, I will have to divide this sound effect up into separate sound files and then add code to my mode script which will play these sound files in the correct sequence, not playing them all if a resurrection isn't successful.

These are sound effect stopping functions which could be added to GEUtil:

StopSoundBeingPlayedFromPlayer(soundName,player) : Stop a sound played by GEUtil.PlaySoundFromPlayer()
StopSound(soundName) : Stop a sound played by GEUtil.PlaySound()
StopSoundBeingPlayedToTeam(soundName,team) : Stop a sound played by GEUtil.PlaySoundToTeam()

Title: Re: Scripting API Suggestion: Allow Sound Effects To Be Stopped
Post by: killermonkey on April 05, 2013, 10:31:05 pm
Agreed good suggestion! I'll modify the playsound functions so they return the sound id or instance so you can then stop it at a later time.
Title: Re: Scripting API Suggestion: Allow Sound Effects To Be Stopped
Post by: Joe on April 10, 2013, 12:35:10 pm
Thanks Killer Monkey.