mIRC Home    About    Download    Register    News    Help

Print Thread
#139931 20/01/06 02:48 AM
Joined: Jan 2006
Posts: 4
P
PoPcorn Offline OP
Self-satisified door
OP Offline
Self-satisified door
P
Joined: Jan 2006
Posts: 4
well i have the following code
on *:TEXT:*:#:{ if ($1 = .set){ set %$2 $3-}}}
that will set the variable name as %$2, but i want whatever text $2 is to be the vaiable name, say if .set egsample is entered, how would i edit this script so that the variable name would become %egsample instead of %$2?

im new to mirc scripting blush
(the above code is an abrieviated version of what i have allready done)

Joined: Feb 2004
Posts: 206
D
Fjord artisan
Offline
Fjord artisan
D
Joined: Feb 2004
Posts: 206
Code:
  
on *:TEXT:.set *:#:{ 
   set % $+ $2 $3-
} 


for further background you can check /help $+ (under the Alias section)

Cheers,

DK


Darwin_Koala

Junior Brat, In-no-cent(r)(tm) and original source of DK-itis!
Joined: Mar 2005
Posts: 212
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Mar 2005
Posts: 212
Code:
on *:TEXT:*:#:{
  if ($1 == .set) {
    set $+(%,$2) $3-
  }
}

Last edited by NeUtRoN_StaR; 20/01/06 03:55 AM.
Joined: Jan 2006
Posts: 4
P
PoPcorn Offline OP
Self-satisified door
OP Offline
Self-satisified door
P
Joined: Jan 2006
Posts: 4
thx works a charm laugh

Joined: Mar 2005
Posts: 212
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Mar 2005
Posts: 212
i left out an = on accident
i edited the code it should be all right now


Link Copied to Clipboard