There are two problems in your PG:
- the “Armature” node is named “Armature.001” in the 2nd avatar:
I used “Armature” instead of “Armature.001” when searching for children in the PG below but a better fix would be to correct the naming in the DCC tool. Also, you should passavatarMesh
and notarmatureMesh
tocopy()
otherwise “Armature” will not be found when searching for children (destMesh.parent
does not go high enough in the hierarchy ifdestMesh==armatureMesh
) - the 3rd anim is a morph target animation, not a rigged animation. You should skip it in the
copy()
function.
Here’s a corrected PG: