CPL Protection.

By WacKy- on Apr 21, 2005

Well iv tested and tbh it pwned me even with a takover script lol, u might have to change it a little bit b/c its set for my bot but its not hard :) commands !bitchmode on/off to turn it on or off and let it do its proteciton stuff

on 1:TEXT:*!bitchmode on*:#:{
  if ($readini(admin.ini,$chan,$address($nick,2) != admin)) {
    msg $chan [- You need to be admin to turn this function on/off -]
  }
  elseif ($readini(bitchmode.ini,BITCHMODE,$chan == ON)) { msg $chan [- Bitchmode Is Allready Enabled $nick -]
  }
  elseif ($2 != $nul) {
    writeini bitchmode.ini BITCHMODE $chan ON
    msg $chan [- Bitch Mode Is Now Enabled For $chan -]
  }
  else { msg $chan [- Use: !bitchmode on ' -]
  }
}

on 1:TEXT:*!bitchmode off*:#:{
  if ($readini(admin.ini,$chan,$address($nick,2) != admin)) {
    msg $chan  [- You need to be admin to turn this function on/off -]
  }
  elseif ($readini(bitchmode.ini,BITCHMODE,$chan == OFF)) { msg $chan [- Bitchmode Is Allready Disabled $nick -]
  }
  elseif ($2 != $null) {
    writeini bitchmode.ini BITCHMODE $chan OFF
    msg $chan [- Bitch Mode Is Now Disabled For $chan -]
    msg $chan [- Topic Is Now Disabled For $chan -]
    notice $nick [- Topic Will Be Return To Last Topic set. -]
    topic $chan $readini(topics.ini,TOPICS,$chan)
  }
  else {  msg $chan [- Use: !bitchmode on ' -]
  }
}

on 1:BAN:#:{
  if ($readini(bitchmode.ini,BITCHMODE,$chan == OFF)) { halt
  }
  elseif ($banmask iswm $address($me,5)) && ($nick != $me) {
    timer 1 1  msg l unbanall $chan
    timer 1 2  msg Q unbanall $chan
    timer 1 3  join $chan
    timer 1 5  mode $chan +b $nick
    timer 1 6  kick $chan $nick Banned: ( Viloating $chan Rules ): No Banning: ID 26
    timer 1 6  mass -o 
  }
  elseif ($nick == $me) || ($nick == L) || ($nick == Q) { halt
  }
  elseif ($readini(admin.ini,$chan,$address($nick,2) == admin)) { halt
  }
  else { 
    timer 1 1  msg l unbanall $chan
    timer 1 2  msg Q unbanall $chan
    timer 1 3  join $chan
    timer 1 5  mode $chan +b $nick
    timer 1 6  kick $chan $nick Banned: ( Viloating $chan Rules ): No Banning: ID 26
  }
}

on 1:KICK:#:{
  if ($readini(bitchmode.ini,BITCHMODE,$chan == OFF)) { halt
  }
elseif ($knick == $me) {
    /msg l unbanall $chan
    msg Q unbanall $chan
    join $chan
    mode $chan +b $nick
    kick $chan $nick Banned: ( Viloating $chan Rules ): No Kicking: ID 22
    mass -o 
}
  elseif ($nick == $me) || ($nick == L) || ($nick == Q) { halt
  }
  elseif ($readini(admin.ini,$chan,$address($nick,2) == admin)) { halt
  }
  else { 
    /msg l unbanall $chan
    msg Q unbanall $chan
    mode $chan +b $nick
    kick $chan $nick Banned: ( Viloating $chan Rules ): No Kicking: ID 22
    mass -o 
  }
}

on 1:DEOP:#:{
  if ($readini(bitchmode.ini,BITCHMODE,$chan == OFF)) { halt
  }
  elseif ($nick == $me) || ($nick == L) || ($nick == Q) { halt
  }
  elseif ($readini(admin.ini,$chan,$address($nick,2) == admin)) { halt
  }
  else { 
    msg l op $chan $me
    msg Q op $chan $me
    mode $chan +b $nick
    kick $chan $nick Banned: ( Viloating $chan Rules ): No Deoping: ID 23
    mass -o 
  }
}

on 1:UNBAN:#:{
  if ($readini(bitchmode.ini,BITCHMODE,$chan == OFF)) { halt
  }
  elseif ($nick == $me) || ($nick == L) || ($nick == Q) { halt
  }
  elseif ($readini(admin.ini,$chan,$address($nick,2) == admin)) { halt
  }
  else { 
    mode $chan +b $nick $banmask
    kick $chan $nick Banned: ( Viloating $chan Rules ): No Unbanning: ID 24
    mass -o 
  }
}

on @*:mode:#:{ 
  if ($readini(bitchmode.ini,BITCHMODE,$chan == OFF)) { halt
  }
  elseif ($nick == $me) || ($nick == L) || ($nick == Q) { halt
  }
  elseif ($readini(admin.ini,$chan,$address($nick,2) == admin)) { halt
  }
  else { 
    mode $chan $replacex($1-,+,-,-,+)
    mode $chan +b $nick 
    kick $chan $nick Banned: ( Viloating $chan Rules ): No Mode Changes: ID 27
    mass -o 
  }
}

alias mass {
  var %a = "", %b = 1, %c = $+($left($1,1),$str($right($1,1),$modespl))
  while ($nick(#,0) >= %b) {
    if ($1 == -o) && ($nick(#,%b,a) == $me) { inc %b }
    var %a = %a $nick(#,%b,a)
    if ($modespl // %b) { mode # %c %a | var %a = "" }
    inc %b
  }
  if (%a) { mode # %c %a  }
}

Comments

Sign in to comment.
xDaeMoN   -  Apr 21, 2005

You misplaced the \")\" in your $readini. It should be \"$readini(file.ini,section,item) == value\".

 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.