anti cj hack - 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: anti cj hack (
/showthread.php?tid=638881)
anti cj hack -
Bussyman - 07.08.2017
Hi,
SetTimer( "AntiReconnect", 15000, true );
Код:
forward AntiReconnect( );
public AntiReconnect( )
{
foreach(Player, playerid)
{
new State = GetPlayerState( playerid );
if( State == 1 || State == 2 || State == 3 || State == 8 )
{
if( !Spawned[ playerid ] )
{
printf ( "Player [ ID: %i ] kicked for reconnect.", playerid );
Kick ( playerid );
}
}
}
}
This is accurate? if player is not using hacks, when he spawn onplayerspawn allways get called?
new Spawned[ MAX_PLAYERS ];
OnPlayerSpawn
Spawned[ playerid ] = true;
Re: anti cj hack -
DarkZero - 08.08.2017
So you want to kick a player who reconnects and spawns within 15 seconds? What about those who are having a timeout for one second only (can happen) and login and spawn fast?
I can't answer your question, but I think you should keep this also on your mind.