Go to Next Scene

Go to Next Scene
October 23, 2008 03:25PM
I'm new to using flash components and AS as well. I'm use to putting everything on one timeline and letting it play through, but now I'm working with multiple scenes.

On the first scene I have a few symbols with FlashEFf components attached to them , but how do I have one scene transition to the next?

It's hard to tell, i keep using root.goToPlay("Scene 3", 1"); and nextScene():void but none of those are working.


I"m getting the following error when using goToPlay method : 1061: Call to a possibly undefined method gotoAndPlay through a reference with static type flash.display:DisplayObject.


and when I use the nextScene method I get this and it the flash eff components blink continuously: 1078: Label must be a simple identifier.



Thanks in advance.
Re: Go to Next Scene
October 24, 2008 07:38AM
Well... first of all there is no goToPlay() method defined on the root object (I guess you are referring to gotoAndPlay()). Also, gotoAndPlay() cannot be called directly on the root object because the root object is returned as a DisplayObject and the gotoAndPlay() method is defined on MovieClip objects. So you have to typecast the root object to MovieClip ( MovieClip(this.root).gotoAndPlay(...) or (this.root as MovieClip).gotoAndPlay(...) ). The same goes for the prevScene() and nextScene() methods, they belong to the MovieClip class.

Also, to best of my knowledge, you can't really apply transitions between scenes, Flash just changes from one scene to another.
Re: Go to Next Scene
October 24, 2008 03:53PM
Sorry, I did mean gotoAndPlay(); I said transitions because when I play the movie, only one scene plays and the flasheff components blink continuously. I'll give the movie clip thing a try, but something doesn't seem right and it seems more difficult than it should be.


Thanks again for your help.
Re: Go to Next Scene
October 27, 2008 07:30AM
We have a post that might help you out when using FlashEff with multiple scenes: http://www.flasheff.com/forum/read.php?23,491.
Sorry, you do not have permission to post/reply in this forum.