A Flash Developer Resource Site

+ Reply to Thread
Results 1 to 5 of 5
  1. #1
    Junior Member
    Join Date
    Feb 2004
    Posts
    3

    drag movieclip until y=certain value

    hi there

    i have a movieclip wich follows the mouse in the y position...
    but i need it to stop at a certain y value .....

    this is the script:

    onClipEvent(enterFrame) {
    _y += ((_root._ymouse - _y) / 8);
    }

    how can i do this or am i going the wrong way totally...

    hope you can help me..

    greetz Sander

  2. #2
    AKA [ Paul Bainbridge] webdreamer's Avatar
    Join Date
    Aug 2001
    Location
    Glasgow, Scotland, UK
    Posts
    3,318
    code:

    onClipEvent(enterFrame) {
    _y += ((_root._ymouse - _y) / 8);
    }if(_y>=yvalue){
    trace("border reached !");
    }




    Try this

    Hope it helps
    .: To me AS is like LEGO, Only for the big Kids :.
    - Site - Blog - Twitter - Linkedin
    bringmadeleinehome.com

  3. #3
    Junior Member
    Join Date
    Feb 2004
    Posts
    3
    the script works on 1 minor error

    onClipEvent(enterFrame) {
    _y += ((_root._ymouse - _y) / 8);
    if(_y>200)
    trace("border reached !");
    }

    but if y=200 i want the drag to stop how do i initiate that??


    thanks for youre help......

  4. #4
    AKA [ Paul Bainbridge] webdreamer's Avatar
    Join Date
    Aug 2001
    Location
    Glasgow, Scotland, UK
    Posts
    3,318
    Now that i dont no sorry.

    try some of these links on scripted movement,


    scritped movement

    Forum search

    FK tuts

    Hope it helps
    .: To me AS is like LEGO, Only for the big Kids :.
    - Site - Blog - Twitter - Linkedin
    bringmadeleinehome.com

  5. #5
    Junior Member
    Join Date
    Feb 2004
    Posts
    3
    thanks webdreamer

    for youre effort to help me i think the links will help me out

    thanks again

    cheers

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