From a8b785478f6a07cb0147f5c25379890b3635bbc5 Mon Sep 17 00:00:00 2001 From: Lukas Cone Date: Sun, 21 Apr 2024 12:23:09 +0200 Subject: [PATCH] lmt fixes --- src/mtf_lmt/bone_track.cpp | 8 +++++--- toolset/lmt_to_gltf/lmt_to_gltf.cpp | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/mtf_lmt/bone_track.cpp b/src/mtf_lmt/bone_track.cpp index eccf330..b46c5bf 100644 --- a/src/mtf_lmt/bone_track.cpp +++ b/src/mtf_lmt/bone_track.cpp @@ -273,9 +273,11 @@ void ProcessClass(LMTTrackMidInterface &item, LMTConstructorProperties flags) { } } - FByteswapper(*reinterpret_cast( - item.interface.data + - item.interface.m(clgen::BoneTrack::compression))); + if (flags.swapEndian) { + FByteswapper(*reinterpret_cast( + item.interface.data + + item.interface.m(clgen::BoneTrack::compression))); + } } } diff --git a/toolset/lmt_to_gltf/lmt_to_gltf.cpp b/toolset/lmt_to_gltf/lmt_to_gltf.cpp index 65e4b28..b55a143 100644 --- a/toolset/lmt_to_gltf/lmt_to_gltf.cpp +++ b/toolset/lmt_to_gltf/lmt_to_gltf.cpp @@ -758,7 +758,7 @@ void DoLmt(LMTGLTF &main, uni::MotionsConst motion, std::string name, for (auto k : times) { Vector4A16 value; t->GetValue(value, k); - //value *= SCALE; + value *= SCALE; aNode.positions.emplace_back(value); } break;