mIRC Home    About    Download    Register    News    Help

Print Thread
reply message when joining a channel #196633 20/03/08 10:28 PM
Joined: Mar 2008
Posts: 4
M
mafanda Offline OP
Self-satisified door
OP Offline
Self-satisified door
M
Joined: Mar 2008
Posts: 4
Hi,
Im writing an irc-bot of my own and cant just find the correct spec for the JOIN-command.
Aren't the other members of the channel supposed to get a
message when a new user joins the channel?
Of course they are, I just cant find the correct RFC-specs.
Got any suggestions?

Thanks!

Re: reply message when joining a channel [Re: mafanda] #196634 20/03/08 10:29 PM
Joined: Oct 2003
Posts: 3,918
A
argv0 Offline
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
Use RFC 1459 http://www.mirc.co.uk/help/rfc1459.txt

Everything you need is in there


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Re: reply message when joining a channel [Re: argv0] #196635 20/03/08 10:31 PM
Joined: Mar 2008
Posts: 4
M
mafanda Offline OP
Self-satisified door
OP Offline
Self-satisified door
M
Joined: Mar 2008
Posts: 4
Yup, I've read it.
Can't find anything about messages sent to other members,
though.

Re: reply message when joining a channel [Re: mafanda] #196636 20/03/08 10:36 PM
Joined: Dec 2002
Posts: 2,962
S
starbucks_mafia Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 2,962
I'm confused. You're talking about making an IRC bot, which normally means an automated client user that connects to an IRC server, however you're talking about sending a JOIN message to all other users. If you really are implementing an IRC bot (as in a client) then you don't need to worry about that, the JOIN message is automatically propagated to other users by the server when you successfully join a channel.


Spelling mistakes, grammatical errors, and stupid comments are intentional.
Re: reply message when joining a channel [Re: starbucks_mafia] #196637 20/03/08 10:43 PM
Joined: Mar 2008
Posts: 4
M
mafanda Offline OP
Self-satisified door
OP Offline
Self-satisified door
M
Joined: Mar 2008
Posts: 4
Hi,
and thanks for your incredibly quick responses, should I
be worried smile

Ok, What Im essentially doing is writing a bot in the sense that it is a scriptable client. One of the tasks I have to solve for one of its upcoming nifty feature is the problem I so clumsily described above; I really need to get a notification when a user enters the channel that Im on. The message that I'm talking about is one that supposidly is sent to all members of the channel when a new member joins. This is the message that i desperatly need to capture.

Cheers!

Re: reply message when joining a channel [Re: mafanda] #196638 20/03/08 10:51 PM
Joined: Dec 2002
Posts: 2,962
S
starbucks_mafia Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 2,962
OK, in that case the JOIN message you receive from others will look something like this:

Code:
:joininguser JOIN :#joinedchannelname


The exact format of joininguser varies depending on the server, but generally it will be a full nickname!ident@hostname.com. The colon (:) before the channel name is also optional. This is briefly described in the "Join message" section of RFC 1459 (section 4.2.1) however it's not very well explained.

As a note, you can use mIRC's debugging feature to see the exact raw messages it sends to and receives from the server. For example type /debug @debug and the @debug custom window will list all traffic.


Spelling mistakes, grammatical errors, and stupid comments are intentional.
Re: reply message when joining a channel [Re: starbucks_mafia] #196639 20/03/08 11:02 PM
Joined: Mar 2008
Posts: 4
M
mafanda Offline OP
Self-satisified door
OP Offline
Self-satisified door
M
Joined: Mar 2008
Posts: 4
Greatm thanks!
Now I got it.

For some strange reason mIRC isn't compiled for any *nix so its not an option for me.
Well, thanks alot for the help, greatly appreciated!


Re: reply message when joining a channel [Re: mafanda] #196642 21/03/08 12:25 AM
Joined: Oct 2003
Posts: 3,918
A
argv0 Offline
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
That's not really strange, mIRC is an IRC client for the Windows operating system-- always has been.


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Re: reply message when joining a channel [Re: mafanda] #196643 21/03/08 01:08 AM
Joined: Dec 2002
Posts: 503
B
Bekar Offline
Fjord artisan
Offline
Fjord artisan
B
Joined: Dec 2002
Posts: 503
In any case there are plenty of existing clients for *nix platforms, including epic/ircII, bitchx, xchat, ircs, etc. etc..

All of these have existing scripting languages and structures of which 'bots' have been made in the past.

If you're programming a bot from scratch, possibly you want to look closer at the eggdrop stuff.

In any case, the RFC has all of this basic information in it. Coupled with a basic understanding of IRC in general, you shouldn't have any issues.