ActionScript 3.0 :: External SWF - Jumping To Frame Of Main Timeline
Aug 10, 2011
I have an external swf (is is an intro, nade in aftereffects)..and it loads in the main timeline of the site with a preloader. Everything is ok, but, when the intro in done plating. It stops and I want do see de site. I mean from the last frame of the external swf, I want to jump to the second frame of the main timeline.
Here is the script:
stop();
var req:URLRequest = new URLRequest("intro.swf");
var loader:Loader = new Loader();
function fileLoaded(event:Event):void{
addChild(loader);
[Code] .....
View 2 Replies
Similar Posts:
Apr 6, 2010
The situation is as follows:I'm using Action Script 2.0 --- I'm obligated to in the course I'm attending.I have a main timeline that has 3 frames. On the 2nd frame I have a movieclip named mc_nbr. On the 3rd frame I have a button "voltar" that when pressed I want it to "Go and Stop/Play" at frame 3 of the movieclip (that is embedded on frame 2 of the main timeline).
I used the folowing code for the button btn_voltar:
on (press)
{
[code]......
View 2 Replies
Apr 29, 2011
I am trying to make a button jump to a label in the main timeline from within a movieclip but I dont think i have the syntax etc correct. I'm getting "access of undefined property _root" when I run the following code. Any ideas what I'm doing wrong here? heres the code..
menuButton_IN.pHome_IN.addEventListener(MouseEvent .MOUSE_DOWN, onPressHandler);
function onPressHandler(myEvent:MouseEvent){
_root.gotoAndPlay ("home");
[code]......
View 2 Replies
Jul 26, 2010
On the last frame of my swf, I placed a loadClip("filename.swf", fileholder); using a MovieClipLoader object. Now it is successfully loading the external swf, I can see it, but it immediately jumps back to the first frame of the parent swf. Why is this happening?I have placed the fileholder movieclip in the same frame. Also, the moviecliploader code is not inside any container, it is just placed into the actions section as is, starting with moviecliploader declaration.
View 5 Replies
Mar 24, 2011
I tried to get this right but it just won't work for me. It's probably something very simple. I have a video in a movieclip on my timeline. On the first frame, I have the stop(); command. I want to be able to hit the SPACEBAR: which results in pausing the movieclip and jumping to frame 2 on the timeline.
View 8 Replies
Mar 24, 2011
I tried to get this right but it just won't work for me. It's probably something very simple. I have a video in a movieclip on my timeline. On the first frame, I have the stop(); command. I want to be able to hit the SPACEBAR: which results in pausing the movieclip and jumping to frame 2 on the timeline.
View 4 Replies
Aug 3, 2009
I have a button that when pressed goes to the next frame of a external swf file loaded into a movie clip. When the last frame of the external swf is reached, I want the button to go to the next frame of the main timeline (which in turn loads another external swf and the process repeats itself over again).
I assume I have to use an if/then statement, but what exactly is the if clause?
View 1 Replies
Jan 3, 2010
Not sure if I'm in the right place, I apologize in advance if so. I'm somewhat proficient with html, but fairly new to flash, using cs4pro, as3. Here's my dilemma. Converting an existing html/css site to flash. Flash is main site now but a few html pages are still linked, a buy page and a form page, a few others. I can get the all the external html pages to link to a frame in the flash movie, and I can get the flash to link with all external urls.
My problem comes when I move to a frame outside the main timeline. The movie is lets say 393 frames. All symbols/content are on seperate layers, and so is the action. Once the full movie ends, I have several frames past that where I have basically created frames for additional "pages" and created anchors for those frames, new layes for content, new layers for anchor (labeled) and new layers for a stop(); on each frame, I extended the pertinant graphic frames out to 410 from the original movie.
Now when the movies runs the buttons appear at about frame 115, so in the action layer I coded a keyframe and then added frames of it out to frame 410 or so: I have attached the .fla Now I'm lost here. When you navigate the site, from home lets say to an external link (button) like members, the html member page opens, and if you click home button, back to flash frame, and all works, all buttons, on the home frame 393. But if you go to any of the external htmls, and then go back to any other frame like frame 401 the about page, and all the rest 402 403, etc, the page appears properly, but then none of the links function. the site URL is [URL]there is a flash intro too, swf in question is actually at[URL]
View 2 Replies
Feb 8, 2010
I've beein digging forums everywhere but cant find the solution to my problem...
I have an external swf "advert_3.swf" loading into the main index.swf.
advert_3.swf has two buttons: one needs to go to "services" frame the other to "events" within a content_mc which is in the index.swf.
that is in the index.swf:
ActionScript Code:
var request:URLRequest = new URLRequest("advert_3.swf");
var loader:Loader = new Loader();
loader.x = 35;
[Code].....
View 1 Replies
Mar 24, 2011
I have a video in a movieclip on my timeline. On the first frame, I have the stop(); command. I want to be able to hit the SPACEBAR: which results in pausing the movieclip and jumping to frame 2 on the timeline.
View 1 Replies
Nov 22, 2011
How do I link a button thats embedded in frame 2 (music page timeline) to a frame in the main timeline ( frame 3= biography page)? Both pages are on the same scene with link buttons embedded in each page independent timeline.
View 1 Replies
Oct 16, 2009
I have 3 functions in my main document class that I want to execute when the main timeline reaches a particular frame number. how do I do that?
see the code and comments
public function mainClass()
{
//stage declaraction
stage.align = StageAlign.TOP_LEFT;
[Code]....
View 5 Replies
Mar 16, 2007
I simply want to assign a variable to the current frame of the main timeline (not movieclip timeline) I already know about _currentframe and it doesn't help in this case.
View 4 Replies
Apr 26, 2011
I am in the learning process. Working with FlashCS5 and AS3. if the issue appears to be too simple for you. Placed a movieclip(mcassessJohn) on the main timeline and moved to the frame labelled "johnFeedback" in the movieclip timeline using the following actionscript code.
[Code]...
View 1 Replies
Aug 9, 2010
I am trying to "gotoAndStop" on a frame in a nested timeline from the main timeline, but can't seem to figure out the correct way to write it with it's 'parents' etc... this is how I have tried which makes sense to me (have tried other ways too) but no success.
gotoAndStop(parent."framename");
View 3 Replies
Apr 22, 2009
So I have a frame labeled 'init' and a button called _exit. I want _exit on click to keep going back until it reaches 'init'
I'm guessing something like this but it doesn't work:
[AS]_exit.addEventListener(MouseEvent.CLICK , function(e:Event):void
{
if(currentFrame!='init'){
gotoAndPlay(currentFrame-1)
}
});
[/AS]
View 1 Replies
Aug 27, 2009
How do you go to a frame in the main timeline?I tried stage.gotoAndStop(2); but that did not work.
View 4 Replies
Feb 13, 2010
Whenever I hit the enter key, the main timeline goes to the next frame. I don't want this to happen -
View 1 Replies
Jan 5, 2010
How do you retrieve the frame rate for the main timeline that was set when the SWF was created.
var fr = MovieClip(root).frameRate
...does not work for me.
View 1 Replies
Jan 19, 2011
I'm trying to go to the next frame in the main timeline from a class with no luck.
I have a movieclip called winner_mc that is created in the document class.
winner_mc is linked to the Winner class.
The Winner class creates a movieclip called nextlevel_mc which is linked to the Nextlevel class.
Then when I click on the nextlevel_mc movieclip I want to go to the next frame on the main timeline.
I tried this for the Nextlevel class:
package {
import flash.display.MovieClip;
import flash.events.MouseEvent;
public class Nextlevel extends MovieClip {
[Code]....
View 21 Replies
Apr 1, 2011
I just added a motion tween on the main timeline only to realize it doesn't run. Only frame 1 is executed, including its AS3 code. No I could not locate any stop() command within the AS3 code.
View 5 Replies
Apr 2, 2011
I made an RPG, and I'm trying to make the movie itself go to the second/next frame. But whenever I try to do that, nothing happens at all. I tried _level0.gotoAndStop(2) and _root.gotoAndStop(2), both on a frame and on a movie clip.
It's suppose to initiate this function once a certain variable (_root.numbers) reaches 20, and I've tested if the variable does reach 20 by doing other things.
View 0 Replies
Apr 28, 2011
What would be the best way to move onto the next frame (frame 2), when an animation has finished playing on the first frame in the main timeline, with no user input? The animation is on the first frame in the form of a nested movie clip.
View 2 Replies
Jul 14, 2004
I have an internal swf file play within a main swf file. At the end of the internal swf file timeline I want the timeline of the main swf to go to a certain frame and stop.
View 3 Replies
Feb 3, 2005
Just wondering if theres a quick way to check if there's another frame on the main timeline after the one you are currently on.. or just a command to tell me how many frames total in movie(and if therres a command for # of current frame, or ill just have to make a counter), rest i can do myself
View 2 Replies
May 8, 2008
I am working on a site that involves a dropdown gallery menu. I have placed four buttons inside the dropdown menu and it works only with the geturl function, but i want it to gotoAndPlay a particular frame outside of the movie clip. is that possible? Here is the link. TJ2 Studios
Im sorry if i am not clear. My actionscript is coming along very slowly. I created a dropdown menu inside a button. This button is supposed to gotoAndPlay frame 365 outside of the mc i created within that button, ie on the main timeline. But it does not work. However when put the script getURL it goes to the site i commanded.
View 4 Replies
Jul 14, 2004
Flash MX- I have an internal swf file play within a main swf file. At the end of the internal swf file timeline I want the timeline of the main swf to go to a certain frame and stop.
View 3 Replies
Oct 11, 2010
I have 5 different buttons for the navigation on my flash website.The first page is on frame one.When you click on any of the 5 buttons I want it to play frames 10 - 15 before moving to which ever frame the button 1-5 corresponds to. So:
Click on button 1 > plays frames 10 - 15 > Goes to frame 20
Click on button 2 > plays frames 10 - 15 > Goes to frame 30
Click on button 3 > plays frames 10 - 15 > Goes to frame 40 etc
How do I make this work?
View 3 Replies
Mar 5, 2010
chimera-studio.com/misery.fla Any ideas as to why this won't work?? It's such a simple concept...
I have this code on the middle frame of a movieclip in my main timeline. When the nav buttons are pressed they play an animation and report their names to a variable called "navigation" that's declared in the first frame of the main timeline.
[Code]...
View 1 Replies
Jan 17, 2011
I need to use, GoToAndStop(), from a Symbol, that is not on the Timeline, to change the current frame on the Timeline.
View 1 Replies