PDA

View Full Version : Crashes/errors/instability


General Tso
08-18-2009, 05:32 PM
I'm pretty new to Flash. I have slowly built up an .fla file to its current size of 44MB. It is in AS3 (CS4) and has numerous jpegs imported into it with animated masks over each. I am importing the jpegs by simply going file > import to stage. Most of the jpegs are around 700 KB or so. Some were much larger, so I took them into Photoshop and manual changed the image size to the exact pixel dimension that I wanted in the Flash file. For the 700 KB images I imported and then resized within Flash. Should I resize them all in Photoshop?

I am now experiencing multiple issues that have made it impossible to work on it.

1. A week ago I started occasionally getting "Flash has has unexpectedly quit" error messages, whereupon Flash would crash. This was before I started adding many of the jpegs and the file size was still something like 5MB. Now I receive these messages almost constantly - If I try to open a second file within Flash or when I just work in my main file for a few minutes.

2. A few days I ago I started getting a few random messages saying "error initializing java runtime environment you may need to reinstall flash". This was fixed by simply restarting Flash, but still troublesome. I have since updated to the most recent Java version.

3. Rarely I would finish working on something and try to test the movie. It would go through the loading bar, but then nothing would happen. The only way to fix this was to go back to a previous file version and rebuild from there. My current file save has this problem.

Now I am stuck because I have to go back quite a ways to find a file that will successfully test. On top of that if I try to import one of my new movieClips into the older file version, Flash of course crashes.

Is the file too big? It doesn't feel like I'm doing that much. I've definately seen flash sites that have way more going on than mine. Could it be all the imported jpegs? Could I be importing them in a bad way? How can I avoid/fix these issues?

CyanBlue
08-18-2009, 05:43 PM
No, that file is not big at all... I've heard of people using over 100MB FLA files...

First of all, open up your file, and do Save As and save it to a different file name... and use that one to see if that file causes the problem... If you still get the error messages, send it to somebody else and have them test to see if they get the same meesage... If they do, your file probably is corrupted...

Start working on a new FLA file on a mock project and see if you are getting any of those error messages... If you do, you probably need to reinstall the Flash...

Speaking of the image... Create a new FLA file, import all those images you think you are having trouble with... save the FLA file... Open up the Library panel, click through them one by one to see if you can find the problematic file... I remember loading a sequence of images, one of the images does not show up when I click through them in the Library... I ended up saving that image again from the Photoshop with different setting which did not give me trouble... Hopefully that is the case to you cuz it is an easy fix once you figure out which one is causing the problem...

General Tso
08-19-2009, 12:32 AM
Thanks. You have me on my way to resolving these problems. I tried saving as a new file and other things. None worked. It's weird because I can go back a few file saves and experience the same problems. But if I go back far enough they go away. So it makes sense that it's an issue related the jpegs.

Your suggestion to check the jpegs in the library was what did it. A handful of them showed up blank. I resaved in photoshop and reimported to the library, replacing the old images. Well, I'm partway through doing this anyway. But deleting them all (that's what I tried first) fixed the problem of not being able to test the movie. It's taking a while to actually replace them all because I keep getting crashes. And at one point the ability to test the movie failed again, so I had to start over and start saving in increments.

I think this will help a lot, but the crashes are partly a seperate issue. I think it's a RAM problem. I was surprised, but the 'performance' tab in Windows Task Manager showed that I was using 84% of my RAM. I have 2GBs which I thought was enough. I guess I should get a little more, but I'm only on Windows Vista 32 so 3GBs is the max. Does this seem unusual that I'm using so much of the RAM on Flash? The only other thing I have open is IE.

CyanBlue
08-19-2009, 03:28 AM
I don't think it is the memory issue... I think it's the case where Flash is not correctly recognizing the image file, period... :(

General Tso
08-19-2009, 09:49 PM
If it truly has nothing to do with RAM, then the question is why isn't Flash correctly recognizing the image files?

Anyway, I seeked out all the non-showing images in the library and replaced them. This made it so I can successfully test my movie now, which is fantastic. But after that, I occasionally started seeing some of the images show up as solid red boxes. This would also sometimes lead to Flash freezing, then crashing. Yay.

After more searching the net, I came upon three different Adobe articles which explain the 'red box' problem. All three had a different cause/solution:

This one (http://kb2.adobe.com/cps/138/tn_13864.html) says there's not enough RAM allocated to Flash, but it seems to be Mac-based, and I thought my computer auto-allocated memory anyway...

This one (http://kb2.adobe.com/cps/141/tn_14164.html) says it's caused by inserting objects. I have been importing, so I would imagine this wasn't the issue.

And this one (http://kb2.adobe.com/cps/403/kb403360.html) says it's due to large JPEG file image compression. My JPEGs are fairly normal size but....

regardless, I decided to resize every single JPEG to the actual pixel dimensions I use in my file, which ended up reducing most of the images by atleast half. This got rid of all the evil satanic red boxes.

I only recently managed to solve all this, so while it's operating smoothly now, we'll see if the crashes persist down the road.

Thanks for all the help. Most appreciated.