gotoAndPlay(); probs

  • groovemaize2K
  • Beginner
  • Beginner
  • User avatar
  • Posts: 38
  • Loc: UK

Post 3+ Months Ago

I'm using the gotoAndPlay(); command so I can have multiple parts in the same timeline. The first button is assigned to gotoAndPlay(41); which works fine, it plays from 41 to the next stop point. But I have assigned another button to go back and play from frame 1 with gotoAndPlay(1); but for some reason its not working. Is this because goto and play only works with frames infront of the command (I cant imagine that) Much appreciated if someone could shed a little light. Thanks Guys, Groovie...

http://www.incrediweb.co.uk
  • fotbon
  • Novice
  • Novice
  • fotbon
  • Posts: 20

Post 3+ Months Ago

check your actionscript for each frame--it sounds to me like you put in the actionscript for a single keyframe, and it didn't transfer over to the rest of the keyframes. If not that, perhaps you didn't include the _root prefix?

More specificity would help, but I hope one of those two suggestsions helps.
  • lostinbeta
  • Guru
  • Guru
  • User avatar
  • Posts: 1402
  • Loc: Philadelphia, PA

Post 3+ Months Ago

Does Frame 1 have a stop() action on it?

If so, that is what is causing your problem. The movie will gotoAndPlay frame 1, but the stop() action on frame 1 gets called as well.
  • groovemaize2K
  • Beginner
  • Beginner
  • User avatar
  • Posts: 38
  • Loc: UK

Post 3+ Months Ago

nope, theres no actions in frame 1, only a stop() in fram 40 and a stop() in frame 72. I have the gotoAndPlay() commands in 2 seperate buttons...
  • lostinbeta
  • Guru
  • Guru
  • User avatar
  • Posts: 1402
  • Loc: Philadelphia, PA

Post 3+ Months Ago

Is the button to gotoAndPlay(1) inside another movieclip or anything? If so then you need to target the correct timeline to gotoAndPlay().

Are the buttons animated in? If they are you have to make sure the actions exist on the correct instead of the button (so say you have 2 keyframes in your tween, keyframe 1 has the button with the actions, but keyframe 2s button may not have the actions on it)



If both buttons are set up the same, and gotoAndPlay(41) is working and gotoAndPlay(1) isn't and there is no stop() on frame one, then I have no clue what is up. Could you possibly post your .fla?
  • groovemaize2K
  • Beginner
  • Beginner
  • User avatar
  • Posts: 38
  • Loc: UK

Post 3+ Months Ago

I remade the button and added the script. Works fine now! :roll:

Thanks for the advice guys. Groove

http://www.incrediweb.co.uk
  • lostinbeta
  • Guru
  • Guru
  • User avatar
  • Posts: 1402
  • Loc: Philadelphia, PA

Post 3+ Months Ago

Oh... it's one of those situations.

Yeah, Flash does that sometimes, it's usually not an all the time thing, but it happens.

Post Information

  • Total Posts in this topic: 7 posts
  • Users browsing this forum: No registered users and 10 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
cron
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.