[Added] A_StopAllSounds

Moderator: GZDoom Developers

A_StopAllSounds

Postby Major Cooke » Sat Jan 18, 2020 11:15 am

Pull Request

And a test sample:
Code: Select allExpand view
Class z : Actor
{
   Default
   {
      Radius 13;
      Height 8;
      Speed 25;
      Damage 5;
      Projectile;
      +RANDOMIZE
      +ZDOOMTRANS
      +BRIGHT
      RenderStyle "Add";
      Alpha 0.75;
      Obituary "$OB_MPPLASMARIFLE";
   }
   States
   {
   Spawn:
      PLSS A 6 A_StartSound("weapons/plasmaf", 8);
      PLSS B 6 A_StartSound("weapons/plasmaf", 9);
      Loop;
   Death:
      PLSE A 4
      {
         A_StopAllSounds();
         A_StartSound("weapons/plasmax");
      }
      PLSE ABCDE 4;
      Stop;
   }
}
Last edited by Major Cooke on Sat Feb 29, 2020 12:14 pm, edited 1 time in total.
User avatar
Major Cooke
QZDoom Maintenance Team
 
Joined: 28 Jan 2007

Re: A_StopAllSounds

Postby Marisa Kirisame » Sun Jan 19, 2020 5:00 am

I would appreciate this too.
User avatar
Marisa Kirisame
ZScript Crimester
 
 
 
Joined: 08 Feb 2008
Location: Vigo, Galicia
Discord: 霧雨魔理沙#1666
Twitch ID: magusmarisa
Github ID: OrdinaryMagician
Operating System: Other Linux 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: A_StopAllScreeching

Postby Uni-000 » Tue Jan 21, 2020 8:15 pm

Mmm, tasty Idea, I think this would do!
User avatar
Uni-000
Banned User
 
Joined: 01 Apr 2017
Discord: Uni#4057

Re: A_StopAllSounds

Postby Matt » Thu Jan 23, 2020 5:35 pm

Related request: IsActorPlayingAnySound()
User avatar
Matt
Putting the XD into *xdeath since 2007
 
Joined: 04 Jan 2004
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia

Re: A_StopAllSounds

Postby Uni-000 » Fri Jan 24, 2020 11:19 am

Matt wrote:Related request: IsActorPlayingAnySound()


Could be useful for TItlemaps. +1
User avatar
Uni-000
Banned User
 
Joined: 01 Apr 2017
Discord: Uni#4057

Re: A_StopAllSounds

Postby Major Cooke » Sun Jan 26, 2020 4:01 pm

Matt, you should make a new thread for it.
User avatar
Major Cooke
QZDoom Maintenance Team
 
Joined: 28 Jan 2007

Re: A_StopAllSounds

Postby Graf Zahl » Mon Jan 27, 2020 1:08 am

Matt wrote:Related request: IsActorPlayingAnySound()



Can already be done by passing 0 for the channel and sound id to the existing check functions.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: A_StopAllSounds

Postby Matt » Mon Jan 27, 2020 1:58 am

Sweet, that would've been exactly what I would've suggested had it not already been the case!
User avatar
Matt
Putting the XD into *xdeath since 2007
 
Joined: 04 Jan 2004
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia

Re: A_StopAllSounds

Postby Major Cooke » Sat Feb 29, 2020 12:12 pm

User avatar
Major Cooke
QZDoom Maintenance Team
 
Joined: 28 Jan 2007


Return to Closed Feature Suggestions

Who is online

Users browsing this forum: No registered users and 1 guest