Visual Basic Express 2010 Tutorial 37 Hit Detection - EZInvaders Part 6 Game

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
5,337
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Jan 30, 2011

http://www.schoolfreeware.com
To hit the invader with the shot, the extreme edges of the shot and invader must be found. Once all four edges are found the relative coordinates must be placed in an if statement using Ands.

  • likes, 0 dislikes

Link to this comment:

Share to:

Uploader Comments (SchoolFreeware)

  • I have VB 2010 Pro.

  • @zizeeo VB Pro should be able to open the project from VB Express without complication. I will double check to see if there isn't something wrong with the file. Anyway, the code used should be in your Inbox by now.

  • Sorry to ask for help again but it says "checkhit()" is not declared.

  • @zizeeo No problem. Make a private sub checkhit and add the code. If you need to check your work with what is created in these tutorials, the code is downloadable at the SchoolFreeware website.

  • @SchoolFreeware I downloaded it and it says it cannot be opened.

  • @zizeeo Hello, are you using VB 2010? If not, the project file will not be compatible for any other version. I sent the code via YouTube Personal Message.

see all

All Comments (19)

Sign In or Sign Up now to post a comment!
  • Instead of the Smiley face and Triangle I Did A Vader Mask and X- Wing

    Thumbs Up

  • @Lacihun1 oh okay thanks

  • @cyrusemerson

    But you have to be carefull using invader.right and invader.bottom because the are readonly values.

  • @Lacihun1 Really?

    Thanks gets a bit confusing when using the method the video explained!

  • In fact you don't have to use invader.left+invader.width, you can simply use invader.right or invader.bottom it's the same but more simple.

  • What would you do to make a precise collision code ?? Like if you don't want the invader to die if the bullet only enters any corner of the Picturebox1 but doesn't really touch the drawing. =X

  • Amazing tutorials thank you.

  • how can u be talking like this forever!

    i would hav a sore mouth if i do this

  • Thanks

    

Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more