egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How to join an invite channel?

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Eggdrop Help
View previous topic :: View next topic  
Author Message
reddy
Voice


Joined: 26 Nov 2006
Posts: 5

PostPosted: Sun Nov 26, 2006 12:30 pm    Post subject: How to join an invite channel? Reply with quote

Hey, i have a bot that needs to join private channels, via a Q auth and self invite.

I have the Q auth, how can i go about getting my bot into the private channels?

the irc commands would be /msg q invite #channel then /j channel

is it in the partyline or bot config or should i do a script? Im new to TCL and bots n stuff, but im having fun learning!!

Thanks

reddy
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2857

PostPosted: Sun Nov 26, 2006 12:41 pm    Post subject: Reply with quote

Either use "bind need" or check the need-invite channel setting;
Either allows you to trigger a piece of tcl-code to be executed when your eggdrop recieves the need-invite errorcode.

Might very well be a few such scripts in the Tcl Archive. If not, should'nt be too hard to implement, and makes nice practise in tcl coding
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
reddy
Voice


Joined: 26 Nov 2006
Posts: 5

PostPosted: Sun Nov 26, 2006 1:05 pm    Post subject: Reply with quote

nml375 wrote:
Either use "bind need" or check the need-invite channel setting;
Either allows you to trigger a piece of tcl-code to be executed when your eggdrop recieves the need-invite errorcode.

Might very well be a few such scripts in the Tcl Archive. If not, should'nt be too hard to implement, and makes nice practise in tcl coding


I've searched the archive, and its heavy duty stuff! Im getting errors when i try run the taylored scripts - Its a bit overkill imo... there has to be an easier way to do it - heres a small snippet of a script i got which is WAAAY too much detail

Quote:

bind need - "% invite" need:invite

proc need:invite {chan type} {
global botnick needinvitetype needinvitechans
if {($needinvitetype == 1) && ([lsearch -exact [split [string tolower $needinvitechans]] [string tolower $chan]] != -1)} { needinvite:chans $chan $type }
if {($needinvitetype == 2)} { needinvite:chans $chan $type }
if {($needinvitetype != 1) && ($needinvitetype != 2) || ($needinvitetype == 0)} { return 0 }
}



I know this does something totally different, but can it be done like

Quote:

bind pub - !joinInvite pub_joinInvite
proc pub_joinInvite {nick host hand chan lang text} {
putserv "PRIVMSG Q Invite #CHANNEL"
putserv "join #CHANNEL"
}


Im only coding TCL a day now, so as much detail as possible would be great
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2857

PostPosted: Sun Nov 26, 2006 1:14 pm    Post subject: Reply with quote

Actually, should you combine those two scripts, you'd have pretty much all you need. (Or well, the privmsg in the second script is slightly flawed, as you need to prepend the message with a ":", just as with any privmsg)

Although this would fit better in "Script Help"; here we go..
First scriptlet shows you how to create the binding that'll trigger the script and how the proc (function) will be called.
Second one shows what you actually want that proc todo.
Try and combine them..

Rome was'nt built in a day, so keep going Smile
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
reddy
Voice


Joined: 26 Nov 2006
Posts: 5

PostPosted: Sun Nov 26, 2006 2:01 pm    Post subject: Reply with quote

Thanks! Will do, i've book marked this, so ill keep replying to it!
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Eggdrop Help All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber