Raised This Month: $51 Target: $400
 12% 

Solved [ H3LP ] Stop Entity sound


Post New Thread Reply   
 
Thread Tools Display Modes
DarthMan
Veteran Member
Join Date: Aug 2011
Old 10-11-2017 , 17:08   Re: [ H3LP ] Stop Entity sound
Reply With Quote #21

Quote:
Originally Posted by PRoSToTeM@ View Post
Try CHAN_STATIC with SND_STOP and use currently playing sound as sound name.
But then that will noly work for a specific sound. I don't want that.
DarthMan is offline
PRoSToTeM@
Veteran Member
Join Date: Jan 2010
Location: Russia, Ivanovo
Old 10-12-2017 , 14:33   Re: [ H3LP ] Stop Entity sound
Reply With Quote #22

Quote:
Originally Posted by DarthMan View Post
But then that will noly work for a specific sound. I don't want that.
You need to make an auto-detection for it's name.
__________________

Last edited by PRoSToTeM@; 10-12-2017 at 14:33.
PRoSToTeM@ is offline
Send a message via ICQ to PRoSToTeM@ Send a message via Skype™ to PRoSToTeM@
PRoSToTeM@
Veteran Member
Join Date: Jan 2010
Location: Russia, Ivanovo
Old 10-12-2017 , 21:59   Re: [ H3LP ] Stop Entity sound
Reply With Quote #23

I have good news for you: there is a way to stop all sounds on specific channel on specific entity.
Code:
StopAllSoundsOnChannel(entity, channel) {     message_begin(MSG_ALL, SVC_STOPSOUND);     write_short((entity << 3) | channel);     message_end(); }
__________________
PRoSToTeM@ is offline
Send a message via ICQ to PRoSToTeM@ Send a message via Skype™ to PRoSToTeM@
DarthMan
Veteran Member
Join Date: Aug 2011
Old 10-13-2017 , 04:01   Re: [ H3LP ] Stop Entity sound
Reply With Quote #24

Quote:
Originally Posted by PRoSToTeM@ View Post
I have good news for you: there is a way to stop all sounds on specific channel on specific entity.
Code:
StopAllSoundsOnChannel(entity, channel) {     message_begin(MSG_ALL, SVC_STOPSOUND);     write_short((entity << 3) | channel);     message_end(); }
Ty so much, I will check out today when I come back home.
DarthMan is offline
DarthMan
Veteran Member
Join Date: Aug 2011
Old 10-13-2017 , 12:51   Re: [ H3LP ] Stop Entity sound
Reply With Quote #25

Quote:
Originally Posted by PRoSToTeM@ View Post
I have good news for you: there is a way to stop all sounds on specific channel on specific entity.
Code:
StopAllSoundsOnChannel(entity, channel) {     message_begin(MSG_ALL, SVC_STOPSOUND);     write_short((entity << 3) | channel);     message_end(); }
What's the channel?
I tried StopAllSoundsOnChannel(iEnt, CHAN_AUTO); but that didn't work

Edit: It was CHAN_STATIC, it works eprfectly, thanks again

Last edited by DarthMan; 10-13-2017 at 12:53.
DarthMan is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:45.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode