4 Replies Latest reply on Apr 6, 2009 8:39 AM by Rothrock

    flipping speech bubbles?

    shintashi Level 1
      Basic scenario, sprite programmed to say various stuff in a speech bubble (used a dynamic text field inside an MC located inside the sprite). But when the sprite gets too close to an edge of the screen, the bubble goes off the screen. So I made a basic fix for testing:

      robot_mc.talk_mc.bubble_mc.onPress = function(){
      robot_mc.talk_mc.bubble_mc._yscale = -100;

      but noticed the text didn't appear anymore. Before I switch out the "onPress" for something XY coordinate related, is there something I need to do to address the textbox, or am I going about this completely wrong?
        • 1. Re: flipping speech bubbles?
          Ned Murphy Adobe Community Professional & MVP
          What is that fix supposed to be doing?
          • 2. Re: flipping speech bubbles?
            Rothrock Level 5
            I think the problem is that the textfield inside the bubble is now also having a _yscale of -100 and perhaps you didn't embed the fonts for the textfield it isn't showing. Show first embed the font. If you don't know how let us know.

            The next thing to do after that is add:

            robot_mc.talk_mc.bubble_mc.mytextfield._yscale = -100;

            Also I recommend flipping by

            robot_mc.talk_mc.bubble_mc._yscale *= -1

            Just incase it started at 80 or something you don't actually want it at -100 but rather -80. Just a lesson learned....
            • 3. Re: flipping speech bubbles?
              shintashi Level 1
              ah right!, *= -1; that makes a bit more sense. What I think I can do is probably make two parts to the icon instead. One part is the bubble itself with the textbox inside, the second part is the pointy piece connecting the mouth and the bubble, the pointy piece flips, but the bubble doesn't, that way I don't have to imbed the font.

              Ned -- the testing fix was to see if the textbox+bubble would flip upside down at all - the bubble flipped but the textbox disappeared.
              • 4. Re: flipping speech bubbles?
                Rothrock Level 5

                Two parts to the bubble clip are probably the best approach, but generally I recommend embedding the font. There are so many things like masking and rotating and alpha that all rely on having the font embedded that it is generally a good idea to do it.

                1 person found this helpful