SA-MP Forums Archive
New Crash !!! - 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: New Crash !!! (/showthread.php?tid=581036)



New Crash !!! - neymar1477 - 10.07.2015

Hello guys.. today i was having 60 players... but suddenly it goes 20 because of fking player crasher (mod blue eclipse...)... and i want an anti crasher script like UIF has. If you have a crasher and attempted to crash a player, the server will closed the connection "Server Closed The Connection" if anyone can script one or have one. That would be great thanks.


Re: New Crash !!! - Lucky™ - 10.07.2015

Quote:

It could be one of the new player crashers that's being used on servers lately, http://pastebin.com/BPmF9CZ3 seems to block them.

Enjoy!


Re: New Crash !!! - neymar1477 - 10.07.2015

Quote:
Originally Posted by Lucky™
Посмотреть сообщение
Enjoy!
How do I get to ban automatically ?


Re: New Crash !!! - SecretBoss - 10.07.2015

Quote:
Originally Posted by neymar1477
Посмотреть сообщение
How do I get to ban automatically ?
detect it first and then ban is easy


Re: New Crash !!! - awsomedude - 10.07.2015

You can also use this include https://sampforum.blast.hk/showthread.php?tid=581017


Re: New Crash !!! - Sithis - 10.07.2015

Quote:
Originally Posted by neymar1477
Посмотреть сообщение
How do I get to ban automatically ?
By scripting it. Seriously, don't be lazy, you're in the SCRIPTING section.


Re: New Crash !!! - Lucky™ - 10.07.2015

Quote:
Originally Posted by neymar1477
Посмотреть сообщение
How do I get to ban automatically ?
pawn Код:
public OnPlayerWeaponShot( playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ )
{
        new Float:x, Float:y, Float:z;
        GetPlayerPos(playerid, x, y, z);

        //Desync weapon IDs that don't fire bullets
        if (weaponid < 22 || weaponid > 38)
        {
            Ban(playerid);
                return 0;
        }

        //Desync shots with Z pos out of bounds
        if(!(-20000.0 <= z <= 20000.0))
                return 0;

        return 1;
}



Re: New Crash !!! - neymar1477 - 10.07.2015

Quote:
Originally Posted by Lucky™
Посмотреть сообщение
pawn Код:
public OnPlayerWeaponShot( playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ )
{
        new Float:x, Float:y, Float:z;
        GetPlayerPos(playerid, x, y, z);

        //Desync weapon IDs that don't fire bullets
        if (weaponid < 22 || weaponid > 38)
        {
            Ban(playerid);
                return 0;
        }

        //Desync shots with Z pos out of bounds
        if(!(-20000.0 <= z <= 20000.0))
                return 0;

        return 1;
}
thanks