Skip to main content

Timeline for Using 2d collision with 3d objects

Current License: CC BY-SA 3.0

5 events
when toggle format what by license comment
Jul 2, 2012 at 16:48 vote accept Lyise
Jul 2, 2012 at 16:48 comment added Lyise Thanks for the information and the link, I think I'll go for the polygon hitbox approach where the Z axis is ignored in collision detection as you suggest.
Jul 2, 2012 at 16:39 comment added Tom Johnson Well, then, you can give that enemy a polygon hitbox - that's the sort of thing I'm talking about. Circle-circle, circle-poly and poly-poly are all straightforward to implement, define, and manipulate (for example, if you want your ship to bank as you move left or right, you might implement that hitbox-wise by simply scaling it down along the X-axis). metanetsoftware.com/technique/tutorialA.html is a good tutorial for collision algorithms using these shapes.
Jul 2, 2012 at 16:09 comment added Lyise Thanks for the comment. With regards to having the smaller hitbox, I did think about this, but it would not work with what I am aiming for. I've added some extra information about this to my original question, sorry about the confusion. With regards to the circle-poly collision, this may cover what I need, but I am concerned that it would not meet the precision I would like, for example, if one enemy type is tall and thin, I would like a bullet to miss them by flying parallel to the enemy, which a circle hitbox would give a false positive to (potentially)
Jul 2, 2012 at 13:01 history answered Tom Johnson CC BY-SA 3.0