can you use any identifiers inside rgb identifier?
like:
alias myidentifier return 100,100,100
echo -a $myidentifier (works)
echo -a $rgb($myidentifier) (it doesnt)
//echo -a * $rgb($gettok($MyIdentifier,1,44),$gettok($MyIdentifier,2,44),$gettok($MyIdentifier,3,44))
* 6579300
$rgb expects 3 parameters, not 1 parameter with commas.
emm thanks, I was missunderstanding that
you could also do echo -a $rgb( [ $myidentifier ] )
Interesting that [ ] worked when $eval() wouldn't. Good job finding that, though it does mean perhaps a rethink on when to use [ ] and when to use $eval( ,2).
That's because [ ] brackets and $eval are not the same thing; they are designed for different purposes. $eval evaluates any variables/identifiers in the string and only that. Brackets, otoh, control the order of evaluation, something that $eval was not designed to do of course. So, in $rgb( [ %var ] ) , mirc evaluates %var before it deals with $rgb. (contrary to $rgb(%var), in which %var is evaluated after $rgb is parsed, so %var is considered a parameter).