ActionScript 2.0 :: Looking For A Command Like _root But Only 1 Level?
May 12, 2010
Right now I am trying to make a gallery in my site and the set up is
Main SWF(1)
loaded into a movie clip on SWF(1) I have SWF(2)
This SWF(2) has the various thumbnails in a movie clip
The ideal is to load SWF(Photos) of the images into another movie clip in SWF(2)
When running SWF(2) stand alone it works fine with a _root command. But when SWF(2) is running on SWF(1) it doesn't work. And initially I had the movie clips with SWF;s 1&2 having the same name so when the button was pressed SWF(1) loaded SWF(Photos) where SWF(2) was.
Is there a command like _root but only going down 1 level?
I have two layers in my FLA both with empty movie clips as follows:In mc_Empty1, I attach a faded background movieclip as I wait for mc_Empty2 to load a SWF. Once the SWF is loaded into mc_Empty2, I want to remove the faded background movieclip from mc_Empty1. When I load the SWF from the main timeline, the onLoad() function works and removes the faded background from mc_Empty1. However, when I load the SWF from mc_target, the SWF loads, but the onLoad() function does not. Here's my AS2 code:
//Loading SWF from main timeline mc_Empty1.attachMovie("mcFadedBg", "mc_FadedBg", 1); mc_Empty2.loadMovie("My.swf");mc_Empty2.onLoad = function():Void{ trace("loaded"); //This works removeMovieClip(mc_Empty1.mc_FadedBg); //This works}
[code]....
I know I'm targeting properly because the SWF loads as it should, but the onLoad() function does not.
I have a swf file ("myfile.swf") which i want to load using preloader.
I referred many tutorials for preloader but problem is I want to load "myfile.swf" at _root level as I have referenced many movieclips in it as for example _root.mc1.mc2
I tried following but may be i am mistaking somewhere...
1) I used preloader in frame 1 and frame 2 and swf content in frame 3 but the file is so huge that the preloading almost starts at around 69% or so
2) I kept preloader in scene 1 and swf content in scene 2. But i cannot see the preloader or i can see at 98% or 99%
3) I used preloader in "pre.swf" and used loadMovie() to load "myfile.swf" at _root. But as i m loading "myfile.swf" at _root so preloader's code is overwritten and so i m not able to see preloader
My "myfile.swf" is very complicated file and so i cannot change all the movieclips which i have referenced as "_root.mc1.mc2".
I was wondering whether it is possible to start Flash CS4 (or any other Flash version) authoring using a command. The project is related to a virtual supermarket. The client needs to delete existing products (jpg) from its web site and replace them with new ones. Basically I have a swf file which has one jpg file in each keyframe. What I want to do is to start Flash, access some keyframes delete some jpg files and load new ones and generate the new swf file. However, I want to do this automatically, ie; using a scheduler. Would Flex solve this problem?
In the code below i want to change the _root.broj and _root.logo variables inside the function which returns values from .php file. Inside the function everything works fine and all values are correct but when i trace var broj outside the function it's still 0.
var result_lv:LoadVars = new LoadVars(); var send_lv:LoadVars = new LoadVars(); var broj:Number=0; var logo = new Array();
if a condition is true, then:_root.(MC with instance name that is the value of "_root.eelmine").nextFrame(); is this correct?_root._root[eelmine].nextFrame();
I just recently began migrating from AS2 to AS3, and I have of course realized that I can no longer move the "_root" by changing the _x and _y positions of the _root (which no longer exists in AS3). How can I do this in AS3 (specifying _x, _y, _z possibly of the "_root")?
Well i have an adobe air which runs vlc-player at background as service. i check that in Windows Task Manager , the service runs when air application launches. here is the code
processArgs.push("--extraintf"); processArgs.push("rc"); //Remote control processArgs.push("--rc-fake-tty"); //Use terminal as output
I want to call 3 commands one by one , the relation between each commands are command should execute one by one in the previous command result. How to Queue Command's? What is the best practice to handle Queue command , my requirement is adding n number of commands and execute them.Main -> Execute c1c1 got the Result - Execute c2c2 got the Result - Execute c3
This is making me a little kooky today. I thought I could defined a library path in PREFERENCES > ACTIONSCRIPT > ACTIONSCRIPT 3.0 SETTINGS then that library would be available to all AS3 FLA files, but that doesn't seem to work for me. If I use the PUBLISH SETTINGS and define the library path everything is fine.
Is there something that I could have done to disable the application level class path functionality? I guess I'm trying avoid having to set the library path for every new FLA I'm making.
I'm doing a bigger aplication in flash (as2).Image, there is a main "home" flash with several menu buttons.Clicking these buttons, I load external swf into an empty container in this "home" flash.[code]clicking buttons in this second level, will load external movies into an empty container in this SECOND LEVEL swf.This works fine, but now, coming to the THIRD LEVEL (don't think there will be more in the future) problems come up, some scripts won't work.Now (I'm a as2-beginner) I think, loading external swf ALLWAYS into containers in the first "Home" flash should solve the problem.But I don't know, how to load an swf from the third level into a container in the first "home" level.In the "home" level, I have a "close" button, that will unload the container content.I need to go to a certain scene "content_2" in the home swf, too.
i have game im doing, and i want it to jump to level 2 upon completing the first level, but the problem is, the level 2 is a seperate swf, i've tried to use
I have a file1.swf which loads file2.swf into it. Within file2.swf i have a button that when clicked needs to remove file2.swf and load file3.swf into its place.
I have a movie that's 500x400 px in level 0 and has lots of thumbnails with pictures that I want to open. the thumbnails open a 500x400 px movie above the other but on level 1. the problem is that when the new movie loads on level 1, the thumbnails on level 0 (that are now hidden by the new movie) are still active, and if i click anywere in the movie on level 1, it trigger an action from level 0. Is it possible to load a movie to level 1 that deactivates the movie in level 0 without unloading it?
I'm new to Adobe Flash and especially new to Actionscript. Could somebody give an example and explain how to make and "Ignore *this* command if..." style command. Here's what I want to achieve:I have made a button (I may have done it in an odd way but it works) that moves when the mouse hovers over it and then moves back when the mouse moves away. I plan to put the finished product into Dreamweaver and have tried what I've done so far and it works. The problem is that if I move the mouse away before the first animation of the button has finished. It doesn't reach the *Mouse Out* command and then just sticks/stops in the bit where I have put a *stop* command.Basically, what I want is a way to ignore a command if something happens earlier on (such as the cursor being moved away).I've tried to explain the best I can without actually screenshotting it and copying commands.
I have a movie clip with a stop command on frame 1 and a stop command on frame 20.I'm trying to have two separate buttons that tell the MC (onRollOver) to play forward or to play backwards.
The actionscript on button #1- PHP Code: on(rollOver){ gotoAndPlay(_currentframe +1);} The actionscript on button #2-
I an trying to get the _root node of an FLA via JSFL. A co-worker wrote a script that uses _root via actionscript. I was trying to wrap that code into a panel. I have all the trace functionality running and everything running accept I can't seem to access the "_root". I have tried _level0, and almost everything I can think of... I am looking to have JSFL return the _root object from the current file the same way can can hand "_root" to a function. (IE: myfunction( _root ); ) here is my current attempt:
Code: var doc = MMExecute( "fl.getDocumentDOM()._root;" );
I have an external swf, that is a photo gallery, loading into my main swf. When the external swf loads, everything works fine except when you click on a thumbnail in the external swf, the jpg doesn't load. I have it set up that an empty movie clip is created first, then the jpg is loaded into that. I have a feeling it is something with the fact that I am using _root, but I don't have any guesses whats causing the issue and how to fix it.
Edit - managed to find an answer to this by using _parent instead of _root
I've got a swf loader that loads a swf obviously but in the swf that's being loaded I have a button inside of a movie clip which I use...
Code: on (release) { _root.gotoAndStop("page1"); }
When viewing the swf file on its own this works perfectly, however when it gets loaded into the first file it no longer works because the root has now changed to that first file.
I was jsut wondering if it is possible to have the _root fade out, when e.g. loading a something into level1 and then have _root fade back in when unloding level1?