mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Aug 2003
Posts: 143
M
Vogon poet
OP Offline
Vogon poet
M
Joined: Aug 2003
Posts: 143
I am traying to make a var in a if but the var have o had %var $+ $nick. How can i do that
example:
if ( %var $+ $nick == On ) { comands }


T
theRat
theRat
T
$eval($+(%,var,$nick),2)

Joined: Aug 2003
Posts: 143
M
Vogon poet
OP Offline
Vogon poet
M
Joined: Aug 2003
Posts: 143
Humm that code you give to me don“t work, but if i put instad 2 i put 1 it works but not works very good becouse he separate the %var nick and i want %varnick all together.
And the code you just give to me make %var nick.

N
n3wb13
n3wb13
N
I didn't quite get what you mean,

but if you want to use %varNick1 %varNick2 %varNick3 as variables, when $nick is Nick1, Nick2, Nick3; you may use variables like
% [ $+ [ var $+ [ $nick ] ] ]

which are ugly, but can be used in the earlier versions of mIRC, too

I
Iori
Iori
I
Here is two ways to set and retrieve such vars...

//set -u %var $+ $me test | echo -a %var $+ $me = %var [ $+ [ $me ] ]
//set -u $+(%,var,$me) test | echo -a $+(%,var,$me) = $eval($+(%,var,$me),2)

and how to use them in /if statements...

//set -u $+(%,var,$me) test | if $eval($+(%,var,$me),2) == test { echo -a * Match: $ifmatch }

Joined: May 2003
Posts: 161
A
Vogon poet
Offline
Vogon poet
A
Joined: May 2003
Posts: 161
the fastest way is just
Code:
%var [ $+ [ $nick ] ]


Link Copied to Clipboard