mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Sep 2005
Posts: 5
O
oshru Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
O
Joined: Sep 2005
Posts: 5
i want to relay the msg of a nick in a network to another network's channel. what is the coad?

Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
Code:
on *:text:*:#:{
  var %text = $1-
  if ($nick == [color:red]nick[/color]) && ($network == [color:red]network[/color]) { scid -at1 if ($network == [color:red]network2[/color]) msg [color:red]#channel2[/color] % $+ text }
}

Joined: Sep 2005
Posts: 5
O
oshru Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
O
Joined: Sep 2005
Posts: 5
Quote:
Code:
on *:text:*:#:{
  var %text = $1-
  if ($nick == [color:red]nick[/color]) && ($network == [color:red]network[/color]) { scid -at1 if ($network == [color:red]network2[/color]) msg [color:red]#channel2[/color] % $+ text }
}


suppose i m in efnet in #channel1 & nick s abc.. i want to relay bcd's msg in dalnet #channel2. then what ll the coad

Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Just change the nick, channel(s), and network(s) to match your requirements. The parts in the code that are red need to be changed for your specific requirements. The parts that are in black need to be left as coded.

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
As was already said, you just replace the red information. Here's an example.

Code:
on *:text:*:[color:red]#channel1[/color]:{
  if ($network != [color:red]Efnet[/color]) return
  if ($nick == [color:red]oshru[/color]) && ($network == [color:red]Efnet[/color]) {
   scid -at1 if ($network == [color:red]Dalnet[/color]) msg [color:red]#channel2[/color] $1-
  }
}


Note that I also added a check so it will copy text only from #channel1 on network1 rather than any channel on network1, or from #channel1 on any channel.

Now, the only thing you'd replace the channels (assuming you want it from your nick and you want those particular networks... otherwise, replace all the reds).

As it is currently written, it will relay all messages from your nick in Efnet #channel1 to Dalnet #channel2. If the networks are reversed of what you want, just change them. If you don't want it from your nick, change the nick.

Just change anything red to whatever you need.


Invision Support
#Invision on irc.irchighway.net

Link Copied to Clipboard