23.11.2009, 21:31
This is a anti spam library designed to make it easier to reduce spamming in your server without the need for timers and loops etc. The source is commented (OTT in some places) and I have included examples of it's usage (UDST) although unless you need to change the default intervals or add some user defined types then you won't ever need to do more than this really:
You can grab it HERE and learn more about why I did it using time and not timers HERE.
By default the protection time on each feature (chat is a feature) is three seconds but you can change this by modifying the SPAM_PERIOD_**** macros near the top of the script (line 70). It protects you against three main types, chat, commands and keys but you can add more or you can disable a type by using one of the IGNORE_****_PROTECTION macros, read the source as the comments explain the "how, what and why" of it all really.
Please report any issues or suggest any additional features, all replies are welcome (cc included!).
I forgot credits in the source so I'll add them here:
Kye - ofcourse
Y_Less - optimisations thread and _ALS_ hooking method
Donny - 'cos I wrote it
pawn Code:
#include <nospam>
By default the protection time on each feature (chat is a feature) is three seconds but you can change this by modifying the SPAM_PERIOD_**** macros near the top of the script (line 70). It protects you against three main types, chat, commands and keys but you can add more or you can disable a type by using one of the IGNORE_****_PROTECTION macros, read the source as the comments explain the "how, what and why" of it all really.
Please report any issues or suggest any additional features, all replies are welcome (cc included!).
I forgot credits in the source so I'll add them here:
Kye - ofcourse
Y_Less - optimisations thread and _ALS_ hooking method
Donny - 'cos I wrote it