How can I prevent detection spamming [REP+]
#6

Quote:
Originally Posted by karemmahmed22
Посмотреть сообщение
It can be done with GetTickCount, And variable.
Heres an example
PHP код:
new TickCount[MAX_PLAYERS];
//OnPlayerConnect :-
TickCount[playerid] = 0;
//OnPlayerSuspectedForAirbreak or w/e the callback is :D
if(TickCount[playerid] < GetTickCount();)
{
 
TickCount[playerid] = GetTickCount() + 120000// Some time
 //Warn Here.
 
return 1;
}
else if(
TickCount[playerid] > GetTickCount()) return 1//no warnings. 
Its will warn every few mins if player still airbreaking, it wont spam the chat
P.S.:I didn't test it so, you can test me and tell me if theres something wrong.
Thanks for info, I repped you all for helping me but I have some errors, the problem is that it can't get tickcount I think have a look here

Код:
.pwn(707) : error 001: expected token: ")", but found ";"
.pwn(707) : error 036: empty statement
.pwn(707) : error 029: invalid expression, assumed zero
.pwn(707) : fatal error 107: too many error messages on one line
Error line is

Код:
if(TickCount[playerid] < GetTickCount();)
- EDIT -

Код:
if(TickCount[playerid] < GetTickCount())
You putted a ; that is was not needed, its working thanks for all guys
Reply


Messages In This Thread
How can I prevent detection spamming [REP+] - by SecretBoss - 20.09.2015, 07:58
Re: How can I prevent detection spamming [REP+] - by TommyB - 20.09.2015, 08:01
Re: How can I prevent detection spamming [REP+] - by SecretBoss - 20.09.2015, 08:07
Re: How can I prevent detection spamming [REP+] - by BroZeus - 20.09.2015, 08:21
Re: How can I prevent detection spamming [REP+] - by karemmahmed22 - 20.09.2015, 08:22
Re: How can I prevent detection spamming [REP+] - by SecretBoss - 20.09.2015, 08:33

Forum Jump:


Users browsing this thread: 1 Guest(s)