Monthly Target: $400 Donations: $299
 74% 

An example of an antispam check


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Impact123
SourceMod Donor
Join Date: Oct 2011
Location: Germany
Old 04-15-2012 , 22:09   An example of an antispam check
Reply With Quote #1

I've seen a few people still struggling with this, so here is my participation.
This simple commented example script shows you how to avoid command/function spamming.
I wrote this for beginners, so it's heavily commented.
Hope it helps!
Code

Yours sincerely
Impact
__________________
I will refuse to answer you if you're a chronic full quoter
AutoExecConfig | CallAdmin | More plugins | Donate

Last edited by Impact123; 04-15-2012 at 22:09.
Impact123 is offline
mcpan313
Senior Member
Join Date: Mar 2010
Old 04-16-2012 , 08:21   Re: An example of an antispam check
Reply With Quote #2

thx, it's usefull
__________________
sorry, for my poor english.
mcpan313 is offline
Send a message via MSN to mcpan313
animalnots
Senior Member
Join Date: Dec 2012
Old 01-26-2013 , 08:12   Re: An example of an antispam check
Reply With Quote #3

Its cool but what about userids ? You should use userids instead of client or there should be a check that it's the same client we're communicating with.
http://wiki.alliedmods.net/Introduct...Entity_Indexes
__________________
STEAM is the best of the west
Quote:
Never argue with an idiot. He lowers you to his level and then wins on experience!
animalnots is offline
Impact123
SourceMod Donor
Join Date: Oct 2011
Location: Germany
Old 01-26-2013 , 08:16   Re: An example of an antispam check
Reply With Quote #4

There is is no need for it, the time will be purged if the client leaves the server.
This is just an simple example to get you started, for example an client can trick this by rejoining the server.

Yours sincerely
Impact
__________________
I will refuse to answer you if you're a chronic full quoter
AutoExecConfig | CallAdmin | More plugins | Donate

Last edited by Impact123; 01-26-2013 at 08:16.
Impact123 is offline
animalnots
Senior Member
Join Date: Dec 2012
Old 01-26-2013 , 08:29   Re: An example of an antispam check
Reply With Quote #5

But if he joins again he can spam again.
__________________
STEAM is the best of the west
Quote:
Never argue with an idiot. He lowers you to his level and then wins on experience!
animalnots is offline
thetwistedpanda
Good Little Panda
Join Date: Sep 2008
Old 01-26-2013 , 09:55   Re: An example of an antispam check
Reply With Quote #6

The userid will change if the client reconnects. If the value must be maintained, it can be thrown into a clientpref, array, steamid trie, etc.
__________________

Last edited by thetwistedpanda; 01-26-2013 at 09:56.
thetwistedpanda is offline
animalnots
Senior Member
Join Date: Dec 2012
Old 01-26-2013 , 10:14   Re: An example of an antispam check
Reply With Quote #7

steamid trie? Give an example.
Array? Is there a dynamic allocated array??
__________________
STEAM is the best of the west
Quote:
Never argue with an idiot. He lowers you to his level and then wins on experience!
animalnots is offline
minimoney1
SourceMod Donor
Join Date: Dec 2010
Old 01-26-2013 , 14:23   Re: An example of an antispam check
Reply With Quote #8

Quote:
Originally Posted by animalnots View Post
steamid trie? Give an example.
Array? Is there a dynamic allocated array??
adt_array is probably what you're looking for.
adt_trie is for tries. Take a look at the API page and you'll get more information.
__________________
Need help? PM me or add me on Steam.
My Steam




Quote:
Originally Posted by Rp.KryptoNite View Post
For some reason his Plugin never worked for me ,
@credits were added
im not stealing any plugins dude its my THING
minimoney1 is offline
Ermert1992
Junior Member
Join Date: Jan 2012
Location: Germany
Old 01-07-2014 , 05:48   Re: An example of an antispam check
Reply With Quote #9

Thanks, I've looked for something like that
Ermert1992 is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 23:54.


Powered by vBulletin®
Copyright ©2000 - 2015, vBulletin Solutions, Inc.
Theme made by Freecode