Skip to content

Instantly share code, notes, and snippets.

@hm2k
Created January 26, 2011 19:55
Show Gist options
  • Save hm2k/797318 to your computer and use it in GitHub Desktop.
Save hm2k/797318 to your computer and use it in GitHub Desktop.
alias badword { ;badword v0.3 by HM2K Usage: $badword($1-)
var %x = bitch asshole fuck nigger shit bastard whore slut wanker cunt slag dick prick arse nigger cock faggot niggah pussy penis vagina
var %y = 0
var %z = $numtok(%x,32)
while (%y < %z) {
inc %y
if ($gettok(%x,%y,32) isin $1-) { return $true }
}
return $false
}
on *:text:*:#chan: {
if ($me !isop $chan) { return }
if ($nick !isreg $chan) { return }
if (!$eval($+(%,banspam,$chan,.,$nick),2)) { return }
if ($badword) {
.ban -ku $+ $banspam.time $chan $nick 3 $iif($1,$1-,badword)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment