actionscript 3 - Embedded movieclip coordinates set from parent -
i have project have embedded in movieclip, when add objects based on character located, seems ignore child coordinates , place based on parent's coordinates. character placed in timeline, , i'm adding children in embedded clip's code "this.addchild()". if embedded movieclip @ (100, 100) in parent, , i'm trying add object clip, seems adding @ (150, 150) relative parent rather relative child, (250, 250) parent. i'm setting object's coordinates based on character's coordinates in embedded clip, somehow seems using global coordinates instead. how can make use character's relative coordinates?
generally, set child's position within parent's code. if b child of a, within a's code say: addchild(b); , b.x = number; , b.y = number. keyword 'this' unnecesary.
Comments
Post a Comment