dcsimg
A Flash Developer Resource Site

Results 1 to 15 of 15

Thread: navigating between scenes

  1. #1
    Junior Member
    Join Date
    Sep 2001
    Posts
    9

    navigating between scenes

    For some reason I can't get the buttons to navigat between scenes...I keep getting errors. Perhaps someone can take a look & see what the problem is?

    You can see the .fla here: www.wildfiremarketinggroup.com/dev/db/index.fla

  2. #2
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    I looked at your file and there is no script that I could find anywhere to go to a different scene.
    Each of your buttons has:
    Code:
    onClipEvent (enterFrame) {
    	// if the mouse IS over the clip ...
    	if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
    		// if the last frame of the tween hasn't been reached...
    		if (this._currentframe<this._totalframes) {
    			// keep playing the next frame to the last and stop...
    			this.nextFrame();
    		}
    		// if the mouse is NOT over the clip
    	} else {
    		// if we're past the first frame of the tween...
    		if (this._currentframe>1) {
    			// play the previous frame until it reaches frame 1 and stop...
    			this.prevFrame();
    		}
    	}
    }
    Somewhere in there you need to have an:
    _root.gotoAndPlay("SceneName", 1);
    or
    _root.gotoAndStop("SceneName", 1);
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  3. #3
    Junior Member
    Join Date
    Sep 2001
    Posts
    9
    Quote Originally Posted by jasonsplace
    Somewhere in there you need to have an:
    _root.gotoAndPlay("SceneName", 1);
    or
    _root.gotoAndStop("SceneName", 1);
    Yeah, it was there before but the syntax was messed up...I think the quotes should fix it. I'm going to try that now.

  4. #4

  5. #5
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    if you have the quotes it should work. Did you put the _root on there? It is required to access the main timeline.
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  6. #6
    Junior Member
    Join Date
    Sep 2001
    Posts
    9
    on (release) {
    _root.gotoAndPlay("this.about us", 1);}

  7. #7
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    Use:
    on (release) {
    _root.gotoAndPlay("About", 1);
    }
    You are targeting the main timeline so you don't need this and the scenes name is "About" not "about us"
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  8. #8
    Junior Member
    Join Date
    Sep 2001
    Posts
    9
    For some reason it still does not work

  9. #9
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    Does it give you an error or does it just not appear to work because both scenes are identical. Can you post a new FLA?
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  10. #10
    Junior Member
    Join Date
    Sep 2001
    Posts
    9
    No error...it just doesn't go anywhere. I dropped a big box into the "About" scene so they are different. The newest .fla is on the server.

  11. #11
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    I looked at your file and I can't find any button objects or any _root.gotoAndPlay
    Where is it at?
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  12. #12
    Junior Member
    Join Date
    Sep 2001
    Posts
    9
    The actual button is burried a bit...it is inside tween 3

  13. #13
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    Well, i'm at a loss. I can't seem to figure out the problem but I think it may have something to do with the hitTest interfrerring with the button
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  14. #14
    FK's Official Mac Hater jasonsplace's Avatar
    Join Date
    Mar 2002
    Location
    Provo, Utah
    Posts
    2,245
    If I were you I would get rid of scenes all together as they are buggy pieces of crap and just do movieClips.
    Jason L. Wright
    I'm not that hard to imitate. Just make some random negative claim at Apple or anything else for that matter and then have nothing to back it up.

  15. #15
    Junior Member
    Join Date
    Sep 2001
    Posts
    9
    Got the problem solved...someone from Ozzu told me what was wrong. It works now. Thanks for your help though.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center