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.

[Help] setting need-invite/key/op/unban in every channel

Help for those learning Tcl or writing their own scripts.
Post Reply
D
Djoezy
Voice
Posts: 6
Joined: Sun Mar 30, 2008 7:56 am

[Help] setting need-invite/key/op/unban in every channel

Post by Djoezy »

hello guys, i'm working om my own script right now.

I dont know if this is the right forum because it are eggdrop commands in a tcl script. So i thought this was the best place.

The script contains a little protection from some modes from channelusers. Like -o/kick. This works quite allright.

And i also want's too have the bot too msg Q (quakenet channel service)
too grant him op/invite/unban on the channel.
Well this is possible because i have checked it out (i set the commands in chanlist manually)

This is what is have in my script
if {[channel get $channel bot:masterflags]} {
channel set $channel need-invite {putserv "PRIVMSG Q :invite $channel"}
channel set $channel need-key {putserv "PRIVMSG Q :clearchan $channel"}
channel set $channel need-unban {putserv "PRIVMSG Q :banclear $channel"}
channel set $channel need-op {putserv "PRIVMSG Q :op $channel"}
This is a part of a script who's setting channelsetting every 6 hours.. the rest of the "channel set" works.

I want this too be like this ( this is manually done !! )
(14:38:00) ((Dizzle) To get key (need-key):
(14:38:00) ((Dizzle) putserv "PRIVMSG Q :clearchan #gather-network.chat"
Butt if i do it like the first quote, then he doesnt fill in the $channel variable. then its like this
(14:38:00) ((Dizzle) To get key (need-key):
(14:38:00) ((Dizzle) putserv "PRIVMSG Q :clearchan $channel"
I have tried several thinks like, replacing the {} for [] and "". Butt that doenst work either.

Can this be done, or should i let it slip ??
User avatar
user
 
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

Code: Select all

channel set $channel need-invite [list putserv "PRIVMSG Q :invite $channel"]
Have you ever read "The Manual"?
D
Djoezy
Voice
Posts: 6
Joined: Sun Mar 30, 2008 7:56 am

Post by Djoezy »

Sorry butt this doesnt work
channel set $channel need-invite [list putserv "PRIVMSG Q :invite $channel"]
This return
(21:39:37) ((Dizzle) To regain op's (need-op):
(21:39:37) ((Dizzle) putserv
And if i try something else like
channel set $channel need-invite { putserv "PRIVMSG Q :invite [list $channel] }
returns :

(22:00:17) ((Dizzle) To regain op's (need-op):
(22:00:17) ((Dizzle) putserv "PRIVMSG Q :op [list $channel]
Do you know what reallife means ? And where i can download it ?
D
Djoezy
Voice
Posts: 6
Joined: Sun Mar 30, 2008 7:56 am

Post by Djoezy »

Allright i'm futher right now
thanks user for pointing me the right way

Code: Select all

channel set $channel need-invite [join [list putserv "PRIVMSG Q :invite $channel "]]
he's taking over the $channel now butt not the "" in front of putserv. so it gives faults.

Any ideas

** UPDATE **

Problem solved ..

Code: Select all

channel set $channel need-invite [join [split [list putserv "PRIVMSG Q :invite $channel "]]]
will return in channelinfo
(08:34:22) ((Dizzle) To regain op's (need-op):
(08:34:22) ((Dizzle) putserv {PRIVMSG Q : op #djoezy }
Do you know what reallife means ? And where i can download it ?
User avatar
user
 
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

Your split+join is pointless. My first reply was correct.
Have you ever read "The Manual"?
Post Reply