[FilterScript] Anti IP/PAGE
#1

Hi, I would like to introduce you to my script on the Anti IP / PAGE

The script I did in 3 minutes and does not contain much code

Код:
#include <a_samp>


new str[128];


public OnPlayerText(playerid, text[])
{


if(anty(text) && !IsPlayerAdmin(playerid))
{
format(str,256,"*** Player %s has been banned from the Server. Reason: advertising IP / PAGE",PlayerName(playerid));
SendClientMessageToAll(0xFF0000FF, str);
Ban(playerid);
return 0;
}


return 1;
}

stock anty(string[])
{
if(strfind(string,"www.",true)!=-1 || strfind(string,"http://",true)!=-1 || strfind(string,".com",true)!=-1 || strfind(string,".net",true)!=-1 || strfind(string,"91.",true)!=-1 || strfind(string,"195.",true)!=-1 || strfind(string,".pl",true)!=-1|| strfind(string,".org",true)!=-1)
return true;
return false;
}


stock PlayerName(playerid)
{
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, MAX_PLAYER_NAME);
return name;
}
Reply


Messages In This Thread
Anti IP/PAGE - by niepowtarzalny - 13.07.2010, 16:12
Re: Anti IP/PAGE - by marine - 13.07.2010, 16:19
Re: Anti IP/PAGE - by wolfcock - 13.07.2010, 16:40
Re: Anti IP/PAGE - by Toni - 13.07.2010, 16:55
Re: Anti IP/PAGE - by RyDeR` - 13.07.2010, 18:59
Re: Anti IP/PAGE - by Flavinho153 - 13.07.2010, 20:54
Re: Anti IP/PAGE - by JohnnyIV - 05.06.2013, 09:58
Re: Anti IP/PAGE - by JohnnyIV - 05.06.2013, 10:14
Re: Anti IP/PAGE - by KingHual - 05.06.2013, 12:31

Forum Jump:


Users browsing this thread: 2 Guest(s)