Qbasicnews.com

Full Version: collion data
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
how the heck do you do collision dectection and collision data for maps? i get the basic idea of having a set of points for some object and another and checking if they are the same vaules. how would take some BMP map and set collision data to it so object dont go throught it.
this topic has been beaten over and over again, but anyways....

my best suggestion would be to outline all objects that you cannot pass with a colour you won't use anywhere else, and if the tile has that colour in it, you won't be able to go there.

otherwise, you could use a "layer" system, where the visual map layer is your regulay map, The second layer is filled of 0s and 1s : 0s mean nothing, 1s mean "no passing"
this method is more consuming, but it does the job

Oz~