02.02.2018, 09:53
you get muted just by typing 5 messages in chat..it doesnt matter if you write fast or wait 1 minute between messages..you still get muted.
and after you get muted for the first time,after the mute expires,you can flood the chat as long as you want,you wont get muted again.
and after you get muted for the first time,after the mute expires,you can flood the chat as long as you want,you wont get muted again.
Quote:
SpamCheck[playerid] = GetTickCount(); if(GetTickCount() - SpamCheck[playerid] < 1000 && SpamCheck[playerid] != 0) { SpamTimes[playerid]++; if(SpamTimes[playerid] == 5) { PlayerData[playerid][Muted] = 1; PlayerData[playerid][MutedTime] += 20; new str[128]; // blah blah mysql_format(SQL, str,128,"UPDATE `users` SET `Muted`='1' ,`MutedTime`='%d' WHERE `id` = '%d' LIMIT 1",PlayerData[playerid][MutedTime],PlayerData[playerid][ID]); mysql_tquery(SQL, str, "", ""); SendClientMessage(playerid, COLOR_GREY, "You have been auto-muted for spamming. You will be unmuted in 20 seconds."); return 0; } } else SpamTimes[playerid] = 0; |