A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: on clip event text scroll

  1. #1
    9th Grade WC
    Join Date
    Sep 2000
    Posts
    1,192
    how can i get the scroll to scroll while the mouse is down
    rather than just going down one part
    do i have to loop the movie

    onClipEvent(mouseDown)
    {
    if(this.hitTest(_root._xmouse,_root._ymouse)
    {
    if (_ymouse > 3.2)
    {
    _root.text.scroll = Number(_root.text.scroll) + 1;
    }
    else
    {
    _root.text.scroll = _root.text.scroll - 1;
    }
    }
    }

  2. #2
    Code:
    onClipEvent(mouseDown) { 
     if(this.hitTest(_root._xmouse,_root._ymouse)) { 
      if (_ymouse > 3.2) {
       scrollTextDown = true;
      } else {
       scrollTextUp = true;
      }
     }
    }
    
    onClipEvent(mouseUp) {
     scrollTextUp = false;
     scrollTextDown = false;
    }
    
    onClipEvent(enterFrame) {
     if (scrollTextDown) {
      _root.text.scroll++; 
     } 
     if (scrollTextUp) {
      _root.text.scroll--;
     }
    }
    i might have my up/down mixed up, but that should get you started...

  3. #3
    9th Grade WC
    Join Date
    Sep 2000
    Posts
    1,192
    thanks i'll try that

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center