ActionScript 2.0 :: Getting Root To Play In External SWF's?
Sep 6, 2004
I am making a website and there is an empty SWF that is the base for my site. It loads up an external page called the Home page, in that home page are movie clips that are told to .play() with a _root command. What i wanted to know, was how do i get those buttons to play those movie clips inside of itself.
MAIN EMPTY SWF __
|
HOME PAGE SWF (which is loaded into an empty movie clip in MAIN)
|
|__ Fading movie clip (which is inside of HOME PAGE, given a _root.fadewhite.play() by a button inside of HOME PAGE SWF
In short, how do i refer to the movie clip to play that is inside of HOME PAGE SWF which was loaded into an empty movie clip inside of MAIN EMPTY SWF?
View 1 Replies
Similar Posts:
Sep 13, 2009
I have a movie mc that contains buttons called menuMovie.I also have another movie clip called "myMovie". There is an instance of menuMovie on the main timeline in keyframe1 called "_menuMovie_mc".There is also an instance of myMovie on keyframe1 called "_myMovie_mc" .I want to have one of the buttons in menuMovie play myMovie.mc which has a label called _here". My understanding is:
root._myMovie_mc.gotoAndStop("_here");
View 2 Replies
Feb 16, 2009
I made a button within a movieclip.The movieclip name = OurKlips-mainThe scene name = oneWhen I hit this button, it changes two frames in the html part (This works)Also, I want this button to play frame 30 from the root scene, titled "one"on (release) {getURL("content-ourklips.html", "content-txt");_root.gotoAndPlay(30);}
View 2 Replies
May 17, 2003
I can usually find what I need by searching. Not this time.I'm scaling an mc with a script.This is on the timeline of the parent:
stop();
MovieClip.prototype.easeScale = function (finalWidth, finalHeight, speed) {
this.onEnterFrame =function () { [code]...
I want to trigger another mc to play on the root once mask_mc reaches its finalHeight.I've tried if statements, but nothing really works.
View 14 Replies
Jul 14, 2009
I am creating a flash site, and inside my frame label for lets say "pageA" the movie clip begins In pageA, fades up shows the content and stops(); alowing for the page content to be read.
After reading, the viewer clicks on the button inside the nav bar, to take them to say "pageB" i now want "Page A" to fade out and then root to "pageB
my thinking is that i insert a stop on the time line of the movieclip, then when the button is pressed it plays, lets say, the remaining 10 frames in the clip (the fade out), and then roots to pageB.
i just need a simple actionscript to do that, if there is an easier way, any one who could point that out and end my misery is a god/godess respectfully!
View 2 Replies
Jan 5, 2012
I have a movie embedded and I am passing a variable to the root movie for it to play when the embedded movie is complete. I know the variable is getting passed because I am displaying the value in as dynamic text but the parent movie will not play. This is what I have:
stop();
row = 0;
if (row == 1) {
this.gotoAndPlay(2);
}
Row is being passed from the embedded movie as
_root.row = 1;
I know there is a way to tell the parent movie to play from the embedded movie by using TellTarget but I would like to find out why this doesn't work.
View 1 Replies
Nov 9, 2007
Im trying to tell my movie to goto and stop on anoter frame on my root timeline and then play a movie clip on the new frame... This is probs really simple but it is early.
[Code]...
View 11 Replies
Aug 15, 2010
I have added some three sound clips, play pause buttons, on the root timeline in a movie with corresponding callouts. I am able to stop all sounds on the main timeline by below
stop_btn.addEventListener(MouseEvent.CLICK, stopSound);
function stopSound(event:MouseEvent) {
SoundMixer.stopAll();
}
But now how do I resume all the sound to play. In sort, mute unmute root sounds in AS3.
View 1 Replies
Mar 3, 2007
If you load an external swf into a movie and this external file references "_root", does "_root" reference the root of the external swf or the swf that contains the external file?
View 3 Replies
Sep 16, 2010
I have my main fla and then I have a actionscript named bullet.as in the bullet.as I create a bullet using "this" throughout the script now how would I call the bullet on my main timeline?
View 1 Replies
Jan 14, 2010
I have been provided with some flash movies/apps to include in a web design that I am doing. These flash movies load an external xml file.This is failing.The problem appears to be that when the flash movie goes to load the file using a relative directory path, it starts at the very root of the web directory, where the main jsp file is, instead of the where the .swf file is located.[url]...
View 1 Replies
Mar 25, 2009
I've been going through online tutorials and so forthand yea I'm still a newb. I have a flash site I'm designing and this is probably a simple answer. I've figured out how to incorporate the external flashes using buttons and loader, please see the script below. The main problem I am having is I want to load my 1.swf file as the main home page. When I load the flash is comes up empty instead of loading the swf file when the flash is first opened. I can use the button to load it back, but how do you get it to appear once the flash is initailly loaded instead of just pulling up a blank page?
Code:
on (release) {
//load Movie Behavior
if(this.home == Number(this.home)){
[code].....
View 7 Replies
Dec 21, 2010
I made this class and I put it in the same package of Timeline.as (the Document Class):
package {
import flash.utils.Timer;
import flash.events.TimerEvent;
public class Counter2 extends Timer {
public function Counter2(delay:Number, repeatCount:int=0) {
[Code]...
View 1 Replies
Dec 10, 2007
My flash project is structured as follows, with the nested external swfs being loaded to clip holders using loadMovie():
home.swf
|--sponsors.swf
|--educators.swf
In home.swf, I've defined a text box with instance name contentWindow_txt, and assigned its path to _root.cw_txt. Now, when I type the following anywhere in home.swf:
Code:
_root.cw_txt.htmlText = "testing!";
The dynamic text box contentWindow_txt will display "testing!" when the swf loads. Unfortunately, when I make the same call in sponsors.swf, I get nothing. Is there something about external swfs or variable inheritance I don't know?
View 9 Replies
Jul 23, 2009
I am able to access main root from an external swf by doing this:
MovieClip(root.parent.root)
but how to avoid getting an error when testing external swf alone? Is there any try catch system I can do to avoid thoses errors?
View 1 Replies
Mar 20, 2006
I'm working on a site for a friend's art gallery.I have a dynamic html file I'm using to list an archive of shows so that it can be easily updated by the curator.Is it possible to code a link in the externally loaded xml file that will tell my flash movie to load an external swf into an empty mc on the root? is there a way to:
create a variable in AS that when added to the xml file, triggers something like loadMovie("g_0306.swf", "_root.empty"); ?
View 11 Replies
Sep 16, 2010
I have my main fla and then I have a actionscript named bullet.as.in the bullet.as I create a bullet using "this" throughout the script now how would I call the bullet on my main timeline?
View 3 Replies
May 10, 2011
when a button is clicked, I want an external swf to load and play, then I want to go back to a particular frame in the original timeline.
View 2 Replies
Dec 4, 2010
I am trying to create a global function to reuse repetitively. It worked until I moved the function to the external .as file. The problem is with MovieClip(root) and MovieClip(parent). They do not work and cause errors.
[Code]...
View 0 Replies
May 15, 2009
I am loading the SWF just fine, but I want the SWF to fit the root stage exactly. What happens instead is that the external SWF seems to include white space from around itself.
For example, the author-set width of the Tanks game (an example file I was using) is 550px, but when I set the width of loadEvent.currentTarget.content.width to 550px, the game is resized to maybe 350px width. I have to set the value of loadEvent.currentTarget.content.width to something like 640 in order to get the game itself to make full use of those 550 pixels.
Code:
package {
import flash.net.URLRequest;
import flash.display.Loader;
import flash.events.Event;
[Code].....
I have CS4 with AS3. I hard-coded values for cWidth and cHeight instead of getting them from flashvars because I am just testing in the IDE right now. Normally I would get those vars from flashvars.
View 1 Replies
May 18, 2011
I have a ScrollBar with some buttons in it. I need to know how I can load an external swf in a MovieClip which is on the root of main application?
View 3 Replies
Jan 5, 2012
i have 2 flash file,one is mine (the main container) and one is a external swf.i want to load the external swf to my container swf.i write this code in my as2 container code inside the main timeline flash (mine flash) -----first of all i add a movie clip with instance name mc1 to the first layer
Code:
mc1._lockroot = true;
mc1.loadMovie("external.swf");
countdown = function(){
[code]....
i really try to use that code - BUT !!! -> if i use this code the external swf predominant my main swf code and all the rest of my code dosent work (like timer of trace)....
View 7 Replies
Jul 15, 2010
I have small issue in as3. I am load "mainmenu.swf" file into "main.swf". through loader class. so now "main.swf" is parent "mainmenu.swf" file children how can call "main.swf " variable & function from "mainmenu.swf" .
View 2 Replies
Jan 5, 2012
I have 2 flash files,one is mine (the main container) and one is a external swf.I want to load the external SWF to my container SWF.I write this code in my AS2 container, inside the main timeline flash (mine flash).In the first method, I add a movie clip with instance name mc1 to the first layer:
mc1._lockroot = true;
mc1.loadMovie("external.swf");
countdown = function(){
trace("ok");
}
countdownIt = setInterval(countdown,1000);
This code works fine in most of the cases, but I found many SWFs files that it dosen't work with. These SWFs and work with the following code instead:
loadMovieNum("external.swf",0);
countdown = function(){
trace("ok");
}
countdownIt = setInterval(countdown,1000);
I really try to use that code - BUT !!! -> if I use this code the external SWF predominant, my main SWF code and all the rest of my code dosen't work (like the setInterval() timer).... I want to load the SWF like the second example and still run the setInterval() function.
View 1 Replies
Jan 14, 2009
Situation:
- We have a Flash application located on a SAP EP (let's say ep.x.com)
- We have a SAP ABAP Application (Webservices) on a SAP WebAS
server (abap.x.com)
- Clarification: This is not about Flash islands / but a normal Flash application communicating with WebAS ABAP via WebServices
Problem: Due to the changed security policy in Flash 10 this scenario does no longer work.
- A crossdomain policy file on root level cannot be deployed on root level
- The WebServices http/s headers cannot be modified, since the WebServices are generated by the WebAS IDE.
Comment: Technically there is a way to patch a WebAS ABAP,but this is not a practical / acceptable way in a normal SAP WebAS infrastructure.
Conclusion:- The above scenario (Flash from EP content / WebAS ABAP as backend) is a quite normal scenario in the SAP world.
- SAP / Adobe always features the close relationship between their technologies.
Question:- What could we do?
- How does the Visual Composer works around that problem?
View 1 Replies
Mar 22, 2010
I have a root stage, and a MC that is called from the root stage.Now from that MC, i will called in another MC2, and I wanted to placed the MC in the center of the stage. The reason I could not use normal ADDED_TO_STAGE at MC and define the center is because MC is not place in the exact position of the root stage (as in x, y=0). So if I would target MC2 at MC stage center, it would not be the exact center of the root stage/screen.How can I called the root stage properties rather than adding MC2 into the stage?
View 1 Replies
Nov 7, 2011
How do you tell the root timeline to root.gotoAndStop(2); from the timeline of a movieClip added using addChild?In the maintime line I have
addChild(fade_eng);
and in fade_eng I have the following on frame 20
root.gotoAndStop(2);
this.gotoAndStop(1);
But I am getting 1061: Call to a possibly undefined method gotoAndStop through a reference with static type flash.display:Stage.
View 1 Replies
May 28, 2010
I am making a title sequence to a flash site. I load the sequence with addchild. After the title is finished I want to unload the title and play a function.
How can I unload the title movie once its finished? I know I should use removeChild, but I only want to unload the movie after a certain time.
View 1 Replies
Jul 16, 2009
I know this is a very basic question and one that I know the anwser to, but it's been a while since I've used Flash and the solution is escaping me right now. I'm loading external swfs into my main swf and they should just be playing automatically. When I test in Flash, the system works. Upon loading the swf into an HTML page, the system seems to shut down. It seems liike the exteranl swfs aren't even loading. This is what I've got so far.
[CODE]...
View 5 Replies
Dec 14, 2009
I have five videos that play on command when you click one of five buttons. I want to make two enhancements to this script and I need an expert's help (because clearly I'm clueless!).
#1 - Even though I have the vidPlayer (aka flvPlayback component) setting set to "true" for autoplay, the area where the videos are set to play remains blank until clicking on one of the buttons. How can I get the first video to truly "autoplay"?
#2 - I would like to have the videos play in sequential order when the last video is finished, then stop after the last (fifth) video has played. How can I get them to play back-to-back?[code]...
View 5 Replies