[Help] GetPlayerSpecialAction not working? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: [Help] GetPlayerSpecialAction not working? (
/showthread.php?tid=435804)
[Help] GetPlayerSpecialAction not working? -
Tika Spic - 08.05.2013
OK so this is from my anticheat for JetPacks:
Код:
if (GetPlayerSpecialAction(i) == SPECIAL_ACTION_USEJETPACK)
{
format(string, sizeof(string), "| Ban %s | Reason: JetPack", sendername);
SendClientMessageToAll(COLOR_RED, string);
SetPlayerSpecialAction(i, SPECIAL_ACTION_NONE);
new banloc[64]; format(banloc,64,"bans/%s.ini",sendername);
dini_Create(banloc);
dini_Set(banloc, "Admin", "AntiCheat");
dini_Set(banloc, "Reason", "Jetpack");
Kick(i);
}
It kicks the correct player but bans a random player ... The ban file is created for that random player, so the one who used the JetPack isn't even banned.
Can anyone tell me what I'm doing wrong?
AW: [Help] GetPlayerSpecialAction not working? -
HurtLocker - 08.05.2013
Where is the code where you get the cheater's name? (sendername)
Re: [Help] GetPlayerSpecialAction not working? -
Tika Spic - 08.05.2013
Ok, how dafuq did I miss that :O.. Thanks bro thats the problem, it was right after this, for the weapon hack check :O.. I seriosly don't know how I didn't figure that out ... :O