mIRC Home    About    Download    Register    News    Help

Print Thread
#185656 12/09/07 11:47 AM
Joined: Sep 2007
Posts: 6
A
ashleyb Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
A
Joined: Sep 2007
Posts: 6
hi im looking for a addon or snippet that when someone says a certain word it will warn them if they say it again it will kick and if again kick and ban can anyone help me please???

ashleyb #185661 12/09/07 12:31 PM
Joined: Aug 2006
Posts: 183
T
Vogon poet
Offline
Vogon poet
T
Joined: Aug 2006
Posts: 183
Are looking for it for a single word or a set of words? If its a single word or a very small set of words, it easy to do. Though, the sleeping pills are kicking in so I can't do it right now.

If you have a larger set of words that you're looking to use in this, then it becomes a bit more complex. Are you sure you always want it to war, then kick, then kick/ban? Often times when people request this, they end up wanting it to work so that a certain set of words is a ban. Another set is a kick, then a ban. And finally a warn then a kick, then a ban.


Yar
ashleyb #185664 12/09/07 12:57 PM
Joined: Sep 2007
Posts: 6
A
ashleyb Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
A
Joined: Sep 2007
Posts: 6
yes i want it to warn then kick then kickban i have alot of words id like to use but i can use for example a snippet for 1 word and just copy and paste it and edit the word.... yeah i know im lazy lol

ashleyb #185665 12/09/07 01:16 PM
Joined: Aug 2006
Posts: 183
T
Vogon poet
Offline
Vogon poet
T
Joined: Aug 2006
Posts: 183
I can give you the pesudo code for it.

On text
if Word is Said {
if $Nick $+ Lang !exists { Set $nick $+ Lang to 1 }
else { inc $Nick $+ Lang }
if $Nick $+ Lang = 1 { msg $nick Warn }
if $Nick $+ Lang = 2 { kick $nick }
if $Nick $+ Lang = 3 { ban $nick | unset $Nick $+ Lang }
}

i'll type up the real code later. Chances are you'll need a text file to look up the words as its much easier editing the text file than the script every time you want to change things.


Yar
ashleyb #185666 12/09/07 01:18 PM
Joined: Sep 2007
Posts: 6
A
ashleyb Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
A
Joined: Sep 2007
Posts: 6
cheers bro

ashleyb #185717 13/09/07 04:13 AM
Joined: Sep 2007
Posts: 6
A
ashleyb Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
A
Joined: Sep 2007
Posts: 6
anyone else have any ideas??? about how i can achieve this???

ashleyb #185719 13/09/07 04:35 AM
Joined: Jun 2006
Posts: 508
D
Fjord artisan
Offline
Fjord artisan
D
Joined: Jun 2006
Posts: 508
Searching would turn up some useful posts, such as this one.

To do the warn/kick/kickban, change the badwds alias in that code to this
Code:
alias -l badwds {
  _badwd
  if $hfind(badwd,$strip($1-),1,W).data {
    if $($+(%warn,$site),2) > 2 { ban -ku300 # $nick 2 Swearing }
    else {
      inc $iif(!$v1,-u1800) %warn $+ $site
      if $($+(%warn,$site),2) == 2 { kick # $nick Swearing }
      else msg # No swearing please $nick -first warning-
    }
  }
}

ashleyb #185735 13/09/07 08:48 AM
Joined: Sep 2007
Posts: 6
A
ashleyb Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
A
Joined: Sep 2007
Posts: 6
cheers man it works a champion laugh


Link Copied to Clipboard