all groups > flash actionscript > january 2005 >
You're in the

flash actionscript

group:

targeting scene in external movie clip


targeting scene in external movie clip techtigger
1/14/2005 9:35:00 PM
flash actionscript: Need some help targeting a movieclip i've loaded: I have an external movieclip
with buttons, that I load in as the website starts I have another external
movieclip (we'll call it 'content') that I want these buttons to control I can
get them to control the main timeline, but when I want to tell it to go to the
next scene, frame x, it does nothing. Here is the code I was trying: on
(release) { _root.content.gotoAndPlay('main', 2); } What am I doing wrong?
Thanks!:confused;
Re: targeting scene in external movie clip barn
1/14/2005 9:44:54 PM
Part of the problem is that there are actually TWO gotoAndPlay()s -- one is a
method and one is a function. The function accepts a parameter for a scene name
and a frame number, but cannot be preceded by a path. The method, which can
(and is usually) preceded by a path accepts only one parameter -- the frame
number or name (or a varible containing a value representing one of those two).
Secondly, scenes only exist at the _root of a given level. If you are loading
an external movie into a movieclip target, the scenes no longer exist (for all
practical purposes, they really only exist in the authoring environment,
anyway, as an authoring convenience). Best eliminate your dependence on scene
names, and use frame labels, instead.
Re: targeting scene in external movie clip techtigger
1/14/2005 9:54:47 PM
thanks! that explains much, got it all working. You'd think macromedia
would come up with a way to let you use scenes in external clips though...
(hint -hint -Yoohoo, Macromedia, anyone out there listening? ...) *grinz*
AddThis Social Bookmark Button