Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash








On Release - Finish Scene - Goto Scene?


I have a navigation scene with buttons that is 100 frames but stops to allow navigation at 50.

What is the correct script to add to the buttons that allows me to finish the current scene to frame 100, then go to required scene??

Help is greatly appreciated.
Thanks,
Nick




FlashKit > Flash Help > Flash Newbies
Posted on: 09-08-2002, 03:42 AM


View Complete Forum Thread with Replies

Sponsored Links:

On(release) Goto Scene(number)
hello, i have createb buttons that have to go to different scenes when pressed.

what is the actionscript to put on the button to go to example scene3 ?

View Replies !    View Related
RollOver (mc) Release Goto Scene
first, I'm a bit of a newb to AS.

I've seen a lot of similar threads but not this exactly.

I'm trying to place all my AS on the first frame (not in buts etc.)

I have a button and on rollOver I want to play a mc and on release goto scene 'profile'.
goto works fine but when calling the mc I'm not sure what action is most appropriate; 'loadmovie', 'visable=true', 'attachmovie' or something else.

here is what I have...


// Stops the playhead at Frame 1.
stop();

// This script takes the user to Scene profile when profile_btn
//is released.
profile_btn.onRelease = function () {
gotoAndPlay("profile", 1);
} ;

// This function plays profile_mc when profile_btn instance
// is rolledover

profile_btn.onRollOver = function() {
this._parent.attachMovie("profile", "profile_mc", 1);
profile_mc._x = 10;
profile_mc._y = 112
} ;

any help would be appreciated and I thank you in advance

View Replies !    View Related
Button Problem - Cant Goto A Scene On Release
Hi,
Beginer here, i am tryin to make my button in scene 1 goto frame 1 of scene 2. i have used the following script for the button:

on (release) {
gotoAndStop("Scene 2",1);
}

..but it doesnt work. confusing. can someone take a look and see where im going wrong? im sure its simple )

please see file attached.

thanks in advance.

View Replies !    View Related
Button Action - Finish Scene And Go To Other Scene
hello and thanks for any help,

i have a main scene that runs to frame 125 and stops.

i have a few buttons, each one i want to (upon click) continue the movie (up to, say, frame 130, which has my 'transitional fade') and then go to the corresponding scene (each button corresponds to it's own scene).

this is what i've been trying, and it's continuing past the 'stop' but not going to the scene:

button:
on (release) {
_root.choice = 1;
_root.play();
}

frame 125
stop();
if (_root.choice == 1){
_root.gotoAndPlay("Scene 2",1)
}

if (_root.choice == 2){
_root.gotoAndPlay("Scene 3",1)
}


thanks a lot !

View Replies !    View Related
Button Action: Finish Scene And Go To Specified Scene
hello and thanks for any help,

i have a main scene that runs to frame 125 and stops.

i have a few buttons, each one i want to (upon click) continue the movie (up to, say, frame 130, which has my 'transitional fade') and then go to the corresponding scene (each button corresponds to it's own scene).

this is what i've been trying, and it's continuing past the 'stop' but not going to the scene:

button:
on (release) {
_root.choice = 1;
_root.play();
}

frame 125
stop();
if (_root.choice == 1){
_root.gotoAndPlay("Scene 2",1)
}

if (_root.choice == 2){
_root.gotoAndPlay("Scene 3",1)
}


thanks a lot !

View Replies !    View Related
I Need To Pause My Scene On For A While Then Goto Next Scene,
i need to pause my scene on for a while then goto next scene, i need the right syntax and all, with examples pleeease?

View Replies !    View Related
MC Finish Before Scene Change
I'll admit that although I've been using Flash for quite some time, I've never really gotten into AS. I feel like I have to apologise because I think this seems like a really simple thing, but I just can't work it out.

All I want to do is (in Flash 5) tell a scene to wait for a movie clip to finish playing before it advances to the next scene.

I've done tutorials, read messages and tried everything. I promise I'll try to get my head around AS better if someone will just please point me in the right direction.

Cheers.

View Replies !    View Related
Finish The Scene, THEN Gotoandplay
i have a scene that i want to go to the end of before it goes to the next user-chosen scene. so, i have a scene, Home, with this actionscript on the Music button:

on(release){
Play;
}

but when it gets to the last frame, it needs to go to the scene called Music. is there some kind of if(frame==#) statement, or something along those lines, that i could use? i'm just not sure if that will work.

thanks guys, i really appreciate it.

-- Cm

View Replies !    View Related
GotoAndPlay Scene After Tween Class Finish?
Can any one help me... I have spent many hours trying to nut this one out..

I have an animated button which I am animating using a tween class. It works fine, my problem is this, I need to jump to another Scene after the animation has finished.

HOW please!!!!!

View Replies !    View Related
Goto Movie(goto Scene)
hi, i made a scene (at the end of it (frame 560) i made a menu of buttons), when i click one of the buttons, a movieclip should appear (on(release){gotoandplay(561)}). At the end of the movie clip i put a script(gotoAndPlay ("scene#2", 1) that it should go to second scene. but it doesn't work. the movie plays but it repeats itself. do i have to add something else in the script!? please help, thanx!

View Replies !    View Related
Goto Scene
When the end of a movie clip is reached, I want a particular scene to play. So on the last frame of the movie clip, I have:

gotoAndPlay ("Scene 2", 1);

But this doesn't play that "Scene 2" for me. It just plays the same movie clip again. This also happens when I place a button in the movie clip with:

on (release) {
gotoAndPlay ("Scene 2", 1);
}


How do I get this "Scene 2" to play when that movie clip reaches the end, or when the button is pressed? I hope someone can I'm just a newbie at this... thanks for your help.

View Replies !    View Related
Goto From A MC To A Scene
Hi,
I hope you can help me with something:

I want to go from a MC to a Scene and I know how to do it if the Scene I want to go is the First One:

on (release) {
_root.gotoAndStop(1);
}

But the problem is that I want to go to Scene 2 and not to the first one.

I found something like this in this page:
http://iat.ubalt.edu/courses/old/pbd...oProblem.shtml

But since I don't know much about ActionScript I don't how to code all the "set a value in a global variable, then perform some statement such as _parent.gotoAndPlay" stuf

Can someone make the code from what's being said on the url above

Thanks for the help!

View Replies !    View Related
Goto Scene
hello im just wondering if any one could help me i am designing a game an want to make it jump to anothter scene after 20 seconds

i have a timer all set up but cannot get it to work.

the variable name of the timer is seconds and the scene is called high.

i have tried to

if(seconds = 0)
gotoAndStop("high","1")

it doesnt work

Thank you

View Replies !    View Related
Goto Scene At End Of FLV
I have an flv video playing from a FLV Playback component. I am trying to have the movie goto the next scene at the end of the FLV video. I have go through numerous tutorials online to get the action to do this, but to no avail. I have tried both addeventlisteners and NS. Can someone please tell me the easy way to have the movie advance to the next scene after the flv and where the AS has to be to get the movie to function properly.

Thanks, I appreciate your help.

View Replies !    View Related
Goto Different Scene.
could somebody please give me the actionscript for making a button goto a different scene. thanks in advance.

View Replies !    View Related
Goto Different Scene.
could somebody please give me the actionscript for making a button goto a different scene. thanks in advance.

View Replies !    View Related
Goto SCENE
Hello folks.

I have a file im working on and it consists of two scenes. The first is the intro animation, the second is the main page (buttons and wotnot).

The screens for each button are contained it certain frames in scene 2, frame 1 is the main menu, frame 5 is another menu etc... and each button works by giving a gotoAndStop command.

The problem I am having is that the initial buttons I have work. They are a button object on the main stage (scene2). I am attempting to have animated buttons like in the 'flash source files - icons' example.

This requires that the button be turned into a movieclip, which leaves the button commands on the button inside that MC.

This seems to have totally stopped the gotoAndStop command from working.

I have tried changing it to _root.gotoAndStop but it jumps right back to scene1. How can I get it to do a _root.gotoAndStop for scene2.

There we go, probly very easy.

Thanks guys.

Gaz.

View Replies !    View Related
On Release Of Button...got To Another Scene
Hey guys I'm a newbie so be easy with me! I have a button in my first scene. Upon release of that button I want to go to my next scene. What script do I write out for this, I've been trying this forever and still can't get it to work! Thanks

View Replies !    View Related
On Release Next Scene ~ Troubles
i have a button in an MC, which is set on the main stage. I'm tring to get the button to play the next scene, but nothing works, i have two other button next to this one and each does a different thing (open new window, close the MC) and they both work fine, but playing the next scene doesn't, i thought maybe it was a _root. issue so i tried on(release) _root.nextscene(), still no luck, why am i haveing this problem and how can i over come it?

View Replies !    View Related
Flash Won't Goto The Next Scene
i have scene 1, frame 1 with an actionscript that does a text effect, and then at the end i have it go to scene 1 frame 2. then i have scene 1 frame 2, gotoAndPlay ("Scene 2", 1);, but flash will not goto scene 2 and play frame 1. i have tried a lot of stuff, i can't figure it out. any help would be nice. thanks.

View Replies !    View Related
On Play Goto Scene?
hi. i tried searching for a thread with this but was unsuccessful . . could i get some help on this? i don't think it's a very hard one but i'm kinda new in actionscript. .

i've got a .swf with 3 scenes on an html page.
the first time the page loads the first scene plays and then stops.
if you mouse over that it will play scene 2 and stop. mouse over scene 2 it plays scene 3 and stops.
mouse over scene 3 and it plays scene 2. and continues the cycle between scene 2 and 3.

now on the html page there is a frame. there are links on the same page as the swf. every time a link is pressed it loads a page inside the frame, and at the same time it gives the command to play the .swf.

what i want to happen is for the .swf to see if it's in scene 1, 2, or 3.

if in scene 1 (when the play command is issued)play scene 3.
if in scene 2 (when the play command is issued)play scene 3.
if in scene 3 (when the play command is issued)play scene 2.

is there some way to set this up so that the swf can do this? also, where do i put this action scripting? would i need to put one on each scene? or just on scene 1?

thank you in advance for the help. .. 8*)

looooooooove,

botti

View Replies !    View Related
Goto NEW SCENE Simple Insīt It?
I have these scripts over a button inside a mc called "enter"

on (press) {
_root.gotoAndStop ("bipede", 1);
}

I want my movie to go to the scene "bipede"
I seems to be simple but I can find the deal

Thanks

View Replies !    View Related
Goto Other Scene On Specified Condition
Hi All,

I've create a small "find the 7 differences".
It's 1 scene and 1 frame long. The number of differences found is alse shown.

The code behind the "secret area's" is:
----------------------------------
on (press) {

if (Click1 <> 1) {
Aantal = int(Aantal)+1;
}
}
on (release) {
Click1 = "1";
}
----------------------------------

The frame action is:
----------------------------------
Mouse.hide();
startDrag ("Arrow", true);
----------------------------------


Here's my problem..

When I add a second scene which shows "bravo, bla bla...", I can't get the movie to wait on the first frame of scene1 till the var Aantal = 7 ..

I'm very new to flashscripting (started yesterday) so it's probably a small function I'm overlooking.

The current-application (without scene2) can be seen on:
http://www.altijdfeest.com/various/7verschillen.asp


Thanks in advance!

(sorry for the crosspost on Flash 4 Actionscript

View Replies !    View Related
Goto Scene With Keyisdown
I Need help,

I have an mc with this script:

if (key.isdown(key.space)) {
if (_root.copter.hitTest(_x, _y)) {
_root.gotoAndPlay ("beach", "1");
}
}

but it didn't go to scene "beach"
what's wrong with my script ? Anyone can help me ..?

Thanks in advance


Hairos

View Replies !    View Related
Goto Is NOT Going To Correct Scene
possibly bug .. dont know.. but:

I have two scenes .. one preloader, one movie.

the preloader does its thing .. sucessfully.

then says

if (getBytesTotal == getBytesLoaded){
nextScene();
}

I have also tried different commands like goto play scene, just good ole 'play()'. The problem is, when the movie DOES goto the next scene .. ANY code in the proper movie that has a 'gotoAndPlay(n)' command doesn't refer by deafult (which it should) .. to the current scene .. it refers to the preloader scene. There is a work around if I point to frame labels .. but I shouldn't have to edit my other movie .. because as you could imagine, some movies have Bajillions of gotoAndPlay refernces .. Any ideas.

View Replies !    View Related
BIG Problem With Goto Scene Within MC?
I know, I know...

This may have been cover somewhere on the groups but I have searched to no avail!!!

I have a menu(MC) which displays buttons which when clicked should goto a scene in the main movie. NB: I have no other movies loaded. I just want to go to another scene.

Button inside a MC do not seem to goto anywhere?!

Here is the file http://www.mlic.co.za/new/movie1.fla

Thanks guys

View Replies !    View Related
Anyone Know How To Goto A Scene From Wthin A MC?
http://www.mlic.co.za/ne/movie1.fla

here is the file

View Replies !    View Related
Help:goto Scene Onpress
how would i go about doing a onpress gotoAndStop("scene",1);

do i have a good start on my site..do u like

my site

View Replies !    View Related
Goto Scene,frame,MC
How can I combine these actions:
gotoAndPlay("Scene 2", 1);
_root.mc.gotoAndPlay(2);

So that when I click the button, the movie goes to the mc in another scene with a defined frame.

Greetz

View Replies !    View Related
GoTo A Diferent Scene
iīm running Flash MX on the Windows 2000 server, and like to know if is any conflit. I have one more question, i had a buntton inside of a movieclip and i want to give him an action to go to a diferent scene. How can i do that?

View Replies !    View Related
Button Won't Goto A New Scene..
I've suddenly accumulated this problem in my action scripting where I'm trying to assign a button an onmouse event script that will send the movie to the next scene, and the scripting that I've been using before suddenly won't work for this document. When I click on the button that should be going to the next scene, it just replays the current scene. I have no idea what the problem is, could someone help me out?

Here's what I currently have, let me know if it's wrong:

on (press) {
gotoAndPlay ("<scene 2>", 1);
}

View Replies !    View Related
Goto Scene Not Working
I have a movieclip with another mc in it with code on it so when you press enter it goes to a scene. Theres about 131 scenes and I have the mc duplicate and at differant times in the timeline so that at one frame if you press enter it will goto one scene, and at another frame if you press it it will goto some completly differant scene. But my problem is that enter is acting like a play command. Just going to the next scene. So i made it on release, instead of enter. And now it doesnt go anywhere. Please i need help fast, this huge project is due tomorow and it's a final

View Replies !    View Related
Actionscript To Goto Next Scene?
Im making a little navigation screen with an intro in the same scene.. the intro would play and in the end it would have an "enter" button.. when pressed, I want it to goto the next scene, which would reveal the navigation bar.. is there a way to do this with action script?

View Replies !    View Related
Problem With Goto Scene
i created button and put it into a movieclip. if i klick on it, the movie should jump to the other szene, but it doesnt. so i tried the button outside this movie on the normal stage. here it works, but i need it in this movie.
the code i've used:

on (release) {
gotoAndPlay("aboutme", "1");
}

please help me
__________________-
www.gluszko.de

View Replies !    View Related
Goto And Play Scene
This is a really dumb question, and Im sorry for that, but when ever I try to make a button designated to take the user straigt to a scene, I use ''on (release) {gotoAndPlay(1,1);}'', and Its says that it must be a quoted string. What does this mean? and what is the proper syntax?

View Replies !    View Related
Goto Scene Problem~
hi, im making a basic flash webpage. i set all the different pages to different scenes. (so 1 scene = 1 webpage).

for the buttons, im using the "SubMenu", so the button splits into like... 5 other buttons which link to different pages. the problem is, i try to set the buttons to "goto scene and play on release", but it wont work. it stays in the same scene, and the submenu closes.

im not sure if you understand what im talking about but if you kno how to link scenes using submenus, please help.

thanks for your time

View Replies !    View Related
Tell Target Then Goto Scene?
Ok, here's my problem:

I have a button with this action

on (release) {
tellTarget ("targetclip") {
gotoAndPlay(5);
_root.gotoAndPlay("label");
}
}


What I want is to play the targetclip first THEN goto the other scene.
This script ignore the telltarget and jump directly to the scene.
How do I make it do it in the right order.

View Replies !    View Related
How To Goto And Stop To A Scene?
I just downloaded the trial verson of Macromedia Flash MX Professional 2004, and I made a button, and I want it to go to Scene 30 when it is clicked on.

But when I choose that from the Behaviors, the only option it lets me choose from is Frame, not scene.

So what do I have to do to make it go to scene 30?

I have searched for it, but I couldn't find the answer. Sorry if it has already been asked and answered.

Thanks

View Replies !    View Related
[F8] Goto Scene After Xx Seconds Help
Hello, I almost have this working, just need a little help. I have a movie with multiple scenes. I have next and back buttons set up. If noting is clicked, it will automatically change scenes after 12 seconds. My problem is that I want it to move to a specific scene, not just the next scene. As of right now, after 12 seconds it moves to the next scene no matter what scene I specify in the gotoAndPlay command. If anyone could tell me how I can tell it to go to a specific scene I would really appreciate it!


PHP Code:




stop();

var intervalId:Number;
var count:Number = 0;
var maxCount:Number = 0;
var duration:Number = 12000;

function executeCallback():Void {
    gotoAndPlay("Scene 2");
if(count >= maxCount) {
    clearInterval(intervalId);
}
count++;    
}

function beginInterval():Void {
    if(intervalId != null) {
        trace("clearInterval");
        clearInterval(intervalId);
    }
    intervalId = setInterval(this, "executeCallback",duration);
}

beginInterval ();
beginInterval ();
beginInterval ();

View Replies !    View Related
[F8] Goto Scene On Video End
Basically, I have a video as an introduction, its 4 minutes long roughly. There is an option to skip to the homepage. What would be the actionscript for, on video end goto and play the homepage. Any help, much appreciated.

View Replies !    View Related
Goto Scene Problem.
Hi

I am having a problem jumping to the right scene when i press and release the button. I set up a simple code to test going to Scene 3 from Scene 1, but instead to goes to Scene 2, even though the code is saying scene 3.

Here is the code i am using.........


moveUp.onPress = function() {
rocket.onEnterFrame = function() {
this._y -= 4;
}
}
moveUp.onRelease = function() {
gotoAndPlay("Scene 3");
delete rocket.onEnterFrame;
}
stop();

View Replies !    View Related
Goto Scene From Nested Mc
on the main stage I have a mc named "main" and a button names "b1". Nested inside "main" is an mc named "img1". When I press "b1" main.img1.gotoAndPlay(66); and lands on frame 88. Once the "main.img1" lands on I need it to goto Scene 2 frame 1.


I tried to place this code on frame 88 but got nothing.

_root.gotoAndStop("Scene 2", 1);

also tried

_parent._parent.gotoAndStop("Scene 2", 1);

what am I doing wrong?

View Replies !    View Related
Goto To Frame 2 Of Scene 1 Within A Mc? Please Help
I searched the forums but didn't find a match...
What I want to do is make my intro mc (which is on frame 1 of scene 1) automatically goto frame 2 of scene 1 once the intro ends. The simple goto statement won't work because my intro is in it's own mc.
I have attached a simple version of what i'm takling about. If someone could "solve" this and re-upload it, I would greatly appreciate it!
Thanks!

View Replies !    View Related
Goto And Play Scene?
For some reason i'm having problems swapping scenes in my flash movie. At first i put the action in a "actions" named layer and a link to a button.

So basicly when scene1 loads the frame 1 action is "stop ();". The viewer clicks on button1 which has a code of ;

on (press) {
gotoAndPlay ("10");
}

At frame 10 a 15 frame animation plays and finishes at frame 25. Actions for frame 25 is (keyframed ofc) ;

gotoAndPlay ("scene2", 1);

which wont work. I tried _root.gotoandplay etc and even scene1.gotoandplay and stil wont work. Then i assigned the action to the button itself and just wanted to see if i could switch to the scene by clicking on the button. No it wont work.

I'm fairly (actualy VERY) new to flash, so i might be missing something essential. What is it?

View Replies !    View Related
Goto To Frame 2 Of Scene 1 Within A Mc? Please Help
I searched the forums but didn't find a match...
What I want to do is make my intro mc (which is on frame 1 of scene 1) automatically goto frame 2 of scene 1 once the intro ends. The simple goto statement won't work because my intro is in it's own mc.
I have attached a simple version of what i'm takling about. If someone could "solve" this and re-upload it, I would greatly appreciate it!
Thanks!

View Replies !    View Related
Dynamic Goto Scene
is it possible to tell flash to go to a scene dynamically? instead of using frame labels can i just use scene names and set a gotoandplay to go to a scene that is dynamic?

View Replies !    View Related
Goto A Special Scene From A Movieclip
Hi Freaks out there!

I have a film with several scenes. Of course I can jump from scene to scene with the goto command.

But this doesn't work if the goto command is one level higher in a movieclip.

I can ... Wait...

While I wrote this Question I found out the solution:

on (release) {
tellTarget ("_flash0") {
gotoAndStop ("seid", "seid");
}
}

With this script I can jump to scene "seid" to the keyframe "seid" out of a mc

I hope sb. can use this too!!

View Replies !    View Related
Tell Target / Goto Scene URGENT
i have a button within a movie within a movie within the main movie.
i want that button to send the main movie to the next scene names scene2.

ive been using this code and it's not working

on (release) {
tellTarget ("_local0") {
gotoAndPlay ("scene2", 1);
}
}


why?

View Replies !    View Related
Goto Scene 2 Using A Button Inside A Mc
Hello!!! I have two scenes. In scene1 I have a mc that has a button inside. In this button I put the actionscript

onmouseevent(release)
gotoandplay("scene2",1)

I would like to know why the event doesnīt work. It because the button is a mc? The levels?
How can I go to another scene through a button that is a movieclip?
The LoadMovie works, but GoTo doesnīt.

Thanx!!
Carol
:-)

View Replies !    View Related
Goto Scene From Button Inside MC
I have a movie clip which is a dropdown menu that animates on rollover, the items that show upon the menu collapsing are buttons and I want to assing a goto a different scene action to each one individually, I tried it but when I test it, i click on the button I have assigned the action to but it doesn't take me to that scene.

any suggestions?

thanks in advance

View Replies !    View Related
Scene Name From Variable In Goto- Action?
is it possible to set a goto- action with a scene name from a variable?

like this (doesn't work this way, i tried...):

jump="mySceneName";

gotoAndPlay (jump,1);

i need to do this to distingiush the scene jump depending
on some user input.

View Replies !    View Related
Copyright Đ 2005-08 www.BigResource.com, All rights reserved