Code: Select all
putserv +a
Once upon a time , I fiddled with this sort of thing that you started this thread about.simo wrote: ...
and after max modes per line allowed on ircd has been exceeded it wont set at all
Code: Select all
# Some networks allow you to stack lots of channel modes into one line.
# They're all guaranteed to support at least 3, so that's the default.
# If you know your network supports more, you may want to adjust this.
# This setting is limited to 6, although if you want to use a higher value,
# you can modify this by changing the value of MODES_PER_LINE_MAX in
# src/chan.h and recompiling the bot.
#set modes-per-line 3
Code: Select all
proc stackBans {chan banlist} {
set max 25
set count [llength $banlist]
while {$count > 0} {
if {$count> $max} {
set mode [string repeat "b" $max]
set masks [join [lrange $banlist 0 [expr {$max - 1}]]]
set banlist [lrange $banlist $max end]
incr count -$max
incr total $max
} else {
set mode [string repeat "b" $count]
set masks [join $banlist]
incr total $count
set count 0
}
putnow "MODE $chan +$mode $masks"
}
}
Code: Select all
proc massmode {chan mode arg} {
scan $mode {%[-+]%[bov]} p m
set j [llength $arg]
set k [expr {${::modes-per-line}-1}]
set out "";
for {set i 0} {$i<$j} {incr i} {
set args [lrange $arg $i [incr i $k]]
append out "MODE $chan $p[string repeat $m [llength $args]] [join $args]\n"
}
putdccraw 0 [string len $out] $out
}
?+vvv+bbb A B C *!*@a.com *!*@b.com *!*@c.com
17:34:22 <+simo> .b Anaya Archibald Arturo Ashleigh Benjamin Britton Carlito Eartha Frame Holley Homer Lange Lavender Layla Leary Mcgrath Mckenna Mendenhall Proffitt Saenz Salerno Samuel Sharkey Simone
17:34:22 @TCL-Tester Sets Mode on #tcl-test to: +bbbbbbbbbbbbbbb *!*@123.149.76.44 *!*@nqpu:lqx1:0:e565::yr4u:r40g *!*@4MSJ76KF.IGHX27CM.2G2DUIY0.IP *!*@kn2l:s86p:8:e321::8802:98d2 *!*@31.222.222.232 *!*@112.97.54.150 *!uid304591@* *!*@a247:6384:3:3veg::k0n8:vi9u *!*@23.13.13.12 *!uid73149@* *!*@BVRQVAGE.S4KES3EI.I12G26PR.IP *!*@131.178.177.68 *!*@81.81.182.78 *!*@0m1f3:r6lc::v055:iy8q *!*@50.150.158.125
17:34:22 (13 Users) Are Banned Anaya Archibald Arturo Ashleigh Benjamin Britton Carlito Frame Holley Homer Lange Lavender Leary
17:34:22 @TCL-Tester Sets Mode on #tcl-test to: +bbbbbbbbb *!sid27555@* *!*@133.81.84.82 *!*@80.23.182.76 *!*@233.331.11.233 *!*@Cloaked-b6r.530.61.13.IP *!*@Cloaked-u0i.890.20.71.IP *!uid41669@* *!sid24364@* *!*@19.39.234.95
17:34:23 (9 Users) Are Banned Mcgrath Mckenna Mendenhall Proffitt Saenz Salerno Samuel Sharkey Simone
17:34:23 @TCL-Tester Sets Mode on #tcl-test to: -vvvvvvvvvvvvvvv Anaya Archibald Arturo Ashleigh Benjamin Britton Carlito Eartha Frame Holley Homer Lange Lavender Layla Leary
17:34:23 @TCL-Tester Sets Mode on #tcl-test to: -vvvvvvvvv Mcgrath Mckenna Mendenhall Proffitt Saenz Salerno Samuel Sharkey Simone
Code: Select all
Sorry if this sounds stupid, but is that 'a' a valid or even allowed channel mode in the first place?
Btw, putdccraw was deprecated so instead you should use putdcc or putnow (have a look at 'scripts/compat.tcl' that comes with the eggdrop).
Code: Select all
if it's for pushmode +a for admin of a user thats different