mIRC Home    About    Download    Register    News    Help

Print Thread
#72960 27/02/04 08:25 PM
Joined: Dec 2003
Posts: 261
M
milosh Offline OP
Fjord artisan
OP Offline
Fjord artisan
M
Joined: Dec 2003
Posts: 261
Good evening. I need to script a command that will kline channel ban list (all bans on some channel :tongue:). I don't know how to read bans into some variable or something, or maybe there's some other (better) way to do the job.
Also, bans are in format *!*@<ip> and I need to kline in format *@<ip>.

thanx!


velicha dusha moja Gospoda
#72961 27/02/04 08:35 PM
Joined: Dec 2002
Posts: 3,138
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 3,138
Something like:
Code:
raw 367:*:{
  if ( $2 == [color:green]#channel[/color] ) {
    kline $gettok($3,2,33) Banned on $ifmatch
  }
}

should work.

Type /mode [color:green]#channel b[/color] to start it.

You could also use the IBL if you're in the channel and have the ban list, loop through $ibl(#channel,n).

#72962 27/02/04 09:49 PM
Joined: Dec 2003
Posts: 261
M
milosh Offline OP
Fjord artisan
OP Offline
Fjord artisan
M
Joined: Dec 2003
Posts: 261
Thank you, man... If anybody needs a code here it is (thanx to Collective):
Code:
  set %i 0
  :start
  if (%i == $ibl(#,0)) goto end
  inc %i
  kline $gettok($ibl(#,%i),2,33) Klined
  mode # -b $ibl(#,%i)
  goto start
  :end
  echo -s Banning of ban list on channel # is over.

Note: Not tested and not optimized!


velicha dusha moja Gospoda

Link Copied to Clipboard