2 Replies Latest reply on Apr 29, 2009 9:38 PM by Zealouse

    Huge bug in Flash CS4 verify

    Zealouse Level 1

      Could any one please verify this bug and let me know if it is a bad install or acualy a hugh bug in Flash:

       

      This is what is happening...if I do not give instance names to the buttons on frame 1, frame 2 buttons WILL NOT work even if they are named...also doing a trace of objects shows they are given the flash default names...as though I hadnt named them...here is the FLA I saved it as CS3 :

      http://alphagraphicdesigns.com/help/Flash_bug.fla

       

       

      these are the steps to get it to happen:

       

      1. Create a new document using Action script 2

      2. Draw out a vector rectange using the rectangle tool

      3. Right click and turn it into a button (dont give it a name leave the default)

      4. Copy and past it 5 times on frame one (do not name any of the buttons)

      5. Name only one of the buttons "navigate_bnt"

      6. Past the below code on frame 1

       

      ///////////////////////////////////////////////////////////

      navigate_bnt.onPress = function() {
      gotoAndStop(2);
      };
      ///Loop and find all objects
      for (var Object_Name in this) {

      trace("frame 1: "+Object_Name);
      }
      stop();

      ///////////////////////////////////////////////////////////////

       

      5. Create a frame on Frame 2 of the timeline

      6. Past the button 5 times on frame 2

      7. Name 1 of the buttons "navigate_bnt."

      8. Name 4 of the buttons  on frame 2 : "bnt_1","bnt_2" ect..

      9. Past the below code on frame 2

       

      /////////////////////////////////////////////////////////////

      navigate_bnt.onPress = function() {
      gotoAndStop(1);
      };
      bnt_1.onPress = function() {
      trace(this._name)
      };
      bnt_2.onPress = function() {
      trace(this._name)
      };
      bnt_3.onPress = function() {
      trace(this._name)
      };
      bnt_4.onPress = function() {
      trace(this._name)
      };
      ///Loop and find all objects
      for (var Object_Name in this) {

      trace("frame 2: "+Object_Name);
      }
      stop();

      ////////////////////////////////////////////////////////////

        • 1. Re: Huge bug in Flash CS4 verify
          Ned Murphy Adobe Community Professional & MVP

          I guess this would be considered a bug, it's always bugged me, but it's nothing new to CS4 as far as I can tell.  I've dealt with it for as long as I can remember.

           

          The usual fix is to either name things at both frames, or separate the keyframes (blank keyframe between, etc)

          1 person found this helpful
          • 2. Re: Huge bug in Flash CS4 verify
            Zealouse Level 1

            Hi Ned,

             

            Thank you for verifying this and the suggestion...

             

            The issue with adding the "blank frames" is the flash player slows to about 4 times slower to render out the new frame.

             

             

            I have decided to place the code directly on the buttons, because I have found that sometimes a button's name will change as well and call on the wrong function....So this is very weird that I can dynamically change a buttons name hardcoded in! I cannot take the risk of the button firing off the wrong function as this could seriously injure someone. This program controls some big machinery.

             

             

            The issue seems to stem pretty deep into the flash engine and effects all "Objects".

             

             

            For example:

            1. On Frame 1 name all of the objects

            2. On Frame 2 rename all of the objects

            3.On Frame 3 do not name the objects

             

            On frame 1 gotoAndStop(3)

             

             

            all of the buttons are named from frame 2 !!!!

             

             

            So even though I have skipped frame 2 the unnamed objects pick up frame 2's names and label the unnamed objects.

             

            So I would think the player would skip over frame 2...like a hard drive would indexing....but rather the flash player acts like a tape recorder having to seek to a position in the timeline.