1 Reply Latest reply on Oct 1, 2008 8:25 AM by James Newton, ACP

    Sprite Problem

      I am trying to replace a sprite so that when the user clicks on the button, the image is replaced with another. I have the following code in place

      on mouseDown me

      When I tested this in an clean project it worked fine, but in the main project the replaced sprite appears in the centre of the screen as opposed to being in the same place as the clicked sprite.
        • 1. Re: Sprite Problem
          James Newton, ACP Level 3
          This sounds as if it may be a registration point issue. I assume that both the original member of the sprite, and member "settings_en_r2_c6_f3" are bitmaps. Open these in the Paint window (double-click on the cast member or the sprite), then select the second tool from the top in the left-hand column. This is the regPoint tool and it looks like a marksman's sight. In the Paint window, you will see a horizontal and a vertical dotted line. These indicate where the sprite will be positioned with respect to the sprite's #loc (location) property. If you move the regPoint around, the sprite's position on the Stage will move.