Raised This Month: $ Target: $400
 0% 

emit_sound not working?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
PyRo
Member
Join Date: Mar 2005
Old 05-31-2005 , 10:56   emit_sound not working?
Reply With Quote #1

Here's a very simple test I was trying

Code:
public voice_exterminate(id) {
	if (is_user_connected(id) && is_user_alive(id) && !is_user_bot(id) && !is_user_hltv(id)) {
		emit_sound(id,CHAN_VOICE, "misc/exterminate.wav", 1.0, ATTN_NORM, 0, PITCH_NORM)
	}
	return PLUGIN_HANDLED
}


public plugin_init() {
	register_plugin("blah", "blah", "blah")
	register_clcmd("voice_exterminate","voice_exterminate")
	precache_sound("misc/exterminate.wav")
	return PLUGIN_CONTINUE
}
When I try voice_exterminate in game nothing happens when I think it should play misc/exterminate.wav
The wav file is 92.6kb, 352kbps, 16bit, mono and 22khz and it plays fine via the spk command.

Any idea what I'm doing wrong?

Pyro
__________________
85.133.16.45:27035 - [CPP] Clan Server #1 (fun Maps)
85.133.16.48:27195 - [CPP] Clan Server #2 (Standard/Custom/Fun Maps)
PyRo is offline
LynX
Veteran Member
Join Date: Oct 2004
Old 05-31-2005 , 11:40  
Reply With Quote #2

errrrmmmm... maybe do precache_sound in public plugin_precache()
__________________
Current plugin : SoulPunisher anti-cheat
Percentage done : {||--------} 20%

If you think v3x is a PIMP, paste this into your sig!

If you think Bailopan is DA BOMB, paste this into your sig
LynX is offline
Send a message via ICQ to LynX
PyRo
Member
Join Date: Mar 2005
Old 05-31-2005 , 11:54  
Reply With Quote #3

Quote:
Originally Posted by LynX
errrrmmmm... maybe do precache_sound in public plugin_precache()
/me runs away and hides
I knew it was something obvious, thanks
__________________
85.133.16.45:27035 - [CPP] Clan Server #1 (fun Maps)
85.133.16.48:27195 - [CPP] Clan Server #2 (Standard/Custom/Fun Maps)
PyRo 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 16:37.


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