win frags
i had used a similar script that worked in the past but lost it. Can anyone help solve what i'm trying to do here?
public plugin_init() { register_event("SendAudio", "T_frags", "a", "2&%!MRAD_terwin") register_event("SendAudio", "CT_frags", "a", "2&%!MRAD_ctwin") } public CT_frags(id) { if(CsTeams:cs_get_user_team(id) == CS_TEAM_CT) { set_user_frags(id, get_user_frags(id) +3) message_begin(MSG_BROADCAST,get_user_msgid("S coreInfo")); write_byte(id); write_short(get_user_frags(id)); write_short(cs_get_user_deaths(id)); write_short(0); write_short(1); message_end(); } return PLUGIN_HANDLED } |
Re: win frags
What are u trying to do??
|
Re: win frags
There is nothing like id in SendAudio event. You should use a cycle to pass through all players. Look on get_players() and pass through team, then you won't need to call the event two useless times.
Edit: Oh, sorry. Didn't notice that 2&%!MRAD_ctwin. Actually, I think it's still better to hook round end and pass through teams there. |
Re: win frags
What I'm trying to do is add frags to the winning team after each round. This method worked and scores updated right away. After a few years of being away my scripting abilities are gone and I need help.
|
Re: win frags
solved. thanks.
|
| All times are GMT -4. The time now is 07:09. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.