Raised This Month: $ Target: $400
 0% 

Help with SendAudio


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
soccdoodcss
Veteran Member
Join Date: Nov 2006
Location: Wisconsin
Old 01-19-2007 , 02:02   Help with SendAudio
Reply With Quote #1

PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <fun>

#define PLUGIN "RiskItAll"
#define VERSION "0.0"
#define AUTHOR "Bent/Soccdoodcss"

new bet[7], money

public plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
register_event("RoundTime""say_bet""b")
    
register_event("SendAudio""receive_bet""b")
    
    
register_concmd("amx_bet""set_bet"0)
}

public 
say_bet(id)
{
    
set_hudmessage(255,0,0,0.43,0.3,0,6.0,10.0)
    
show_hudmessage(id"Place One Or Multiple Bets.")
}

public 
set_bet(id)
{
    
read_argv(1bet6)
    
money str_to_num(bet)
    
    if (
money cs_get_user_money(id))
        
money=cs_get_user_money(id)
    else if (
money<0)
        
money=0
    
if(money!=0)
        
cs_set_user_money(idcs_get_user_money(id) - money)
}

public 
receive_bet(id)
{
    if(
is_user_alive(id))
    {
        
set_hudmessage(025500.430.306.010.0)
        
show_hudmessage(id"You won your money and $%d."money)
        
cs_set_user_money(idcs_get_user_money(id) + money money)
    }
    else
    {
        
set_hudmessage(0,255,0,0.45,0.3,0,6.0,10.0)
        
show_hudmessage(id"You lost $%d."money)
    }
    
money 0
    
return PLUGIN_CONTINUE

Anyone know why the SendAudio is showing up at the beginning of a new round? Thanks.
__________________
"Now safe beneath their wisdom and their feet.
Here I will teach you truly how to sleep."
soccdoodcss is offline
Send a message via AIM to soccdoodcss
XxAvalanchexX
Veteran Member
Join Date: Oct 2004
Location: abort73.com
Old 01-19-2007 , 02:10   Re: Help with SendAudio
Reply With Quote #2

It's probably the "Okay let's go!" sound clips. You probably want to use hook only objective-based ones, such as "The bomb has been planted!"
__________________
No longer around. Thanks your support, everyone! As always:
THIS ONES FOR YOU
3000 PTS
XxAvalanchexX is offline
soccdoodcss
Veteran Member
Join Date: Nov 2006
Location: Wisconsin
Old 01-20-2007 , 11:52   Re: Help with SendAudio
Reply With Quote #3

Alright thanks, is there perhaps another event at the end of the round that I am not familiar with?
__________________
"Now safe beneath their wisdom and their feet.
Here I will teach you truly how to sleep."
soccdoodcss is offline
Send a message via AIM to soccdoodcss
[ --<-@ ] Black Rose
ANNIHILATED
Join Date: Sep 2005
Location: Stockholm, Sweden.
Old 01-20-2007 , 16:40   Re: Help with SendAudio
Reply With Quote #4

End of round:
Code:
register_event("SendAudio", "event_EndRound", "a", "1=0");
[ --<-@ ] Black Rose is offline
soccdoodcss
Veteran Member
Join Date: Nov 2006
Location: Wisconsin
Old 01-25-2007 , 18:59   Re: Help with SendAudio
Reply With Quote #5

Thanks a lot.
__________________
"Now safe beneath their wisdom and their feet.
Here I will teach you truly how to sleep."
soccdoodcss is offline
Send a message via AIM to soccdoodcss
Reply


Thread Tools
Display Modes

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 22:30.


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