# Change scenes from within a movie clip

**URL:** <https://forum.kirupa.com/t/change-scenes-from-within-a-movie-clip/2670>\
**Category:** flash\
**Created:** [May 10, 2002, 4:12am UTC](https://forum.kirupa.com/t/change-scenes-from-within-a-movie-clip/2670 "2002-05-10T04:12:52Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 10, 2002, 4:12am UTC](https://forum.kirupa.com/t/change-scenes-from-within-a-movie-clip/2670/1 "2002-05-10T04:12:52Z")

</div>

I’m writing a simple game with Flash and I need to change the scene from inside a movie clip instance. I know how to change scenes with a button, but I can’t seem to get the scene to change when certain criteria are met. For example inside a movie clip object I have this:

if(\_root.score \> 100)  
\_root.gotoAndPlay(“Congrats”, 1)

but the scene doesn’t change. What am I doing wrong?

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 10, 2002, 7:20am UTC](https://forum.kirupa.com/t/change-scenes-from-within-a-movie-clip/2670/2 "2002-05-10T07:20:07Z")

</div>

use frame labels, instead of frame numbers.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2002, 1:22am UTC](https://forum.kirupa.com/t/change-scenes-from-within-a-movie-clip/2670/3 "2002-05-14T01:22:55Z")

</div>

I dont see where you’re telling it to change scenes.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2002, 3:39am UTC](https://forum.kirupa.com/t/change-scenes-from-within-a-movie-clip/2670/4 "2002-05-14T03:39:31Z")

</div>

He renamed his scene to be “congrates”, I’m assuming.

I didn’t really explain well the frame label thing either so I’ve opted to make another reply. 🙂

The deal with scenes is this… in a final production the frame numbers just extend from 1 to whatever no matter what scenes they run into … I know that doesn’t make a whole lot of sense… it certainly confuses me.

To set a frame label, open your “Frame” panel. create a blank layer and where ever you would like a label for a goto statement, place a blank keyframe. Then with that frame selected, type in a frame label in the “Frame” panel.

then your goto statement would look something like

on(release){  
gotoAndPlay(“congrates”,“myFrameLabel”);  
}
