This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

unlock channel with pub command

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
s
simo
Revered One
Posts: 1106
Joined: Sun Mar 22, 2015 2:41 pm

unlock channel with pub command

Post by simo »

i was trying this out to check channel modes and remove if present
it works fine for the first few modes but not for the channel modes that have a second parameter like:

+k secretkey
it wont accept a mode #channel -k
it needs the key as well to get removed

it wont accept a mode #channel -k key

using this atm:

Code: Select all

bind pub -|- .unlock pub:checkcmodez

proc pub:checkcmodez {nick host hand chan text} {
       if { [string first R [getchanmode $chan]] != -1} {  pushmode $chan -R  }
       if { [string first i [getchanmode $chan]] != -1} {  pushmode $chan -i  }
       if { [string first M [getchanmode $chan]] != -1} {  pushmode $chan -M  }
       if { [string first l [getchanmode $chan]] != -1} {  pushmode $chan -l  }
       if { [string first k [getchanmode $chan]] != -1} {  pushmode $chan -k  }
}


also when using the [getchanmode $chan]
it doesnt seem to show all set cjannelmodes

for example i have set this on channel:

+BCEFGJPTUWfjknrtx block:30:90 ~1:10 3:3 5 c4:2 ~3:2 4:2 jhjhd 1:10:10


yet [getchanmode $chan] shows just : +CtrTnkl jhjhd 33

whats the reason for that is it the channelmodes arent part of what eggdrop recognizes as its default core channel modes and if so would there be a way to display all parameters of the set channel modes ?
User avatar
CrazyCat
Revered One
Posts: 1297
Joined: Sun Jan 13, 2002 8:00 pm
Location: France
Contact:

Post by CrazyCat »

getchanmode sees only the RFC1459 modes.
MenzAgitat creates a little hack for that: https://forum.eggdrop.fr/Alternative-a- ... -1437.html

Sorry, the forum and explanations are in french :)
s
simo
Revered One
Posts: 1106
Joined: Sun Mar 22, 2015 2:41 pm

Post by simo »

thanx crazycat im not sure how to use that tho for example to check for certain cmodes
s
simo
Revered One
Posts: 1106
Joined: Sun Mar 22, 2015 2:41 pm

Post by simo »

ive added it to tcls but im not sure how to use this tho
Post Reply