[ANY] Advert Antiflood
1 Attachment(s)
Advert Antiflood
Description Ever get annoyed by people spamming their trade advertisements in TF2 trade servers? The current antiflood in sourcemod would allow a player to spam an advert up to 3 times before he is throttled for flooding. This will detect lines of chat that are identical and limit the time allowed between them. Thus people that bind an advert to a key will only be able to display it once per X time. This should have a huge impact on cleaning up the chat and allowing everyone to see adverts easily without having to deal with the spam. I wrote this plugin with TF2 trade servers in mind however it will work for any game. NOTE If you have another plugin that manipulates the chat you might have to combine this plugin with the other. For example the simple chat colors plugin could conflict with this. CVARS sm_advertflood_time "5.00" Amount of time in seconds allowed between advert chat messages. sm_advertflood_minlen "5" Minimum length of text to be detected (this will prevent people being throttled for various small things that they actually type fast. For example repeating the answer to yes/no question or making two smiley faces..etc) :D :D Changelog 1.4 - Fixed a bug where client timer did not become invalid after a player left the server. 1.3 - Added userid tracking in timer. 1.2 - Cleaned up code a bit. Made plugin ignore console chat. 1.1 - Added detection for past 3 lines. 1.0 - Initial release. |
Re: [ANY] Advert Antiflood
looks like it works good thanks.
|
Re: [ANY] Advert Antiflood
Thanks for this tough guy!
|
Re: [ANY] Advert Antiflood
Added detection for past three lines. The reason for this is because I got a few people who got clever, made two separate binds with different text to get around the block since it only memorized a single line.
What is nice about this version is that it will still allow people to use multi line adverts but will not allow them to spam. |
Re: [ANY] Advert Antiflood
Great work, useful plug-in.
One suggestion, could you make it ignore console say messages. It currently throws an error if you spam a message from the console. Thank you. |
Re: [ANY] Advert Antiflood
Quote:
|
Re: [ANY] Advert Antiflood
Does it allow a whitelist so to speak for cmds used by players repeatedly like !buy or such used from a plugin?
|
Re: [ANY] Advert Antiflood
Quote:
|
Re: [ANY] Advert Antiflood
You should be using AddCommandListener instead of RegConsoleCmd.
|
Re: [ANY] Advert Antiflood
It did block my say commands, after the first time of course, like it's supposed to. I just modified it to allow the same thing twice in a row.
|
All times are GMT -4. The time now is 11:14. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.