Please disregard, I figured it out wink

mmm.. first post..
now, strait to the point. I'm trying to make a script to scramble words. here is what I have so far:
Code:
on *:text:!scramble*:# {
  set %unscrambled $$2
  set %scrambled.len $len($$2)
  set %charnumber 1
  :line
  if $var(%scrambled.char.*,0) == %scrambled.len {
    goto line2
    var %tempscramble 1
  }
  else {
    set %scrambled.char. [ $+ [ %charnumber ] ] $mid($$2,%charnumber,1)
    inc %charnumber 1
  }
  goto line
  :line2
  set %tempvar $var(%scrambled.char.*,$rand(1,$var(%scrambled.char.*,0)))
  echo %tempvar
} 


so, after it selects one of the letters randomly, it puts it into a variable, my problem is, the variable is this:
%tempvar %scrambled.char.3
%scrambled.char.3 is "g"

I need to know how to make it evaluate that variable, so that it returns "g" instead of "%scrambled.char.3". The rest will be easy..

Thx in advance.

~spling


Last edited by spling; 11/01/04 09:12 PM.