|
-
Nov 12th, 1999, 07:13 AM
#1
Thread Starter
Lively Member
I'm making a 2D game in vb, and I need rectangular collision detection.
Or, what I need is to make sure my character can't step on certain areas of the form, to be less complex sounding.
If anyone can give me one way to do this, I will be forever grateful.
Thanks in advance!
------------------
"I'm carrying a Geometry book, but I'm not in Geometry...it's crazy...crazy man!"
-
Nov 12th, 1999, 08:09 AM
#2
Frenzied Member
I use this: If Abs(Image1.Left - Image2.Left) < Image1.Width And Abs(Image1.Top - Image2.Top) < Image1.Height Then ...and put whatever you want after Then. Hope it helps
Steve
-
Nov 12th, 1999, 11:07 AM
#3
New Member
You can check to see if two bitmaps intersect using the IntersectRect API call.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|