Sunday, August 11, 2019

c# - Can 2D Rigidbodies detect collisions with 3D Box colliders?


I would like to know if Rigidbody2D's can detect collisions with 3D Box colliders and/or normal rigidbodies.




I seem to have a problem where my 2D Colliders don't detect collision with my 3D Cubes. :/



Answer



No, the 2D and 3D physics worlds in Unity are treated completely separately, using different internal physics engines (2D is using Box2D, 3D uses a variant of PhysX)


If you need 3D physics, then the simplest way is to handle all of your physics objects as 3D, with appropriate constraints to keep the 2D objects from rotating out of their intended viewing plane.


No comments:

Post a Comment

Simple past, Present perfect Past perfect

Can you tell me which form of the following sentences is the correct one please? Imagine two friends discussing the gym... I was in a good s...