I have an editor script that clones an object and modifies the mesh of the clone. When I modify the sharedMesh, it changes not only the clone, but also the original. If I modify the mesh, the mesh collider does not change to match it.
How do I take the modified mesh, tell unity to define a new sharedMesh based on the modified mesh, and save it as a new prefab, probably using the AssetDatabase?
Hi, sorry for just pasting code, was a sloppy answer, the best way to do this is to clone the shared mesh, and to assign the clone, back to the sharedmesh property of the skinnedmeshrenderer…