0 Replies Latest reply on Nov 6, 2006 11:50 AM by graphicpoet

    Button controlling more than one Horizontal (Scroll Object)

    graphicpoet
      Hello All,

      I am trying to control 2 scroll objects with ONE button.

      here is my button props:

      on (press, dragOver)
      {
      tellTarget("right")
      {
      gotoAndPlay(2);
      } // End of TellTarget
      }
      on (release, releaseOutside, dragOut)
      {
      tellTarget("right")
      {
      gotoAndStop(1);
      } // End of TellTarget
      }
      AND simply the "right" is "left" respectively on the other button

      here is the object I wish to duplicate and run:

      onClipEvent (load)
      {
      scrollspeed = 5;
      }
      onClipEvent (enterFrame)
      {
      if (!Key.isDown(39))
      {
      if (Key.isDown(37))
      {
      this._x = this._x + scrollspeed;
      if (this._x >= 2150)
      {
      setProperty("_root.scroll", _x, 2150);
      } // end if
      } // end if
      }
      else
      {
      this._x = this._x - scrollspeed;
      if (this._x <= -2196)
      {
      setProperty("_root.scroll", _x, -2196);
      } // end if
      } // end else if
      }
      The above instance name is "scroll"

      ANY suggestions?

      Thanks in advance