1 Reply Latest reply on Jun 29, 2007 9:42 AM by Newsgroup_User

    mouseX and mouseY

      nevermind....I figured it out. mouseX and mouseY does give the reading on the stage, not the underlying symbol.
        • 1. Re: mouseX and mouseY
          Level 7

          > does the mouseX and mouseY property read where the
          > mouse is on the stage or where the mouse is over a symbol?

          It depends entirely on the object on which these properties are invoked.
          Ideally, to avoid confusion, they should be preceded by an object reference.
          In ActionScript 3.0, which is what it looks like you're using, these
          properties originate with the DisplayObject class. This class "passes its
          genes," so to speak, to numerous progeny, including movie clips and buttons
          (instances of the MovieClip and SimpleButton classes, respectively) and even
          the Stage.

          So the following quick example will show the mouse's x position in
          relation to the Stage:

          function():void {

          While this will show the mouse's x position in relation to a movie clip
          symbol with the instance name "square":

          function():void {

          David Stiller
          Co-author, Foundation Flash CS3 for Designers
          "Luck is the residue of good design."