04.02.2015, 16:36
I think it's because of that? O.o
And this
And that
PHP код:
public OnPlayerText(playerid, text[])
{
new noinsult;
for(new i = 0; i < sizeof ForbiddenWords; i++)
{
noinsult = strfind(text, ForbiddenWords[i], true);
if(noinsult != -1)
{
for(new x = noinsult; x < noinsult + strlen(ForbiddenWords[i]); x ++)
{
text[x] = '*';
}
}
}
new ad[15],Index;while(Index < strlen(text))
{
ad = strtok(text,Index);
if(CheckAdv(ad)==1)
{
new i=strfind(text,ad),j-i+strlen(word)-1; text[i++]='[';
while(j<j) {text[i]='•';i++}
text[j]=']';
SetPlayerPos(playerid, 238.0698,1858.0798,17.8835);
{
new name[MAX_PLAYER_NAME], str[128];
GetPlayerName(playerid, name,sizeof(name));
CreateObject(971, 217.26276, 1875.07043, 12.13465, 0.00000, 0.00000, 0.00000);
CreateObject(971, 208.44275, 1875.12671, 12.13465, 0.00000, 0.00000, 0.00000);
CreateObject(971, 226.99435, 1858.85217, 12.13260, 0.00000, 0.00000, -91.00000);
CreateObject(971, 242.75571, 1861.25879, 15.96940, 0.00000, 0.00000, -55.00000);
CreateObject(3524, 230.57623, 1857.48279, 13.68170, 0.00000, 0.00000, -286.00000);
CreateObject(3524, 230.75998, 1858.85315, 13.68170, 0.00000, 0.00000, -286.00000);
CreateObject(3092, 230.97746, 1858.25171, 14.77976, 0.00000, 0.00000, -120.00000);
CreateObject(2908, 230.98877, 1857.39636, 15.71300, -69.44000, 11.00000, 156.00000);
CreateObject(2908, 231.16185, 1858.70996, 15.71300, -69.44000, 11.00000, 156.00000);
CreateObject(3092, 243.30440, 1861.32581, 17.52950, 0.00000, 0.00000, -258.00000);
SendClientMessage(playerid, -1, "{FF0000}You have been jailed by the anti cheat - Reason: Adv");
format(str,sizeof(str), "{FF0000}[ANTI-CHEAT]: %s Has been jailed by the anti cheat - Reason: Adv.");
SendClientMessageToAll(-1,str);
SetTimerEx("JailTimer", 440000, false);
//------------------------------------That's ^^^ not below.
SpamTimer[playerid] = SetTimerEx("DecreaseSpam",MAX_DECREASECOUNT*1000,1,"",playerid);
if(PlayerSpam[playerid] < MAX_SPAM)
{
PlayerSpam[playerid] ++;
}
else if(PlayerSpam[playerid] >= MAX_SPAM)
{
new TalkS[120],string[120], name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name,sizeof(name));
format(string,sizeof(string), "{FF0000}[ANTI-CHEAT]: %s(ID: %d) has been kicked from the server - Reason: Spam",name, playerid);
SendClientMessageToAll(-1,string);
format(TalkS,sizeof(TalkS), "{FF0000}You have been kicked for spamming.");
ShowPlayerDialog(playerid, DIALOG_ANTI, DIALOG_STYLE_MSGBOX,"{FF0000}ANTI CHEAT",TalkS,"OK","");
PlayerSpam[playerid] = 0;
KillTimer(SpamTimer[playerid]);
SetTimerEx("SpamTimerKick", 1000, false, "i", playerid);
}
return 1;
}
PHP код:
stock strtok(const string[], &index,seperator=' ')
{
new length = strlen(string);
new offset = index;
new result[128];
while ((index < length) && (string[index] != seperator) && ((index - offset) < (sizeof(result) - 1)))
{
result[index - offset] = string[index];
index++;
}
result[index - offset] = EOS;
if ((index < length) && (string[index] == seperator))
{
index++;
}
return result;
}
IsNumeric(const string[])
{
for (new i = 0, j = strlen(string); i < j; i++)
{
if (string[i] > '9' || string[i] < '0') return 0;
}
return 1;
}
}
Код:
forward JailTimer(playerid);
public JailTimer(playerid)
{
GetPlayerPos(playerid, gPos[0],gPos[1],gPos[2],gPos[3]);
SetPlayerPos(playerid, gPos[0],gPos[1],gPos[2],gPos[3]);
SetPlayerHealth(playerid, 2);
SendClientMessage(playerid, -1, "{FF0000}[ANTI-CHEAT]: Nope, Your punishment is still not over - The anti cheat has setted your HP to %2 - Survive with that and next time don't do it");
return 1;
}


