Search Unity

  1. Unity 2019.2 is now released.
    Dismiss Notice

Is there a difference between something on a plane vs something on a cube?

Discussion in 'Physics' started by James15478, Jul 18, 2019.

  1. James15478

    James15478

    Joined:
    Apr 2, 2013
    Posts:
    7
    Say I have a cube, which is a static collider without a rigidbody. And a ball with a rigidbody falls on it, is there a difference to how the physics responds to the collision if the cube was instead a plane?

    I've seen sometimes that if a rigidbody ends up partially in a collider, like if you start the scene and a rigidbody is partially in the floor, the physics system seems to push it slowly upwards, and I'm wondering if the 'floor' being a plane or a cube makes any difference?
    EDIT: Sorry, poor choice of title of thread
    upload_2019-7-18_15-56-38.png
     
  2. xVergilx

    xVergilx

    Joined:
    Dec 22, 2014
    Posts:
    1,875
    Try to avoid planes overall, and replace them with boxes.

    Planes you're using are essentially mesh convex colliders (I assume?).
    And regarding to that, physics calculations may just step over the collider on high velocity objects, so they can clip through planes.

    Also, collisions on the convex mesh colliders are more costly than box collisions. And on non-convex, it even more costly, and even more prone to clipping.

    TL;DR: Use boxes.
     
    James15478 likes this.