In an AS2 file I create a movieClip.Next, I define the movieClip as a component. In the component definition dialog, I define a component variable:
Name:My Variable, Variable:myVar, Default:32, Type:Number
In the script for the component I write "trace('this.myVar')". Compile and run, and the output is "32" as expected. Now I place another instance on the stage and set the value of My Variable to 27 in the Parameters dialog, compile & run, and the output is "32" and "27" as expected.
Now I convert to AS3. This time, the output is "undefined" and "27." For some reason, AS3 doesn't like the default variable setting. Any ideas what's going on here?
Name:My Variable, Variable:myVar, Default:32, Type:Number
In the script for the component I write "trace('this.myVar')". Compile and run, and the output is "32" as expected. Now I place another instance on the stage and set the value of My Variable to 27 in the Parameters dialog, compile & run, and the output is "32" and "27" as expected.
Now I convert to AS3. This time, the output is "undefined" and "27." For some reason, AS3 doesn't like the default variable setting. Any ideas what's going on here?