A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Hit Test

  1. #1
    Junior Member
    Join Date
    Apr 2002
    Posts
    14
    I need sum help with this hit test stuff
    I have 2 movie clips
    one named wall the other man
    the wall is just one side and i used the wall movie clip a few times to form a maze.
    i need for frame one to go to frame two when the man hits the wall
    i have this code but it doesnt work

    wall.hitTest(man);
    if (wall.hitTest(man)) {
    equals;
    true;
    gotoAndStop (2);
    }

    What am i doing wrong? its driving me nuts ive tried everything i know! some one please help

  2. #2
    Senior Member
    Join Date
    Jul 2000
    Posts
    323
    Frame 1:

    if (wall.hitTest(man)) {
    gotoAndStop(3);
    }
    Frame 2:

    gotoAndPlay(1);

    Frame 3:

    //Code for when he hits the wall

  3. #3
    Great, Daddy-O! Hippyscum's Avatar
    Join Date
    Feb 2002
    Location
    Pays-Bas
    Posts
    382
    if (_root.wall.hitTest(_root.man)) {
    gotoAndStop (2);
    }


    think that should be enough
    dunno for sure, tho, try and only ad the "_root." part

  4. #4
    Junior Member
    Join Date
    Apr 2002
    Posts
    14

    thanks

    thanks a lot
    i needed 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