Sign in to follow this  
kingpinzs

How to add collitsion detection to a map

Recommended Posts

how do you add colltion detection on a bitmap a certin points so you wont beable to walk through a wall or something. I know this question has been asked before. But I seam not to be able to find the replys alos I looked over the tutorials on gamedev and I could not find one the was exactly related to my problem. I am using one big bitmap and I want it simple to figure out the frame work then work on getting it more percics. And I am doing it in 2d with direct draw for now Thanks for the help [Edited by - kingpinzs on November 11, 2004 6:02:59 PM]

Share this post


Link to post
Share on other sites
Well, i believe you are talking about 2D collision detection, it depends on a lot of factors, like, if you are using a tile based map, or if you want to make an exact collision detection for something.

I think you need to specify your problem a bit

Share this post


Link to post
Share on other sites
does any one have any idea how to do this? While I have been wating for a reply I have been crusing googl to llok for the answer but I can not find any on using a single bitmap as the map and having the image detec collisions with parts of the image.

Share this post


Link to post
Share on other sites
Is it that you have a huge bmp which is your map and you want to make some parts where you can't walk? Or do you have a tilemap and you to make some of the tiles imparsable?

If its in 2D get a piece of paper and you should be able to work out some good old if() statements that will stop you going where you don't want. After that there are quite a few 2D collision detection tutorials out there which I'm sure you could put to good use! Collision detection is one of the hardest things todo in games so don't expect there to be an easy answer - basically there are 98358637 ways todo it and 2876374 different implimentation of each technique so find one you like and stick to it.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this