How can I access and modify objects inside frames with AS3 in a permanent way?
- by curro
I have a MovieClip symbol created with flash in a fla file library. There is a textfield in frame one of this movieclip's timeline . There is another frame in the movieclip timeline. There is a custon class definition for this symbol. It is a flipping card in a memory game.
I access the textfield by going to frame 2 (gotoAndStop(2)) and setting the textfield's text property ( this.field.text = "hello" ). However if I go to frame 1 and then return to frame 2, the text becomes the original one in the library's symbol. I have to modify the text propery again in a showFace method I've written.
Besides, I cannot pass parameters in the constructor because it is a symbol in the library and that would give errors.
I find this behaviour of flash extremely weird.
Is there a way I can set properties inside frames permanently?
Thank you