QF_SILENT flag for A_QuakeEx

Remember, just because you request it, that doesn't mean you'll get it.

Moderator: GZDoom Developers

User avatar
Jekyll Grim Payne
 
 
Posts: 936
Joined: Mon Jul 21, 2008 4:08 am
Discord: Agent_Ash#4401
Github ID: jekyllgrim
Graphics Processor: nVidia (Modern GZDoom)

QF_SILENT flag for A_QuakeEx

Post by Jekyll Grim Payne »

In what I can only assume is a weird oversight, there's no way to produce a silent quake right now. Both A_Quake and A_QuakeEx occupy a sound channel, even if you pass "" or a null sound*. Since it's frequently used to add effect to enemy or weapon attacks, this is a problem (and while specifying a channel for the other sounds does work around it, this should still be a feature).


* Call A_StartSound, then A_Quake(Ex), and the previous sound will be cut off, because A_Quake(Ex) occupies CHAN_BODY.
Last edited by Jekyll Grim Payne on Mon Jun 27, 2022 10:52 am, edited 3 times in total.
User avatar
Major Cooke
Posts: 8070
Joined: Sun Jan 28, 2007 3:55 pm

Re: QF_SILENT flag for A_QuakeEx

Post by Major Cooke »

Yes you can. Just use "" for the sound parameter. Doesn't play any noise at all.
User avatar
phantombeta
Posts: 2000
Joined: Thu May 02, 2013 1:27 am
Graphics Processor: nVidia with Vulkan support

Re: QF_SILENT flag for A_QuakeEx

Post by phantombeta »

Major Cooke wrote:Yes you can. Just use "" for the sound parameter. Doesn't play any noise at all.
I think this is the issue with that:
Jekyll Grim Payne wrote:Both A_Quake and A_QuakeEx occupy a sound channel, even if you pass "" or a null sound.
User avatar
Nash
 
 
Posts: 17296
Joined: Mon Oct 27, 2003 12:07 am
Twitch ID: nashmuhandes
Github ID: nashmuhandes
Location: Kuala Lumpur, Malaysia

Re: QF_SILENT flag for A_QuakeEx

Post by Nash »

I'm re-opening this (and will send a PR soon).

It has to be a new flag, to not break old mods
User avatar
inkoalawetrust
Posts: 37
Joined: Mon Aug 26, 2019 9:18 pm
Discord: inkoalawetrust #9783
Github ID: inkoalawetrust
Graphics Processor: nVidia with Vulkan support

Re: QF_SILENT flag for A_QuakeEx

Post by inkoalawetrust »

Wouldn't making the function play an empty sound file also work, without needing any additional code ?
User avatar
KynikossDragonn
Posts: 209
Joined: Sat Dec 12, 2020 10:59 am
Twitch ID: kynikossdragonn
Github ID: KynikossDragonn
Graphics Processor: Intel (Modern GZDoom)
Location: Independence, KS, USA

Re: QF_SILENT flag for A_QuakeEx

Post by KynikossDragonn »

inkoalawetrust wrote:Wouldn't making the function play an empty sound file also work, without needing any additional code ?
You'd think but:
Jekyll Grim Payne wrote:Both A_Quake and A_QuakeEx occupy a sound channel, even if you pass "" or a null sound.
so in otherwords, it will interrupt any sound playing on the sound channel even if sound name is null.

Return to “Feature Suggestions”