I cant get the this[] keyword to work.
I want to send a string to a function and then, via the string reference a Sprite. Are theire any other ways to adress a sprite with a String value?
I thought this[myString].alpha = 0.5; was gonna do the trick but i keep getting (1010: A term is undefined and has no properties.). I tried every possible solution it feels like. Delaring Strings locally and Global…but i can´t get it to work. And the String is well spelled btw!
//Nothing Works
this["myString"].alpha = 0.5;
this[myString].alpha = 0.5;
//Anyway to reference a Sprite with a String???
Anyone…???