2 Replies Latest reply on May 26, 2006 5:02 AM by scotan

    hittest

    scotan
      hey i really need help with this hittest thing. i need a code sniplet of hittest. first i was doing a game tutorial and i got stumped at this part ,it didnt work , so i researched and still cant get a bullet to hit anything, i tried a simple line tween into a MC "circle" and used a box moving if it hit. my code wouldnt be much help. i can create a bullet, and a target. and a movie to show the hit. let say my instance names are bullet, target and display on display i used a stop in frame one so movie wouldnt play automatically, then referenced frame to in my condition, any help is appreicated. i will do more reasearch if you have a handy reference for me? thanx a mill
        • 1. Re: hittest
          scotan Level 1
          this is the code from the game tutorial, its not the same as the video , its what i tried to do when theirs wouldn't work

          if (bullet.hittest(_root.bomb_godown))
          with(_root.domb_godown.bomb){
          gotoandPlay(15);
          }

          bullet = my moving line "bullet" it has instance name
          bomb_godown = my target im trying to hit
          bomb = a MC inside of bomb_godown
          15 = explosion.
          i dont get errors but it does notheing when i hit the bomb_godown MC
          thanX
          • 2. Re: hittest
            scotan Level 1
            http://home.tampabay.rr.com/comptech/


            this is the game so far i know there are two bullets that shoot. that is an error from me trying to fix my hit test and is not the problem i am gonna fix that easilly hope this helps. ive tried to nderstand this hittest thing but im just now learning action script sooooooooo!!!! grrr lol
            thanX