pHael commented on a Page, Spam Relay (two bots required)  -  Apr 10, 2010

fixed 1:

bind msgm - * msg:spam:check
proc msg:spam:check {nick uhost hand text} { 
  global spamwords oppedbot
  foreach nospamchan [channels] {
    if {[channel get $nospamchan spamcheck]} {
      if {([botonchan $nospamchan]) && ([onchan $oppedbot $nospamchan]) && (![isbotnick $nick])} { 
        if {([onchan $nick $nospamchan]) && (![validuser $hand]) && (![isop $nick $nospamchan]) && (![isvoice $nick $nospamchan])} {
          foreach pattern $spamwords {
            if {[string match -nocase $pattern $text]} {
              putquick "PRIVMSG $oppedbot :spam $nospamchan $nick" 
            }
          }
        }
      }
    } 
  } 
  return 0
}

fixed 2:

bind CTCP - ACTION spam:check
proc spam:check {nick uhost hand dest key text} {
  global botnick spamwords oppedbot
  foreach nospamchan [channels] {
    if {[channel get $nospamchan spamcheck]} {
      if {([botonchan $nospamchan]) && ([onchan $oppedbot $nospamchan]) && (![isbotnick $nick])} {
        if {![validuser $hand]} {
          if {([onchan $nick $nospamchan]) && (![isop $nick $nospamchan]) && (![isvoice $nick $nospamchan])} {
            foreach pattern $spamwords {
              if {[string match -nocase $pattern $text]} { 
                putquick "PRIVMSG $oppedbot :spam $nospamchan $nick"
              }
            }
          }
        }
      } 
    } 
  }
  return 0
}
 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.