How to add cloth in HDRP?
I have added all of the cloth components and setup the materials. The cloth works fine in Game preview window, but dissapears in build. Tried a lot of things, including the "update when offscreen" property and dynamic occlusion, changed the bounds as well, nothing seems to change.
Unity version: 2020.2.0b2, tried in 2020.2.0b1
Tried in HDRP 8.1,8.2,9.0 and 10
Does anyone know how to fix it?
Comment
Answer by Bajtix · Sep 20, 2020 at 09:09 AM
Figured it out! I enabled Dev Build and found out the error: CollisionMeshData couldn't be created because the mesh has been marked as non-accessible.
I fixed it by enabling Read/Write on the mesh and setting Generate Colliders to true