2 Replies Latest reply on Mar 18, 2009 4:45 AM by Newsgroup_User

    help with rollovers!!!

    ryaneld
      im trying to change a background image using a button rollover. the code im using is:

      on mouseEnter me
      Sprite(1).member = member ("picnic copy")

      end

      on mouseLeave me
      sprite(1).member = member ("blk" bg")
      end


      the code works but the image that replaces "blk bg" is out of place, hanging off of the stage!..... i have no clue how to fix this as i am very new to director. any help you could provide would be greatly appreciated.
        • 1. Re: help with rollovers!!!
          Level 7
          Assuming that the images are the exact same size, do this in the message
          window:

          member("picnic copy").regpoint=member("blk bg").regpoint

          You should only have to do that once and it will fix the problem. Once
          it has been done, save the dir file, and you will not need to do it
          anymore as long as those members have the same images
          • 2. Re: help with rollovers!!!
            robdillon Most Valuable Participant
            You probably need to change the registration point for the cast member that seems out of place. Open the member in the paint window and double click on the reg point tool. That should center the registration point on the cast member. Try the movie and see if that fixes it. If it's still out of alignment,then go back to the paint window and change the reg point's location a little at a time until the sprite lines up as you want it.