I’m importing external vars using loadVariablesNum() from .txt files. I know that each variable must be surrounded by amperstands (&) in order define the start and end of each variable.
ie:
&var_1=abc&
&var_2=xyz&
And then I want to use something like:
[AS]mc.gotoAndPlay(_level#.var_1);[/AS]
But my question is (for simplicity), is there a way to do this if the amperstand at the end is not included, such as:
ie:
&var_1=abc
&var_2=xyz
Flash returns the first variable above as var_01="abc
" which is understandable since it was not closed properly. However, I want to be able to use the gotoAndPlay(); with var_01="abc
". I have tried labelling the frame with abc
, but that didn’t work.
I also tried using frame_array = new Array(_level#.var_1.split("\r")); and then said gotoAndPlay(frame_array[0]); but for some reason I couldn’t get this to work either…
Any suggestions? Thanks.