Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Lets say I have a graphic that I wa 1

Status
Not open for further replies.

okiiyama

IS-IT--Management
Jan 3, 2003
269
US
Lets say I have a graphic that I want to animate using buttons. So the graphic can move forward, backward, stop, and possibly a reset that would bring it to its initial position.

Is there something that would allow me to access the graphic's center coordinates? so essentially, by changing the center's coordinates, I am in fact moving the graphic?

Right now I can make a forward button, and a stop button using the gotoAndPlay() method, but I don't know how to program reverse. I thought about it, and didn't like the answer if I were to rely on the timeline. Using the Center coordinates, I would not need to depend on the timeline.(I think).
Any hints would be great.
 
Thanks for that link....and so far it has proven very helpful. And now I have

How do I ensure that the starting position of the clip is its initial position?. My clip is in one place before I hit 'forward' and then after I click forward, it first shifts and then starts moving.

 
set the initial points in actionscript in the frame actions

clip._x = 100;
clip._y = 200;

clip the instance name

just change the numbers to the ones you want
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top