mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Dec 2002
Posts: 99
M
MDA Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Dec 2002
Posts: 99
Greetings and Well Met,

We posted this request originally in the Scripts and Popups help area, some 40 read the request, none offered any help. We're respectfully reposting this in the mIRC help forum to see if someone can help provide a solution.

I'm having problems automatically updating and changing our chat channel Topics which are displayed in the network server and on the top title bar in mIRC when connected in a multi-session mIRC mode (4 different chat channels, 4 different networks).Yes the manual method works in pulling up the mIRC chat central submenu and manually updating our channel Topic one at a time for each chat channel, we don't want to do that, we want to write a short routine by which we can automatically update each of our 4 mIRC multi session channels.

Normally in a single session mIRC mode for most IRC chatrooms this is simply accomplished by a similar command to this:

Topic %roomname %topic

However in multi sessons in mIRC the IRC network doesn't accept that command, likely its looking for which server connection that is being sent to and ignoring it since its not correct.

I've tried these which failed:

Topic %roomname %topic
scid -at1 Topic %roomname %topic

On our 3rd connection a moment ago I tried this which failed to work also:

scon 3 Topic %roomname %topic

I suspect the solution is gong to be something similar to this routine:

sockwrite -tn xyz.server. $+ $cid TOPIC %roomname : $+ %topic

Additional Update:
Using /debug @debug and then manually entering the channel topic using mIRC Channel Central on that channel shows the following server commands sent and recieved when that is successfully occuring.

-> Whatever.CA.us.something.org NICK :Me
-> Whatever.CA.us.something.org TOPIC #channelname :Newtopic
<- :Me!Me2@11-218-99-99.ca.whatever.com TOPIC #channelname :Newtopic


I'm certain that plenty of folks have solved this problem and appreciate your help and suggestions.

MDA

Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
scon and scid evaluate things an extra time so any %variables or $identifiers inside the text will be evaluated, try this:

Code:
scon 3 Topic % $+ roomname % $+ topic


New username: hixxy
Joined: Dec 2002
Posts: 99
M
MDA Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Dec 2002
Posts: 99
Greetings Tidy-Trax,

I quickly placed the four following routines into our Alias folder to try out various variations on your suggestion, none of them worked:

topic1 {
scon 1 Topic % $+ %Room1 % $+ %defaultopic
}
topic2
scon 2 Topic % $+ #channel2 % $+ whatever topic
}
topic3 {
scon 3 Topic % $+ #LocalHaunt % $+ %defaultopic
}
topic4 {
scon 4 Topic % $+ %Room4 % $+ %defaultopic
echo %defaultopic
}

Even hand coding the channel name and a test dummy topic didn't get any of those to function, any further suggestions to try?

MDA

Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
That's not what I meant, you still left all of the variables in like they were before. This is what I meant for you to try:

Code:
topic1 { scon 1 Topic % $+ Room1 % $+ defaultopic }
topic2 { scon 2 Topic #channel2 whatever topic }
topic3 { scon 3 Topic #LocalHaunt % $+ defaultopic }
topic4 {
  scon 4 Topic % $+ Room4 % $+ defaultopic
  echo %defaultopic
}


New username: hixxy
Joined: Dec 2002
Posts: 99
M
MDA Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Dec 2002
Posts: 99
Greetings Tidy_Trax,

You suggested I try the following formats:

topic1 { scon 1 Topic % $+ Room1 % $+ defaultopic }
topic2 { scon 2 Topic #channel2 whatever topic }
topic3 { scon 3 Topic #LocalHaunt % $+ defaultopic }

I've tried each and every variation on your suggestions, none of them work.

%RoomX matches that channel name #Whatever
%defaultopic is the default we want to include for each chan.

topic1a { scon 1 Topic % $+ Room1 % $+ defaultopic }
topic1b { scon 1 Topic #MyRoom1 whatever topic }
topic1c { scon 1 Topic #MyRoom1 % $+ defaultopic }

I repeated and tested your suggestion also on Scon 2, 3, 4 with the adjustment of #MyRoomX and %RoomX. None of those suggestions worked.

Any further suggestions on what might work?

MDA

Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
They work fine for me so I don't know what to suggest really, you could try using ! to make sure the built-in commands are used:

Code:
topic1a { !scon 1 !Topic % $+ Room1 % $+ defaultopic }
topic1b { !scon 1 !Topic #MyRoom1 whatever topic }
topic1c { !scon 1 !Topic #MyRoom1 % $+ defaultopic }


Also, you should be putting the above in Aliases, not Remote.


New username: hixxy
Joined: Dec 2002
Posts: 99
M
MDA Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Dec 2002
Posts: 99
Excellant Tidy_Trax!

The first one I tried worked perfectly and I copied that alias out for each of our 4 different chatrooms with each one working perfectly:

alias atopic1 {
!scon 1 !Topic % $+ Room1 % $+ defaultopic
}
alias atopic2 {
!scon 2 !Topic % $+ Room2 % $+ defaultopic
}
alias atopic3 {
!scon 3 !Topic % $+ Room3 % $+ defaultopic
}
alias atopic4 {
!scon 4 !Topic % $+ Room4 % $+ defaultopic
}

Thank you Tidy_Trax for your patience and your help,
MDA

Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
Np smile

If the code I gave you above works fine then you have an alias that's overwriting the built-in /scon or /topic commands, you can use the following to get the files they are in:

Code:
//echo -a /topic: $isalias(topic).fname - /scon: $isalias(scon).fname


Then you can remove the aliases if you like.


New username: hixxy

Link Copied to Clipboard