#27962 - Celeryface - Mon Oct 25, 2004 10:36 am
Are there any tutorials on how to do collision detection between sprites and map data? I'm new to this technique, so both theory and code would be awesome!
Also, what's the best map editor to use for platform type games?
Thanks :)
#27965 - tepples - Mon Oct 25, 2004 3:12 pm
Collision in a nutshell: Try testing the four corners of the sprite against a 2D array representing a shrunken version of the map data, which stores one set of codes for solid and one for not.
For a scrolling game, you may want to create your own map editor to correspond to the characteristics of your engine.
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.
#27968 - Celeryface - Mon Oct 25, 2004 4:20 pm
tepples wrote: |
Collision in a nutshell: Try testing the four corners of the sprite against a 2D array representing a shrunken version of the map data, which stores one set of codes for solid and one for not.
For a scrolling game, you may want to create your own map editor to correspond to the characteristics of your engine. |
Are there any map editors that already output collision data?
#27989 - sgeos - Mon Oct 25, 2004 8:06 pm
MapED can create collision layers. Any editor that can output layered maps can be made to output a collison layer.
-Brendan