Everybody likes Google →← AS 3.0 Compiler Errors

What The Flash?

Those annoying little things that you spend hours trying to find out why and as much time trying figure out how to get around them. Here’s some great examples compiled while working on the create trailer feature for the grindhouse site.


First was trying to deploy the feature to the server for standalone testing. The local application worked just fine. However my hastily constructed loading mechanism didn’t take into account my main file since it was being built to be integrated into another piece. Initially that piece was going to handle the main load and therefore was unaccounted for by me. The strange result was that the piece would work in Safari, but not Firefox. No reasonable clue as to why? The real issue became that I was trying to advance to a frame that didn’t exist yet, because the piece was not fully loaded. Lesson learned always make sure you are always loaded.

Another anomaly that appeared during development involved a masked movieclip. The designer used a series of keyframes in a movieclip for the thumbnails and was masking this thumbnail movieclip out with a keyframed mask in the timeline. However I could never get the thumbnail movieclip to retain a frame other than the first. A colleague here recommended that the mask needed to exist at the same point as the thumbnail movieclip or else the movieclip would reset itself each time it was masked. I think the symptom of this issue is true to what he said and the solution became as easy as placing the keyframed mask into a movieclip and using that as the mask. Another developer ran into a similar issue regarding instance names of a masked clip with the same solution. Lesson learned keyframes in masking layers has quirks that involve resetting the symbols they are masking.

Finally after all the trials and tribulations of making the piece work on its own, it was time for integration. Integration of pieces can always be a headache and more detailed information on integration will be reserved for a future post. The major issue involved in integration is almost always first and foremost pathing. Even using extensive relative pathing, you always tend to find some that don’t resolve properly. In certain cases this is due to path quirks of flash itself. Why are the paths of a swf relative to the html document holding itself, but loading an flv into that swf the path is still relative to the swf on the server not to the document the swf is now being housed in? Wow that’s a mouthful, but I think some of you know what I am getting at there ;-)

Whenever in doubt of your flawless development your best bet is to verify that what you are trying to do is able to be done at the moment you are trying to do it. Failure to synchronize your events and actions will lead you to shout “What The Flash?”

February 22nd, 2007  by Stephen  /  6 Comments

Comments on “What The Flash?”

  1. Yeah, I’ve seen this mask issue you speak of, as well as a few others. Masks are definitely pretty tweaky.

    To contribute to this list of weird Flash occurances, I’ve noticed that if you have a method ‘Play’ or ‘Stop’ in a class and you call them inside that class, they will get treated as ‘play’ and ’stop’ instead. If you call the same methods from outside of the class, the methods are recognized correctly. The work-around to call them internally is to use ‘this.Play()’ and ‘this.Stop()’. I hope that makes sense.

    Ryan Taylor on February 23rd, 2007 at 1:11 am
  2. The pathing issue really bothers me as well. Seems like they just push a half-a**d feature into Flash.

    unformatted on February 23rd, 2007 at 3:15 pm
  3. I usually try to avoid preloading the whole movie. It’s way more userfriendly if they see some content rightaway, instead of some loading bar.. But ya, you have to be really careful.. I went crazy till I figured out that flash can’t jump to a frame if that frame is not already loaded. Actually sounds logic, doesn’t it.

    simurai on February 24th, 2007 at 6:30 am
  4. I typically find that tracing out profanity helps Flash to understand my frustration with it and makes it try harder to resolve any problems.

    Kevin Sweeney on February 24th, 2007 at 9:04 pm
  5. I’ve had both the key frame problem when loading and the similar quirky mask issues as well. I concurr what Kevin said about tracing slanderous words is often useful in one’s frustration.

    Ben on February 26th, 2007 at 2:11 am
  6. Try setting the base = “.” in the embed params. This gets around any pathign issues. Everything is then relative.

    Ashley on March 6th, 2007 at 12:26 am