Search Unity

Colliders not working in build since last update

Discussion in 'Physics' started by Asalfin, Feb 14, 2020.

  1. Asalfin

    Asalfin

    Joined:
    Mar 21, 2019
    Posts:
    9
    Hi,
    Since I updated to the last version of Unity (2019.3.0f6), the colliders are not working in my builds, but they are in the editor. Anyone knows a fix to that problem ?

    Thank you !
     
  2. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    2,461
    What problem? You don't provide any information such as whether it's 2D or 3D, what target platform, what colliders, what it means when you say "it's not working".

    Asking why X is not working is impossible to answer.

    Please spend the time providing details on what you're doing, what the expectations are and an image or video if it's appropriate.
     
  3. Asalfin

    Asalfin

    Joined:
    Mar 21, 2019
    Posts:
    9
    Hi, thanks for your answer !

    It's a 3D Project on PC, I'm using HDRP with Unity 2019.3.0f6.

    I'll give you an example : if I add a cube with a rigidbody in the editor, it falls and collides with the colliders it meets in the editor, but in the build I create from the project, the cube just ignores all colliders and falls through everything.
    I also tried with raycasts but the rays also ignore the colliders.

    Is there any other information I should provide ?
     
  4. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    2,461
    You're basically saying a cube falling onto (another cube?) with none of your own scripts added donig anything funky doesn't work in a desktop build on Windows?

    I'm not a 3D physics dev but honestly, I have no idea why that would be the case or what to try. :(

    One thing I will say is that you're mixing some rendering terms with physics. I presume your Rigidbody has a BoxCollider and whatever you're landing on has a 3D collider too. Try using a BoxCollider to land on.

    Maybe post and image or video.
     
  5. Asalfin

    Asalfin

    Joined:
    Mar 21, 2019
    Posts:
    9
    Here is a video in the editor :


    And this one is from a build :


    By the way, I just tried again using box colliders, and it seems to be working now (I don't know why it wasn't working yesterday).

    The rigidbody does have a boxcollider, and the ground has a mesh collider.

    Also, sorry for taking so much time to answer, it took an hour for my computer to make the builds and record !

    Thanks again !
     
  6. Asalfin

    Asalfin

    Joined:
    Mar 21, 2019
    Posts:
    9
    I just tried resetting the mesh collider of the ground and it seems to be working ! Then I tried with other objects and it works as well but only after reseting their respective collider... Also some colliders are working and some are not.

    Do you know anyway to reset all the colliders of the project at once ? I think that would fix my problem !
     
  7. Asalfin

    Asalfin

    Joined:
    Mar 21, 2019
    Posts:
    9
    I'll try to reinstall the last update, I got some other bugs from it so it probably went wrong.
     
  8. Asalfin

    Asalfin

    Joined:
    Mar 21, 2019
    Posts:
    9
    I just reinstalled the last update and it's still not working :(!
     
  9. Asalfin

    Asalfin

    Joined:
    Mar 21, 2019
    Posts:
    9
    I just selected all mesh colliders in the scene (by searching "meshcollider") and resetted all of them, it's now working !
    I really don't know what happend tho.

    Thank you very much for your help :)!
     
  10. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    2,461
    Resetting them just resets the options you can see so it's related to those so the mesh, cooking options or convex option.
     
unityunity