ActionScript 3.0 :: Code Stops Working When Delete Another Layer?

Oct 17, 2009

I am working on a project in flash cs4 and have Adobe Air 1.5 as player as this will be air appi. But other than using localstore to save my data everything else is pure flash as3 code. Nothing special really. And I was just about to finish it when this problem occurred. If I delete a layer that has nothing else but a picture inside which I was using to position movies correctly, everything in frame 3 where my main code is stops working. It doesn't trace anything, it just stops but actions on frame 1 and 2 work just fine. I don't get any errors either.

I deleted all the code from my main action layer in frame 3 and it still doesn't trace simple trace("aa");. As if everything I've put on the layers can't be changed or it just stops working. Same thing if I change a sound in the library, just updating it with another and it stops working. I just can't find the answer really. I rearranged things, deleted movies, basically everything and still no answer. I even tested it in flash cs3 and same thing happens. But I used this kind of methods before (deleting layers that I didn't need) and never had this problem before.

View 0 Replies


Similar Posts:


ActionScript 3.0 :: Class Code Hints Stops Working?

Nov 15, 2010

I've been really frustrated with the code hinting in CS5. It doesn't seem to work like it should. It appears to work fine if I am placing the code on the timeline, but if I create a class file I lose the class code hinting even for simple types like Boolean. The other thing I noticed is after the class file has been created even if I go back to the code on the timeline it has now lost code hinting. The only way to get them back is to close the fla I was working and close flash itself.how to resolve this or is this a legitimate bug? If others have seen this happen please post so that we can get some attention brought to this. It seems to work fine if you create flex components and then edit them in Flash Builder.

View 5 Replies

ActionScript 3.0 :: Delete Row With Code=4, But In The DetailTable, All The Rows With Code=4 Are NOT Deleted?

Feb 4, 2010

I have 2 tables,a main table with a field code as primary key, and other table detail, named p.e. DetailTable, with 3 fiels as primary key.What I want to do, it's a delete a row in MainTable, all the rows in DetailTable,where field code is the same as field code in MainTable should be deleted too.Here is the SQL to create the tables.

var sql2:String = "CREATE TABLE IF NOT EXISTS MainTable [code]....

when tables are created, insert data. I connect without problems, delete a row in MainTable (see the code), for example delete row with code=4, but in the DetailTable, all the rows with code=4 are NOT deleted Why?

[CODE]// Inside a class
private var conn:SQLConnection; 
public function constructorClass(){conn = new SQLConnection();ConexionBD();}[code]...

View 3 Replies

ActionScript 2.0 :: Delete OnEnterFrame Causes Later Code To Not Run?

Jul 12, 2005

i have this code:

Code:
gallery_mc.thumbs_mc.onEnterFrame = function() {
if (this._currentframe == 95) {
loadThumbs(0);
delete this.onEnterFrame;

[code].....

problem is when i get to 95, everything works well, but when i get to 105, the onEnterFrame had already been deleted so that code doesnt run anymore. how can i accomplish this so that the code on 105 runs?

View 6 Replies

ActionScript 2.0 :: Get Code To Delete/remove The Last Movieclip?

Jul 13, 2011

I was wondering how to get my code to delete/remove the last movieclip'cause whenever I go to the gameOver frame the loop to remove all the movieclips leaves out one.

ActionScript Code:
function removeEnemies(spike) {
for (i=0; i<count; i++) {
_root["spike"+i].removeMovieClip();
}
}

View 1 Replies

IDE :: One Button Stops Working?

Oct 16, 2009

I have some movie clips that hold the contents. (ie I have a movie clip to hold my navigation buttons and another to hold the actual content.) I wrote some action script on a separate layer that is outside of the movie clips, the AS adds event listeners and a few simple functions. All my navigational buttons work prefectly, I have a button that I use for email, this works the first the frame is loaded. If I go to another frame (another page of the website), and then go back, the button no longer works, I tested with just using trace("the email button was clicked"); oh, I thought I might add that each page of the website is a different frame, that is inside my content movie clip. my AS looks like this:

stop();
navigation_mc.home_btn.addEventListener(MouseEvent .CLICK, homeClickF);
navigation_mc.rates_btn.addEventListener(MouseEven t.CLICK, ratesClickF);

[code].....

View 3 Replies

Edit Contents - Delete Contents Of The Layer And Then Add The New Clip?

Oct 12, 2009

I'm customizing an xml flash website and while I can handle all the html and xml well enough, but in Flash, I have no clue how to:
Now go on the stage, and delete the contents of the last layer(background & pattern). Here, add from the library, the square movieclip, and name it mcBackColor(see attached image).And then to add your swf background in the "background & pattern" layer from the main.fla file.
 
I can change the name, but don't know how to delete just the contents of the layer and then add the new clip.I've made a slideshow before and that's all I can do.

View 1 Replies

ActionScript 3.0 :: Stops Working On Update?

Jun 18, 2009

I updated FlashPro from 10.0 to 10.0.2 through the adobe updater.After the update applied, Flash ignores any code entered on my action layers as if it were not there, even simple stop(); command.

View 2 Replies

ActionScript 3.0 :: Aniamtion Stops Working?

Oct 17, 2010

I have a Flash Animation which i am running in a Browser Window .. Suppose a Man moving from Left to Right and also a BackGround MusicNow when I change the browser Tab to suppose check my gmail account while the man completes his walk from Left to Right .. The problem is the music is running but the man freezes at his place and continues his animation only after i return to the Flash animation containing browser Tab.

View 2 Replies

CS3 :: Reach Different Symbols In A Layer By Code?

Mar 17, 2010

The thing is, I am coloring though code the parts of a body, which is a movieclip composed by other movieclips. I am coding in AS2, using the setRGB function from the Color class. Everything is working ok, but there is one arm that is not being colored.

This arm actually is in one layer with several keyframes, half of them have one symbol, and the other half have another symbol. Both symbols represent the arm in different positions. Now, even though they are different symbols, I have named both instances with the same name, but with this solution the arm is not being colored. So I tried to remove the keyframes with the second symbol, and then it got colored.

To sum up, I don�t know how to reach all the symbols in different keyframes of the same layer through code.

View 4 Replies

ActionScript 2.0 :: Hittest Stops Working After Loadclip?

May 30, 2007

1 main flash movie called game.swf 1 external flash movie called maze.swf

The thing is from my main movie game.swf I load the external "maze.swf" true the LoadClip procedure. This works "fine".

The maze.swf as you can guess contains a maze game, and as you all will know this works with the Hittest commando to check if the character doesn't walk up against the wall.

If I start the maze.swf as a stand-a-lone this works fine, but as soon as I load maze.swf in my main movie. The hittest doesn't work anymore, because in some way the hittest is now checking with the coordinates of the entire main movie instead of only the boundaries of the maze.

I checked If I was calling to the right path, with _root and _level0 and etc. This is al correct because I can trace all the properties from maze.swf in my main movie. But the hittest simply won't work.

View 7 Replies

ActionScript 2.0 :: SwapDepths In Array Stops Working

Mar 12, 2009

I'm trying to set up an app that moves one movie clip to the top of the screen, regardless of where it is or how deeply it is nested. To do this, I take the full path of the movie clip and go in, movie clip by movie clip, putting the depth of each nested clip on top. This part works perfectly. Afterwards, I want to move everything back to where it was. In the first step, I store the current depths of everything in an array before changing depths. In the second step, I'm trying to change everything back to its original depth, as shown in the array.

The code is below:
_global.videoPath = _root.clip1.clip2;
var pathString = String(_global.videoPath);
var videoPathArray = pathString.split(".");
var depthArray:Array = new Array();
[Code] .....

View 1 Replies

ActionScript 3.0 :: Sound Stops Working Randomly?

Dec 6, 2009

I imported a .aif sound in to my library and gave it a class name of "Beat". I'm using this sound as a rollover effect. So I have my variable initiated at the top like so:

Code:
var snd:Beat= new Beat();
My listener's function like so:

[code].....

View 1 Replies

Button Dropdown Stops Working In Timeline

Feb 23, 2010

When creating a dropdown for a button, I noticed the dropdown will stop working if the button does not run the entire length of the timeline. i.e.: if you navigate to a page that is out of that button's "range" it will stop working unless reset by returning to the root page. Nesting the problematic button in a movie, however, solves this problem...

View 3 Replies

Apache Webserver Stops Working Until Disable FMS 3.5?

Jul 14, 2009

I have installed FMS 3.5 on an Intranet server, and it installs its own version of Apache.This has now caused the localhost to open the FMS page. Disabling FMS 3.5 returns back to the Localhost page.It is not possible to run FMS 3.5 on an existing Webserver with Apache?

View 1 Replies

ActionScript 1/2 :: TextField.menu - Something Stops It Working?

Jul 26, 2009

The following code is from the CS3 Language Reference.Pasted into a new file it works.Pasted into my current project it doesn't.what settings I might have that are disabling it?

this.createTextField("news_txt", this.getNextHighestDepth(), 10, 10, 320, 240);news_txt.border = true;news_txt.wordWrap = true;news_txt.multiline = true;news_txt.text = "To see the custom context menu item, right click (PC) or ";news_txt.text += "control [code]....

View 7 Replies

Actionscript :: Stops Working When Save In Flash CS4?

Mar 12, 2010

I've tried it on several different copies on Flash(on college computers and at home) with different files and no matter what, once I save the file, any action script I had will stop working and will never work again no matter what.

When I create a new document and put in some Actionscript (3), it will work at first. For example if I have one line telling an object to have a lower alpha. Then, consistantly, when I go to "save" it'll stop working.

View 19 Replies

ActionScript 3.0 :: Animation Stops Working After Swapping

May 14, 2010

I have a class which extends a SWC , in the swc i have two boxes, front and back and an animation on the same timeline. The animation works fine without swapping when I swap them the animation stops working.[code]...

View 7 Replies

ActionScript 3.0 :: Button Completely Stops Working?

Mar 24, 2011

My friend and I have been working on a game for about a year. There's a few buttons on the stage that have been on the stage for six months, and always worked fine, but today my friend moved them and I just realized they don't work anymore. They are literally completely unresponsive to all mouse input, they have event listeners for mouseover and click but the events never get triggered (I checked for sure with breakpoints and traces).
 
I tried the obvious things first; move the buttons to the top layer and set .mouseEnabled = true, but that didn't do anything. I tried moving them around the stage in case something invisible was covering them but that didn't work.
 
We've got one button instance named "btnSell" that is broken, and another named "btnMenu" that works. They are instances of different objects in the library, but I tried swapping their instance names on the stage; then "btnMenu" was broken and "btnSell" worked.
 
So I swapped the names back, deleted the broken "btnSell" and created a new instance from the library. Only, it still doesn't work.
 
My friend deleted a bunch of old and no-longer-used assets, including previous versions of the PNGs that make up those buttons, so maybe that's related to the problem?

View 2 Replies

ActionScript 3.0 :: Preloader Stops Buttons From Working?

Jun 7, 2011

I made a flash file with buttons that go here and there and everything was fine except it takes a while to load so i added a preloader and suddenly the compiler is throwing the following error:

[Code]...

View 17 Replies

Actionscript 3 :: Animation Stops Working After Swapping?

May 14, 2010

I have a class which extends a SWC , in the swc i have two boxes, front and back and an animation on the same timeline. The animation works fine without swapping when I swap them the animation stops working.

I have the following code :

var frontTemp:DisplayObject = this.animationInstance.getChildByName("front");
var backTemp:DisplayObject = this.animationInstance.getChildByName("back");
this.animationInstance.swapChildren(frontTemp,backTemp);
this.animationInstance.gotoAndPlay("animation");

View 1 Replies

Flex :: >500 Lines In <fx:Script> And It All Stops Working?

May 10, 2011

it's a little ridiculous; and probably unbelievable, but when I have more than five hundred lines of actionscript in tags in my MXML FLEX Main.mxml, all syntax highlighting, error and syntax verification, error reporting, "Problems" pane, and even sometimes compilation fail. Upon removing any chunk of code, it works again.I don't see why Adobe could release a product such as Flash Builder 4.5 Premium, have this big of a problem; and nobody notice. Therefore I believe the problem has to do with my computer, or my project; as there's now ay more people have had this happen if I can't even find it on Google.

Additionally, many objects that have been defined in the MXML properties above the code, even those in All States, are now showing as warning: Access of undefined property down the side of my document. However, these warnings are not showing up in the "Problems pane", and aren't even yellow squigly underlining the right sections of code to pertain to the message.Steps I have taken to TRY and fix this:I have tried restarting, as well as re-installing the IDE (Adobe Flash Builder 4.5).I have tried creating a new projectI have tried splitting my code into smaller .as files and including them.I have tried compiling my application.

View 1 Replies

ActionScript 3.0 :: Loader Stops Working On Server?

Oct 23, 2009

In my current flash application I and my co-workers are using Loader to load some SWFs from our server. It works perfectly while we have the flash application on our computers running it trough Adobe Flash CS3 but when we publish it and move the html page to our server and try and run it from there the loading doesn't seem to start. I have the firebug plugin for Firefox so I checked if flash actually loaded the images and according to firebugs network monitor it found all needed resources and downloaded them successfully. But the behaviour of our application is as if the loading starts but the complete event is never sent.

View 3 Replies

ActionScript 3.0 :: Flash CS3 Stops Working At Certain Script

Nov 28, 2009

I have this piece of script:

function dataImporting(target, type, path)
{
if(type == "IMAGE")
{

[Code].....

This function is suppose to deal with loading requests from different kind of movieclips throughout the movie. There is something wrong with 'load(path as URLRequest)'. It compiles fine, but upon running flash simply crashes over and over (flash stopped working). It seems as if there is something wrong with it but flash not being able to catch the error.

The path is given as an argument to the function in the form of a string, but should be converted to a URLRequest before being able to be loaded.

View 8 Replies

ActionScript 2.0 :: Stage.height Stops Working?

Mar 16, 2010

I have a problem getting my flash to resize when changing the size of the browser window. It behaves perfectly from the beginning but when i resize the window to less then the minimum movie height to get a scroll (620 px) the Stage.height never changes to bigger than 620 px if I enlarger the window. It seams as if the flash don�t get information that the browser window changes...

This is my code in flash:
var movieWidth = 1000;
var movieHeight = 620;

[code].....

View 1 Replies

ActionScript 3.0 :: Animation Stops Working After Swapping?

May 14, 2010

I have a class which extends a SWC , in the swc i have two boxes, front and back and an animation on the same timeline. The animation works fine without swapping when I swap them the animation stops working

I have the following code :
var frontTemp: DisplayObject = this.animationInstance.getChildByName("front");
var backTemp: DisplayObject = this.animationInstance.getChildByName("back");

[code]......

View 1 Replies

ActionScript 3.0 :: NetConnection - On The Mac The App Stops Working After A Few Seconds?

Jul 12, 2009

I have a flash app that I have been working on for 5 months or so, it relies heavily on Flash remoting with numerous custom classes each making service calls via AMF.I have been developing this app in CS4 on Windows and never had any trouble, it works great.I just got CS4 for my Mac and installed it and copied over the flash files for this app so I can continue working on it on the mac instead of the PC, but on the Mac the app stops working after a few seconds, particularly after doing a few commands that issue flash remoting calls.Even stranger is it will not return to working condition again until I close all of the files involved with the project( the .fla and all .as files involved) and then reload them,if I keep trying to test run the movie from the flash editor it hangs at the first flash remoting call and never returns any error message or any indication that its trying to connect, on the server end my logs show no requests are going to gateway.php.So basically to continue working on the mac I'd have to keep closing down the files every few mins and reloading them.

View 3 Replies

ActionScript 2.0 :: Printing - When I Publish The Swf It Stops Working?

Aug 24, 2009

Its set to print a mc that sits off screen with dynamically generated text within. This all works perfectly when i test the movie within flash, it prints perfect. However, when i publish the swf it stops working, instead it prints the corner of the offscreen content.

View 1 Replies

ActionScript 2.0 :: Removing The OnEnterFrame At The Beginning Of The XML To Variables Line Of Code, So That Is Stops Running?

Mar 26, 2006

I have a bunch of thumbnails i'm getting from XML that have this code on them...

Code:
for (e = 0; e < total; e++) {
_root.web_thumbs.thumb_button.duplicateMovieClip("button" + e, e + 12);
_root.web_thumbs["button" + e].c = e;[code].....]);

It loads the XML variable fullimg into an empty movie clip on its own layer in the timeline.The movieclip, "container", is assigned this code, but the code isn't on the movieclip, it's on a frame designated for just actionscript.This is the code

Code:
container.onEnterFrame = function() {
this._x = int(content._x - (content._width / 2) + 30);
this._y = int(content._y - (content._height / 2) + 30);
}

The Problem Is...When there is no image loaded into the movie clip, it works fine, and shifts around depending on the location of the other movie clip, "content". But, once there is an image loaded into "container", it stops shifting around depending on the location of "content", and just sits in its last location.The only thing i can IMAGINE being problematic is, on another frame, where I have the XML being cut up and assigned to variables, at the end I have a remove _root.onEnterFrame, removing the onEnterFrame at the beginning of the XML to variables line of code, so that is stops running.

View 2 Replies

ActionScript 2.0 :: RemoveMovieClip() And Delete X;! NOT WORKING?

Mar 18, 2006

I have already foud out where I want to place my sprites in my game, and I don't want to have to go through th elengthy "duplicateMoveClip" procdure (or it seems to be lengthy to me anyways, it's probably like 2 lines of code, but still, I WANNA DO IT MY WAY!) ok, anyways, does delete only work on variables and not movie clips?here's what I have so farthis is in the bullet movie clip:

Code:
onClipEvent ( enterFrame){
if (Key.isDown (Key.SPACE)){

[code]....

View 6 Replies







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