diff options
| author | Léo Lam <leo@leolam.fr> | 2021-08-01 22:39:19 +0200 |
|---|---|---|
| committer | MonsterDruide1 <5958456@gmail.com> | 2021-08-02 01:11:24 +0200 |
| commit | c64fb93fbdc370ce2a40c4bc7a76e99443542647 (patch) | |
| tree | 1e360b266d320bc91d63cf0c0d14d94bf61420f0 /src/KingSystem/Physics/SupportBone/physSupportBoneResource.cpp | |
| parent | 90c34d80feabe1849a7e668edfd705eee8b33444 (diff) | |
ksys/phys: Fix matching issues in SupportBone
Diffstat (limited to 'src/KingSystem/Physics/SupportBone/physSupportBoneResource.cpp')
| -rw-r--r-- | src/KingSystem/Physics/SupportBone/physSupportBoneResource.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/KingSystem/Physics/SupportBone/physSupportBoneResource.cpp b/src/KingSystem/Physics/SupportBone/physSupportBoneResource.cpp index 3b885129..a33031e0 100644 --- a/src/KingSystem/Physics/SupportBone/physSupportBoneResource.cpp +++ b/src/KingSystem/Physics/SupportBone/physSupportBoneResource.cpp @@ -233,22 +233,22 @@ float SupportBoneResource::getInterpolatedConnectionCurve(u32 index, float looku return std::isnan(result) ? 0.0f : result; } -// NON_MATCHING: Due to seadQuat::normalize() mismatch, this function does not match. void SupportBoneResource::BaseBone::postRead_() { sead::Vector3f aim_local = aim.ref(); sead::Vector3f up_local = up.ref(); aim_local.normalize(); side = sead::cross(aim_local, up_local); - side.normalize(); + // XXX: this looks like a hack. Why does this not match without an inline function? + [&] { side.normalize(); }(); up_local = sead::cross(side, aim_local); up_local.normalize(); - aim = aim_local; up = up_local; + aim = aim_local; base_rotate->normalize(); - reverse_rotate = base_rotate->inverse(); + base_rotate->invert(&reverse_rotate); } -} // namespace ksys::phys
\ No newline at end of file +} // namespace ksys::phys |
