mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Apr 2005
Posts: 26
D
Ameglian cow
OP Offline
Ameglian cow
D
Joined: Apr 2005
Posts: 26
is there some trick to getting the $nick(#channelname,1) identifier to work with multiple networks i tried using
/scid 1 /set %x $nick(#channelname,1)
with a channel that was on $cid 1 and i get
* /set: invalid parameters
in the status window
/set %x $nick(#channelname,1)
works fine if im only on one network though
any ideas?

Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
You could try something like..

[code]
alias vars {
var %x = $scon(0)
while (%x) {
if ($scon(%x).status == connected) {
scon %x set $($(%nicks.,0) $+ $server,0) $nick($$1,1)
}
dec %x
}
}
[code]

Syntax: /vars #channel

Edit: removed unwanted character.

Joined: Apr 2005
Posts: 26
D
Ameglian cow
OP Offline
Ameglian cow
D
Joined: Apr 2005
Posts: 26
ok cool i was able to use a bit of that

Last edited by DaICeMaN; 27/04/05 04:58 AM.
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
The first connection ID ($cid)? Where did all the networks come into it then?

I've not tested it but it should set set a var on each network like..

%nicks.Network Nickname

Joined: Apr 2005
Posts: 26
D
Ameglian cow
OP Offline
Ameglian cow
D
Joined: Apr 2005
Posts: 26
ok i got this to work (kinda) i have the $cid # the channel and the number that specifys wich nick in the list set to variables
/scid %viewcid /did -a testlist 74 $nick(%viewc,%viewn)
and it works fine when set too /scid 1 for all the channels im in on that $cid but if i set it to any other $cid it just adds a blank line instead of a nick

Last edited by DaICeMaN; 27/04/05 05:32 AM.
Joined: Apr 2003
Posts: 701
K
Hoopy frood
Offline
Hoopy frood
K
Joined: Apr 2003
Posts: 701
From help file: Note: If you use a command that contains $identifiers, and you want the identifiers to be evaluated in the target connection, you must pass them as $!identifier to prevent them from being evaluated first in the current connection.

//scid 1 set $(%x,0) $!nick(#channelname,1)

This re-evaluation in /scon and /scid has been a source of bugs and exploits, so maybe it's best to use the following in scripts and aliases:

scid 1
command
scid -r

(for fun stuff, try this from a editbox:
/set %x %y
/set %y %z
//scon 1 set %x blah
and find out which %var is set to blah smile )

I presume the $cid is correct, to check just type $cid<tab> (no, not enter) in the actual channel window smile

Joined: Apr 2005
Posts: 26
D
Ameglian cow
OP Offline
Ameglian cow
D
Joined: Apr 2005
Posts: 26
cool ill try it out in a bit


Link Copied to Clipboard