Search Unity

Question BoxCollider2D doesn't works some times

Discussion in '2D' started by pleasurehouse, Apr 5, 2021.

  1. pleasurehouse

    pleasurehouse

    Joined:
    Oct 15, 2020
    Posts:
    96
    I have this problem. My Boxcollider2D goes through my CompositeCollider2D.

    At first this happened very often (with the default settings).

    Then I changed the configuration of the CompositeCollider2D
    Geometry Type --> Polygons
    Generatión Type --> Synchronous


    Then I changed the setting of my character's BoxCollider2D
    Auto Tiling -> checked

    Then I changed the configuration of my character's RigidBody2D
    Simulated -> checked
    Body type -> Dynamic
    Collision Detection -> continuous
    Sleeping mode -> Start Awake
    Interpolate-> none

    I am using (Interpolate-> none) because I have read that the (interpolate and extrapolate) options should only be used for the player.

    This configuration helped me a lot to solve the problem. But it still happens sometimes (see video).

    I have realized that this only happens in the corners and that it is important to have the tilemap correctly drawn. However the problem does not disappear completely.



    What can i do?
    Thank you so much!!