fix(spatial): handle case of NaN rotation from 0 scale matrix

This commit is contained in:
Nova
2022-09-10 08:54:01 -04:00
parent 0a4a448ac9
commit 5323479670

View File

@@ -82,6 +82,8 @@ impl Spatial {
}
if let Some(rot) = rot {
reference_space_rot = rot
} else if reference_space_rot.is_nan() {
reference_space_rot = Quat::IDENTITY;
}
if let Some(scl) = scl {
reference_space_scl = scl