ActionScript 3.0 :: Replace A Swf On What Used To Be Called Level

Sep 17, 2010

I'd like to replace a swf on what used to be called level 1, with another swf on level 1, by just loading a swf on that level, from the swf currently on that level, so it kicks out the current swf that called the new swf - just like it used to be in the old days of as2 How can I do this with as3? Do I just do an add swf with a remove swf straight after?

ActionScript Code:
var myLoader:Loader = new Loader(); addChild(myLoader); var url:URLRequest = new URLRequest("myExternalMovie.swf"); myLoader.load(url);
myMovieClip.loaderInfo.addEventListener(Event.UNLOAD, closemyLoader0);

View 9 Replies


Similar Posts:


ActionScript 2.0 :: How The Level Names Could Replace With Variables

Oct 7, 2006

I've a problem with accessing different levels..

actually i'm in the 6th level of my swf and i need to access a movieClip in the 2nd level .

Is it possible to use variable names instead of giving the real level name and movieClip...

My code is something like this...

var levelData:String = _level2.mc_myMovie;
levelData.onRelease = function()
{

[Code]....

View 2 Replies

IDE :: Unloading A Movie - Can't Put The LoadMovieNum In 0 Level Because It Would Replace The Main Stage

Feb 26, 2009

I can't seem to unload a movie, I've tried every possible actionscript code and still it won't go away. My objective is to run in the main stage a sub menu and for that I've done sub pages each one with a previous and next button (inside the movie that will be loaded), and that's the catch. I can't put the loadMovieNum in 0 level because it would replace the main stage. So I'm trying to do on the button:

on (release) {
unloadMovieNum(1); // it was loaded into level 1
loadMovieNum("new_item.swf",1); // he overlays both movies with transparency
}

Is there anyway to remove the actual movie and replace it with the new one?

View 3 Replies

Media Server :: Microphone Activity Level At -1 Even Though Microphone.getMicrophone() Is Called, Why?

Oct 7, 2009

I'm setting up an application where I need to record users' voice every so often during the course of the users' interaction with the application.  Recording is fine, and the quality is fine, but now my issue is understandng how Flash handles the microphone when it gets attached to a stream for publishing.Basically, the problem is that when I "publish" my stream, the voice gets cut off (clipped) at the beginning.  So, I initially thought this may have to do with buffer settings on the FMS server side, but it wasn't. Then I investigated client side stuff.  For some reason, my internal mic .activityLevel property is -1 even though I have called Microphone.getMicrophone().  According to Flash's documentation, this shouldn't be the case:
 
activityLevel    propertyactivityLevel:Number  [read-only]Language Version :     ActionScript 3.0Player Version :     Flash Player 9The amount of sound the microphone is detecting. Values range from 0 (no sound is detected) to 100 (very loud sound is detected). The value of this property can help you determine a good value to pass to the Microphone.setSilenceLevel() method.If the microphone is available but is not yet being used because Microphone.getMicrophone() has not been called, this property is set to -1.I am using a timer to investigate the microphone .activityLevel property every 50 milliseconds:
 
package
{
import fl.controls.Button;
import fl.controls.TextInput;[code].....

View 1 Replies

ActionScript 3.0 :: .replace Won't Replace - Array With A String As Each Entry

Sep 21, 2010

I'm having some real trouble getting .replace to actually replace something. Here's my code...

[Code]...

I can trace both newFiles[i] and keywords[i][whatever], but the replace doesn't replace anything. The regex is valid as well. I'm using regexr to test it, and it works perfectly there... but will not for me and I don't know why.

View 4 Replies

ActionScript 3.0 :: Load An External Swf Called 'signs.swf' Into An Empty Mc Called 'signholder'?

Apr 12, 2010

I want to load an external swf called 'signs.swf' into an empty mc called 'signholder'.

var loadit2 = new Loader();
loadit2.load(new URLRequest("signs.swf"));
signholder.addChild(loadit2);

Everything works. Cool. But, I now want to target something within the signs.swf. How do I do it though? What is the path? Do I have to give the child of signholder an instance name? Everything I try fails.

If I wanted the root timeline of the external swf to gotoAndPlay(2) for example,...would i say...

signholder.loadit2.gotoAndPlay(2) ???
var wow:MovieClip = loadit2.content as MovieClip;
wow.gotoAndPlay(2) ????

View 3 Replies

ActionScript 2.0 :: Create A Level Select Screen So The Buttons Unlock Complete A Level?

Apr 22, 2011

im trying to create a level select screen so the buttons unlock as you complete a level, so far i have this on each button:

on(release){
if(this.number <= currentItem){
gotoAndPlay(3);
}
}

[Code]...

View 0 Replies

ActionScript 3.0 :: Movie Clip Called CircleFill And Another Called CircleOutline?

Oct 30, 2007

I am having issues with startDrag(). I have a movie clip called circle. Inside circle, I have a movie clip called circleFill and another called circleOutline.onEnterFrame, this movieClip is duplicated 4 times.

When I use this:
private function onPressNow(event:MouseEvent):void
{
startDrag();
}
IT DRAGS ALL 4 MOVIECLIPS.

[Code]...

how can I make it drag my movieClip called circle? (meaning both circleFill and outlineFill)

View 8 Replies

ActionScript 3.0 :: Called InfoBox That Contains A Text Field Called Caption?

Oct 24, 2011

i have a box called infoBox that contains a text field called caption. infoBox expands on mouse-over. When it does so, I do not want the text in caption to scale up - I want it to stay at 11 pt. So far my code to prevent this from happening is not working:How do I fix this?[URL]..

View 2 Replies

ActionScript 1/2 :: OnLoad Working At _root Level But Not At Mc_target Level?

Aug 26, 2010

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. 

View 3 Replies

ActionScript 3.0 :: Application Level Vs Document Level Class Paths?

Oct 2, 2010

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.

View 1 Replies

ActionScript 2.0 :: Load Swf From Third Level Into Container In First 'home' Level

Dec 26, 2011

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.

View 7 Replies

ActionScript 2.0 :: LoadMovie - Jump To Level 2 Upon Completing The First Level?

May 9, 2004

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

Code:
on (release) {
loadMovie("level2.swf",2)
}

View 3 Replies

Calling A Swf From1st Level To Go From 3rdlevel To 2nd Level

Dec 2, 2009

I have called main.swf into a container in index.swf.

myMCL.loadClip("main.swf","container"); is an action on my Index.fla timeline.

I have my navigation on index. (i wanted it to go on main, but the nature of the animation meant it had to go on index)

I need to call "home.swf" into "main.swf" from the navigation button in Index.swf.

When I had the navigation on "main.swf" this was my code to call "home.swf" into the page.

on (release) {
Preloader_mc.gotoAndStop("home");
}

("home") is the label name where the preloader is for home.swf

how to call the preloader for home into main.swf from "INDEX.SWF INSTEAD OF MAIN.SWF"

View 5 Replies

ActionScript 3.0 :: Calling Swf From Second Level Swf To Affect Top Level

Feb 2, 2010

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.

View 2 Replies

ActionScript 2.0 :: Link To One Level Below The Current Level?

Sep 16, 2004

Is there a way to link to one level below the current level? Instead of saying _root.level1.level2.level3, something like: ../level3 ?

View 4 Replies

ActionScript 3.0 :: Crossdomain Policy File On Root Level Cannot Be Deployed On Root Level? 

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

ActionScript 2.0 :: Load A Movie To Level 1 That Deactivates The Movie In Level 0 Without Unloading It?

Nov 5, 2004

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?

View 1 Replies

Wordpress Based Site That Stores Information About An Image In A Database Field Called "background" In A Table Called "wp_postmeta"?

Jul 22, 2009

I have a wordpress based site that stores information about an image in a database field called "background" in a table called "wp_postmeta".The 'loader' gets an url such as "/thisImage/background.swf"The "background.swf" should somehow display "background.jpg" instead but since I've changed the field name in the database (from background to temp_background) it doesn't work.I pass variables to the "loader" swf and they are correct based on the new field name but it still isn't working.I need to know if there is anything in the .fla's (and therefore the .swfs) that is pointing to somewhere in the database hard-coded. Basically I need someone to look at them and tell me how they are working.

View 2 Replies

ActionScript 3.0 :: Target Path - Control A Movie Clip Called "nosotrosmc" With A Frame Label Inside Called "historia"?

Oct 5, 2009

i'm trying to control a movie clip called "nosotrosmc" with a frame label inside called "historia" but does not work this is the code:

[Code]...

View 2 Replies

ActionScript 3.0 :: Flash String.Replace Won't Replace "%20" From An Original String

Jun 22, 2011

I've got a strange situation where I'm replacing the text in a string that I've taken from an XML, but the .replace function for the string keeps failing. I've tried running the example given on the Adobe site, so I know the value I'm trying to replace ("%20") isn't at fault - it's something about the string I have! I've included the code below, but it seems correct. Is there a particular tip I should know when taking XML values into AS3? I'm putting them in strings for this project.

[Code]...

View 5 Replies

Actionscript 3 :: Movie Clip Called Axeframe With Yet Another Movie Clip Called Axe

Aug 24, 2011

i have a movieclip on my stage called dude inside the moviclip is a frame with a movie clip called axeframe with yet another movie clip called axe. what i want to do is make a hittest in the axeframe a so that when the axe (only axe not the character) hits an enemy(named enemy) on the stage he will disappear. this is my code:

[Code]...

View 1 Replies

ActionScript 1/2 :: "A.swf" On Level 0 To A "B.swf" On Level 1 With A "gotoAndStop(5)?

Aug 17, 2011

how i can refer from a flash "A.swf" on level 0 to a "B.swf" on level 1 with an "gotoAndStop(5). I tried it with:
 
loadMovieNum("B.swf", 9), gotoAndStop(5);
 
and other variations. It didn´t work anytime.how it can work?

View 1 Replies

CS3 :: Anyway To Replace A Movieclip?

Apr 4, 2009

I am making a simple platformer game with weapons and so far everything is good but i need to find a way to make it so when the player touches an object it replaces the movieclip with something else? [code]...

View 4 Replies

ActionScript 3.0 :: Replace XML Tag With Another One?

Sep 23, 2009

I'm having trouble figuring out how to call an XML tag itself (not the value of the tag). I have a program that reads data from specifically named tags. I.E the program understands the tag <image> and the xml file i'm loading has a similar reference but calls the tag <picture>.

How do I replace the <picture> tag with <image> so it understands it?

View 1 Replies

ActionScript 2.0 :: Replace A Color With Another?

Apr 10, 2009

I'm making a game, and I want to have a "team color" sort of effect. What I want to do is be able to replace a color in a bitmap with another color, but I'm not sure if this is possible. I don't want to tint the entier clip, just a certain color on it...can this actually be done? For those who have played games like Starcraft and Warcraft, to identify which team you're on each unit has your color (like red, blue, ect) on it. This is accomplished by painting those parts of the unit a light grey, and then tinting the grey the proper color.

View 3 Replies

ActionScript 3.0 :: Replace Images With XML?

Oct 19, 2009

What I'm working on is the following: Make a 3D image carousel that loads images from a certain XML file. When I click one of the images I want it to remove the rotating objects, and load new/different images from a new XML which is specified depending on what image you clicked.

I'm not sure if I have to make a new frame for this, or if it's able to load in the same frame etc. (I'm kind of having a bad headache and feeling really sick aside the lack of sleep) Current health status makes me kind of unsure of a lot of things, so I'll give you the full code, the problem is way at the bottom, but I kept in the rest in case I have to refer to other functions again later.

Code:
//We use 70x70 sized images (change this if different for your images)
const IMAGE_WIDTH:uint = 70;
const IMAGE_HEIGHT:uint = 70;

[Code].....

View 1 Replies

ActionScript 3.0 :: Replace One Swf Movie With Another?

Jan 31, 2009

I have a flash movie on my web page and I have made some of the text inside the movie into buttons. The movie only takes up a portion of the page. I would like to replace the movie with another movie when somebody clicks the button.

View 8 Replies

How To Replace Mouse Cursor

May 7, 2009

How would you replace the mouse cursor in ActionScript 3?  I mean with like a movie clip or a graphic within Flash.

View 1 Replies

ActionScript 3.0 :: Replace Value In A Xml Node?

Dec 19, 2009

i have an xml like this one, How can i change the values of the nodes  <adposx> and  <adposy> of the node array "YAYA" .I did that :

this.Pages.page.adverts[1].adposx= newvalue;
this.Pages.page.adverts[1].adposY= newvalue;
but it dont work

[Code].....

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved