-
i understand getProperty(target,property)
and how to access _x and _y of a MC... but how do i get the _x and _y of an embeded MC relative to the stage...not its own internal "space". please help... thanks in advance
[en]
-
FK Supermodel
xpos=_root.target._x;
ypos=_root.target._y;
another
xpos=_root.target.mytarget._x;
ypos=_root.target.mytarget._y;
-
yes, those give back the _x and _y values of the MC position inside the MC but not the _x _y position of acording to their location on the stage.
--> make a MC, place it inside another MC... make the top MC draggable... now try to get the _x and _y value of the MC inside the draggable MC... it won't change since it is giving back only its position in the MC not its positon on the stage.
i'm trying to make a draggable object that has MCs inside that when moved each internal movie clip might conditionally activate a different function
even though, i'll try again -- thanks for your help....
[en]
-
But the first draggable mc's coordinates are available relative to the stage, right? Then if your nested mc is not moving inside the draggable mc, just add the coordinates' offset of this nested mc relative to the first mc, thus getting it's position on stage.
-
cool... that's pretty simple... should have thought of that one.. but i thought there might be a way to just call the value... i know a little math won't kill me =] just thought there might be an easier way...
thanks
[en]
-
I'm not saying there isn't an easier way! Just that I guess this workaround would work!
-
it did...
but i need to rethink since i am hoping to scale my draggable MC.. and scaling doesn't work with that work around [so far]....
it does solve another problem... thanks for your help
[en]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|