Currently:

Arrays are supported by two methods,

var %bar = 1
var %foo $+ %bar = baz
echo -a $($+(%,foo,%bar),2)
Return: baz


otherwise

var %bar = 1
var %foo $+ %bar = baz
echo -a %foo [ $+ [ %bar ] ]
Return: baz


This is all fine and good, but very difficult to read, especially with multi-dimensional array variables mixed into other code.

echo -a $regsubex($($+(%,foo.,%bar,.,$cid,$chan),2),/(.)/g,/$quux(\1))
echo -a $regsubex(%foo. [ $+ [ %bar ] $+ . $+ [ $cid ] $+ [ $chan ] ],/(.)/g,/$quux(\1))


Suggestion:

Allow for visually simplistic and easy to read arrays in a format most people are already familiar with and can be easily taught and explained.

var %bar = 1
var %foo[%bar] = baz
echo -a %foo[%bar]
Return: baz

echo -a $regsubex(%foo[%bar][$cid][$chan],/(.)/g,/$quux(\1))


The parser would detect for [] pairs in the variable name, determine if its contents is an evaluate-able variable or identifier, and evaluate that contents as necessary to build the variable name. The []'s would be string literal and an actual part of the variable's name itself. In the /echo example above, the variable would have literally been named:

%foo[1][325][##mIRC]

from

var %foo[%bar][$cid][$chan] = The quick brown fox.

Thus:

var %bar = 1
var %foo[%bar] = baz
echo -a %foo[%bar]
echo -a %foo[1]
Returns: baz


Well. At least I won lunch.
Good philosophy, see good in bad, I like!