actionscript 3 - Flex: moving a point with rotation doesnt change the point XY? -
actionscript 3 - Flex: moving a point with rotation doesnt change the point XY? -
i have follow issue :
i have point setted @ border on component, changed transform point center of component in order match component rotation.
the of import part when seek point xy after rotation - remains same before rotation.
how xy, after rotation ( changeing point.rotation property specific degrees of rotaion )
if want point after rotation, cos(r) * x, sin(r) * y
easiest way.
if want point after transformations, should able utilize displayobject.transform.transformpoint(x, y)
.
there's displayobject.localtoglobal
. in case phone call localtoglobal(x, y)
, localtoglobal(0, 0)
, calculate difference.
see transform livedocs , displayobject livedocs
flex actionscript-3
Comments
Post a Comment