Anti-spam protection

By ducki on Feb 25, 2009

This is the second snippet I have posted today. It is very, very simple. I was actually looking for some feedback on this because I didn't quite know how to code it to where only people with 100 access and lower would be kicked from the anti-spam protection. So please feel free to leave comments stating how I could go about rearranging my snippet. Thanks!

on *:TEXT:*:#Channel: { 
  if (%flood2. [ $+ [ $wildsite ] ] == $null) {
    set -u5 %flood2. [ $+ [ $wildsite ] ] 1
  }
  elseif (%flood2. [ $+ [ $wildsite ] ] >= 10) {
    kick $chan $nick Anti-flood protection has been activated.
    unset %flood2. [ $+ [ $wildsite ] ]
  } 
  else { inc -u5 %flood2. [ $+ [ $wildsite ] ] } 
}

Comments

Sign in to comment.
chachin   -  Sep 05, 2011

hey I like your work. but how can i make a spam filter on a script I made a few days ago. I'm barely starting to learn scripting and want to make some spam filters on som of my scripts. if you would be cool to help me then do so ASAP

 Respond  
ducki   -  Feb 25, 2009

Didn't see it :)

 Respond  
Aucun50   -  Feb 25, 2009

If your going to edit your code hit the edit button on the code you posted :)

 Respond  
ducki   -  Feb 25, 2009

Edit:

on :TEXT::#Channel: {
if ($ulevel <= 100) {
if (%flood2. [ $+ [ $wildsite ] ] == $null) {
set -u5 %flood2. [ $+ [ $wildsite ] ] 1
}
elseif (%flood2. [ $+ [ $wildsite ] ] >= 10) {
kick $chan $nick Anti-flood protection has been activated.
unset %flood2. [ $+ [ $wildsite ] ]
}
else { inc -u5 %flood2. [ $+ [ $wildsite ] ] }
}
}

Got what I was looking for. Thanks for the help mountaindew. :)

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.