This content has been marked as final. Show 4 replies
Try using gotoAndStop().
yeh that worked. weird... any idea why it was doing what it was doing though?
As I see it, if you're at frame 2, and you tell it to go to and play frame 2, it can't go anywhere, but the gotoAndPlay needs to play, and the stop that probably lives there is already spent, so it takes it to frame 3. Maybe someone else has a more accurate explanation.
when you execute gotoAndPlay(2), the playhead moves to the frame 2 and then plays.
if the playhead is already in frame 2, the playhead will not re-enter frame2 and therefore will not (re)execute any code attached to frame 2 (because code only executes when the playhead enters a frame), but it will play.
when you execute gotoAndStop(2), the playhead moves to frame 2 and stops.
if the playhead is already in frame2, the playhead will not re-enter frame 2 and therefore will not (re)execute any code in frame 2, but it will stop.