PR fixes three things:
1. It adds support for a VRM to have no spring bones while having spring bone colliders.
@pixiv/three-vrm won't load colliders in springBoneManager if there are no spring bones. However, as we noted in load-utils.js the json of the VRM does have information on colliders and we save them to userData for future use (exporting).
The PR makes use of this information to assign the colliders from the VRM with no spring bones to other VRMs.
Conclusion: This means that colliders from a trait can affect the spring bones of other traits
2. Currently we only export the root bone of spring bones. We also completely ignore groups and assume a single bone forms the entire group of bones. This isn't true and this PR addresses this issue. It will now export groups of bones rather than a single bone.
Below is an example of an output VRM:
https://github.com/user-attachments/assets/2e671314-ba8f-45d4-95a5-73d976d53616
PR fixes three things: 1. It adds support for a VRM to have no spring bones while having spring bone colliders.
@pixiv/three-vrm
won't load colliders inspringBoneManager
if there are no spring bones. However, as we noted inload-utils.js
the json of the VRM does have information on colliders and we save them to userData for future use (exporting). The PR makes use of this information to assign the colliders from the VRM with no spring bones to other VRMs. Conclusion: This means that colliders from a trait can affect the spring bones of other traits2. Currently we only export the root bone of spring bones. We also completely ignore groups and assume a single bone forms the entire group of bones. This isn't true and this PR addresses this issue. It will now export groups of bones rather than a single bone. Below is an example of an output VRM: https://github.com/user-attachments/assets/2e671314-ba8f-45d4-95a5-73d976d53616
3. Add
springBoneManager.update()