When you reset a mesh in edit mode in Spine, it removes all the vertices and replaces them with four new vertices at the corners of the image. This action also removes any weights and deform keys associated with the mesh. The reset operation aligns the vertices with the UVs (texture coordinates), which can result in the mesh shifting position and potentially rotating. This is because the new vertices are created without any knowledge of the previous mesh's orientation or deformation.
Here are the key points to understand why the mesh shifts position and rotates:
Vertex Reset: Resetting the mesh in edit mode clears all existing vertices and creates new ones at the image corners. This does not take into account the previous positions or orientations of the vertices.
UV Alignment: The new vertices are aligned with the UVs, which can cause the mesh to appear rotated or translated if the original mesh was deformed or had a different vertex arrangement.
Weight and Deform Key Removal: Resetting also removes all weights and deform keys, which can further alter the appearance of the mesh if it was previously influenced by bones or animations.
Deformed Mode: If you want to edit the mesh while preserving its deformation, you should enable the "Deformed" checkbox in edit mode. This allows you to see and adjust the mesh as it appears outside of edit mode, maintaining the relationship between the vertices and the texture.
For more detailed information, you can refer to the Spine User Guide on Mesh Attachments.
In summary, the reset operation is designed to start over with a clean slate, which inherently means losing the previous configuration and potentially causing shifts in position and rotation. To avoid this, consider using the "Deformed" mode when editing the mesh or manually adjusting the vertices without resetting.