i was trying to get this mass voice tcl (with delay) to voice first stacked nicks of 6 (or less if there are less then 6 to voice) instant and the rest with delay, but i couldnt figure a way to achieve this perhaps someone of you knows a of a proper method to achieve this.
bind pub -|- .mv voice_all
bind pub -|- !mv voice_all
proc voice_all {nick host hand chan text} {
if {![isop $nick $chan] && ![ishalfop $nick $chan] && ![matchattr $hand o|o $chan]} { return 0 }
set userList [chanlist $chan]
set pos [lsearch -nocase $userList $::botnick]
set userList [lreplace $userList $pos $pos]
foreach user $userList {
if {![isvoice $user $chan] && ![isop $user $chan] && ![ishalfop $user $chan] && ![matchattr [nick2hand $user] of|of $chan]} { lappend voiceList $user }
}
# define the max amount of modes per line
set max 6
# op all the members in the above built voice list
if {[info exists voiceList]} {
set voiceList [lsort -unique $voiceList]
set len [llength $voiceList]
while {$len > 0} {
if {$len > $max} {
set mode [string repeat "v" $max]
set users [join [lrange $voiceList 0 [expr {$max - 1}]]]
set voiceList [lrange $voiceList $max end]
incr len -$max
} else {
set mode [string repeat "v" $len]
set users [join $voiceList]
set len 0
}
incr counter 1
after [expr {$counter*4000}] [list putnow "MODE $chan +$mode $users"]
}
puthelp "NOTICE $nick :Voiced all users on $chan."
} else {
puthelp "NOTICE $nick :Nobody needed to be Voiced on $chan."
}
}
i think i found a way to achieve that and it seems to work as expected thanks DasBrain for helping trying to find solutions wich is always apreciated as always.
simo wrote: ↑Mon May 13, 2024 9:47 am
pushmode doesnt allow custom delay wich is what im after as delay i want to use differs from network to network as well as stacked modes per line.
The number of stacked modes allowed by the server is usually sent by the server itself (and I think eggdrop use it).
Concerning the delay... Why do you want to use another one than the eggdrop's one ?