A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: levels targetPath

  1. #1
    Senior Member
    Join Date
    Jun 2001
    Posts
    250

    levels targetPath

    This code is on the root of a movie, it workks fine. However, when i load it into level 100(from another movie) , the snap-to code no longer works.

    I've worked with levels a lot, but this really stumps me.

    I've tried many many variations to taget the correct path, _levels. _root, this._name, targetPath,

    The basic code appear below.

    //code on root movie
    onEnterFrame = fsnapto;
    function fsnapto(){
    //trace("pushed @ snapto ==" +choices);
    // target1
    area_oftarget_x = target1._x;
    area_oftarget_y = target1._y;
    //target2
    area_oftarget_x2 = _root.target2._x;
    area_oftarget_y2 = _root.target2._y;
    }
    // == end snap to==


    // code on buttons
    on(release){
    if(_root.a3._droptarget == "/target1"){
    trace("dropped 3================" +this.targetPath);
    _root.fchoice("a3");
    _root.a3._x= area_oftarget_x;
    _root.a3._y= area_oftarget_y;
    }
    }

  2. #2
    God Bless AMFPHP
    Join Date
    May 2004
    Location
    in a far far place
    Posts
    144
    hi iaustin!, i was lookin for something like this...working with levels, do you have any fla that you could share to see how this is possible?

    i did this:
    _level1.gotoAndStop(3);
    but i canot actually have it working
    Programming is literature, webdesign is art
    Check out my blog at www.asb-labs.com/blog Preguntas??? ---> Respuestas www.asb-labs.com/board >hablemos de flash en español<

  3. #3
    Senior Member
    Join Date
    Jun 2001
    Posts
    250
    You wold have first loaded a movie into level1...
    loadMovie("mymovie.swf", "_level1");
    Then your command should work.

  4. #4
    God Bless AMFPHP
    Join Date
    May 2004
    Location
    in a far far place
    Posts
    144
    i used loadMovieNum();

    do you think it is the problem?
    Programming is literature, webdesign is art
    Check out my blog at www.asb-labs.com/blog Preguntas??? ---> Respuestas www.asb-labs.com/board >hablemos de flash en español<

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