You're right, there are multiple problems with how Spine handles invalid meshes.
We should not reset the mesh weights except if the mesh has no bones at all. We've fixed this in 4.3.39-beta! This fixes the problem where you open a project, it says it reset a mesh, and your work is gone without giving you a chance to fix the mesh.
In 4.3.39-beta we now detect duplicate vertices and automatically remove one. This allows you to open your m.zip
project and the mesh is fixed automatically. A warning is shown to let you know it changed the mesh, which may help if you need to fix the mesh for older versions.
Your other project is harder to fix automatically:


This selected internal vertex has 2 orange edges and it's slightly on the outside of the hull. This makes the orange edges invalid, as edges cannot cross the hull or any other edges. To fix it we could move the vertex, but it's very difficult to determine how to move the vertex in a way that fixes any similar problem AND doesn't cause any new problems.
We could delete the orange edges. That would all triangles to be computed, but the vertex would still be outside the hull. When that happens, the vertex does not affect the mesh image, so the behavior of your mesh would not be the same. You'd have a useless vertex hanging around.
Since there isn't a great way to fix it, probably it's best if we only warn about it. You'll see Mesh cannot be triangulated
and can fix it manually.
We added --debug-triangulation
which logs when triangulation fails. This can happen normally, for example as you drag a vertex to an invalid position. However, it doesn't normally happen when a project loads. This debug logging is probably not useful most of the time, but there may be some case where it helps identify meshes with bad vertices. Until the next launcher update, you'll need --ignore-unknown-args
so the launcher doesn't complain about --debug-triangulation
being invalid.
We have also had for some time --mesh-debug
. You can use it 1, 2, or 3 times for more info.
For example with --ignore-unknown-args --debug-triangulation --mesh-debug
you might see:
WARNING: Triangulation failed: Internal edge is outside of hull: 16, 62
WARNING: Mesh cannot be triangulated: [mesh: palm(L)_lv1, skeleton: skeleton, slot: palm(L)_lv1]
You would always see Mesh cannot be triangulated
but now you also see the triangulation warning. The numbers correspond to the 2 vertices that make up the edge that is invalid. Since you have --mesh-debug
you can see those vertex numbers:

16 and 62 are at the bottom, so you know where you need to move the vertices to fix it. If there are multiple problems, check the log again to see the next problem.
Fixing up vertices manually is not fun. Sorry for the trouble! I wish we could fix them all automatically, but it's a tricky problem. On the bright side, once your projects are fixed and moved to 4.3, you should never have triangulation problems again.