Quote:
Originally Posted by Skyld
Hmm, makevar() is quite untidy. :| Does (@ "foo") or so do anything in place of makevar()?
|
Still nothing :[
PHP Code:
enum test
{
foo = "bar",
bar = "foo"
}
function onCreated()
{
temp.a = "foo";
echo( "TEST:" SPC test.( @ temp.a));
echo( "TEST:" SPC test.( @ "foo"));
echo( "TEST:" SPC test.foo);
}
Produces
HTML Code:
TEST:
TEST:
TEST: bar
same with this..
PHP Code:
enum category
{
Weapons,
Accorories,
Armor,
Potions,
Quest,
Food,
Misc
}
function onCreated()
{
this.category = "Food";
this.category_index = category.(@ this.category);
echo( this.category @ ":" SPC this.category_index);
}
produces