Okay, so I’m using something similar to a tank in a .fla project of mine. There is one MovieClip that is moved using the arrow keys, and a turret that is placed on top of the moving MovieClip that rotates with other keys. The rotating turret must create more instances of a specific class upon the pressing of the space bar. So far so good. Now here’s my problem. The spot where I want the new instances to be created does not a a constant set of x and y coordinated. I want it to be located at the edge of the turret, as far away from the rotation point as possible.
Here’s an example:
O–
I want the instances’ starting x and y coordinates to match that of the end of the long stick in the turret MovieClip.
|
|
0
Now the coordinates of the end of the turret are different.
How can I make it so that no matter what the rotation of the turret is, the instances’ starting x and y coordinates will be the same as the end of the turret’s stick.
I’m not sure I explained that too well, but, can someone please help me? Thanks in advance =D