Fix get_bone_pose_global_no_override()

(cherry picked from commit 565803ce3d)
This commit is contained in:
Lyuma 2023-05-18 03:14:45 -07:00 committed by Yuri Sizov
parent 4cf3aff7cc
commit 9307d851a9
1 changed files with 4 additions and 4 deletions

View File

@ -925,18 +925,18 @@ void Skeleton3D::force_update_bone_children_transforms(int p_bone_idx) {
if (b.parent >= 0) {
b.pose_global = bonesptr[b.parent].pose_global * pose;
b.pose_global_no_override = b.pose_global;
b.pose_global_no_override = bonesptr[b.parent].pose_global_no_override * pose;
} else {
b.pose_global = pose;
b.pose_global_no_override = b.pose_global;
b.pose_global_no_override = pose;
}
} else {
if (b.parent >= 0) {
b.pose_global = bonesptr[b.parent].pose_global * b.rest;
b.pose_global_no_override = b.pose_global;
b.pose_global_no_override = bonesptr[b.parent].pose_global_no_override * b.rest;
} else {
b.pose_global = b.rest;
b.pose_global_no_override = b.pose_global;
b.pose_global_no_override = b.rest;
}
}
if (rest_dirty) {