mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Jul 2004
Posts: 59
L
Babel fish
OP Offline
Babel fish
L
Joined: Jul 2004
Posts: 59
Hi,

What I am trying to do is echo text typed on Server 1 channel 1 to server 2 channel 2 and vise versa without repeating the typed text in the channel in which it was typed.

This is what I have in my bot right now but it echos the text in the same channel it was typed as well which just wont work .

on *:Text:*:#: {
scon -at1 /amsg $nick $1-
}

Thanks for any help

Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
Im going to assume that you are only on these two servers since your the one using scon -at1

Code:
on *:Text:*:#channel1: {  var %nick = $nick | var %text = $1- | scon -at1 if ( $!cid != $cid ) msg #channel2 % $+ nick % $+ text }
on *:Text:*:#channel2: {  var %nick = $nick | var %text = $1- | scon -at1 if ( $!cid != $cid ) msg #channel1 % $+ nick % $+ text }


i simply check if the $cid of the currently executing code is not equal to the $cid of the event triggering code, and only then msg the channel with the message.

I didnt understand why u were using /amsg tho.?

[edit]
I removed using /msg #channel? $nick $1- since they get pre evaluated and thus could be used to exploit you, this way there stored and used as what they are two texts.

Last edited by DaveC; 06/02/05 01:46 AM.

Link Copied to Clipboard