Can anyone help me on this ?
This is for DOD HL1
Can anyone help me on this scripts? Is there anything wrong with it ? It's seems don't work even deaths reach to 10 . Maybe I'm too nub to understand where did I go wrong. ================================== #include <amxmodx> public plugin_init() { // .. register_plugin("deaths_Kicker","1.0","Shadow Leader(123)") register_event("ResetHUD","newRound","b") register_cvar("deaths_limit","10") } public newRound(id) { if(get_user_deaths(id) >= get_cvar_num("deaths_limit")) { server_cmd("banid #%d 5",get_user_userid(id)) server_cmd("kick #%d ^"Reached Death Limits (%d) - Banned 5 min^"",get_user_userid(id),get_user_deaths(id )) } return PLUGIN_HANDLED } ================= Thank you in advance |
server_cmd(kick ..... change to server_cmd(ban .....
and server_cmd(ban ..... change to server_cmd(kick ..... Reached Death Limits (%d),get_user_deaths(id) change to Reached Death Limits (%d),get_cvar_num("deaths_limit") server_cmd("banid #%d 5",get_user_userid(id)) change to new authid[32] get_user_authid(id, authid, 31) server_cmd("banid %d 5",authid) |
Hi there. thanks for the reply, I've tried to change it as mentioned.
But no luck, it won't kick when reach 10 deaths. Did I make anymore mistakes ? Thanks in advance ============================ #include <amxmodx> public plugin_init() { // .. register_plugin("deaths_Kicker","1.0","Shadow Leader(123)") register_event("ResetHUD","newRound","b") register_cvar("deaths_limit","10") } public newRound(id) { if(get_user_deaths(id) >= get_cvar_num("deaths_limit")) { server_cmd("kick #%d ^"Reached Death Limits (%d)^"",get_cvar_num("deaths_limit"),get_user _deaths(id)) new authid[32] get_user_authid(id, authid, 31) server_cmd("banid %d 5",authid) } return PLUGIN_HANDLED } ============================= |
you have 1 line not right
Code:
|
Thanks Again.
But still no luck. It did not auto kick or auto banned. Script compile correctly and run perfectly.... Thank you. |
try this:
Code:
|
Quote:
|
Thank you for the Reply.
I've tried both: By v3x if(dod_get_pl_deaths(id) >= get_cvar_num("deaths_limit")) and by: Z@C if(get_user_deaths(id) >= get_cvar_num("deaths_limit")) Both scripts I have changed the "%s" and enable/disable dodfun (tried both) But it seems luck not on my side. It still won't kick when reach 10 deaths. any further suggestion to help? Thank you. |
Re: Can anyone help me on this ?
try this:
#include <amxmodx> #include <dodfun> public plugin_init() { register_plugin("deaths_Kicker","1.0","Shadow Leader(123)") register_event("ResetHUD","newRound","a") // flag "b" change to "a" register_cvar("deaths_limit","10") } public newRound(id) { new authid[32],reason[64] get_user_authid(id, authid, 31) if(dod_get_pl_deaths(id) >= get_cvar_num("deaths_limit")) { format(reason,63,"Reached Death Limits (%s)",get_cvar_num("deaths_limit")) // i add this server_cmd("kick #%d %s,get_user_userid(id),reason) server_cmd("banid %s 5",authid) // changed %d to %s because authid is a string } } |
| All times are GMT -4. The time now is 08:06. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.