Need help, lol
#5

Quote:
Originally Posted by varthshenon
Посмотреть сообщение
pawn Код:
new Spam[MAX_PLAYERS];//On top of your script

//Inside your command
if((GetTickCount() - Spam[playerid]) < 3000) return SendClientMessage(playerid,Rage_Red,"SPAMMER GTFO!");
Spam[playerid] = GetTickCount();
Thanks, you get +1 reputation from me, lol.
So in basic it is same as
pawn Код:
new Spam[MAX_PLAYERS];//On top

//Inside your command
if((gettime() - Spam[playerid]) < 3) return SendClientMessage(playerid,-1,"You are spamming!");
Spam[playerid] = gettime();
(I use gettime() because I think it is faster and doesn't create lag)
but do I need to put it in all my commands or there is faster way of doing this?
Reply


Messages In This Thread
Need help, lol - by Nenad - 06.08.2011, 16:55
Re: Need help, lol - by Tigerkiller - 06.08.2011, 16:57
Re: Need help, lol - by Nenad - 06.08.2011, 17:03
Re: Need help, lol - by =WoR=Varth - 06.08.2011, 17:03
Re: Need help, lol - by Nenad - 06.08.2011, 17:21
Re: Need help, lol - by =WoR=Varth - 06.08.2011, 17:38
Re: Need help, lol - by Nenad - 06.08.2011, 17:47
Re: Need help, lol - by =WoR=Varth - 06.08.2011, 17:52
Re: Need help, lol - by Nenad - 06.08.2011, 18:02
Re: Need help, lol - by KoczkaHUN - 06.08.2011, 19:04
Re: Need help, lol - by Nenad - 06.08.2011, 19:18

Forum Jump:


Users browsing this thread: 2 Guest(s)