From a5e72e1d7421577cb12df3cfb5dbceb3f43260a6 Mon Sep 17 00:00:00 2001 From: L1Z0 <2grif484d@mozmail.com> Date: Mon, 28 Sep 2026 18:18:06 +0200 Subject: [PATCH] fixed locators not being imported --- AnimationDirector.js | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/AnimationDirector.js b/AnimationDirector.js index e9a33c6..99c0aca 100644 --- a/AnimationDirector.js +++ b/AnimationDirector.js @@ -587,6 +587,22 @@ const g = groupByBoneName.get(boneName); g.origin = convertPos(v3(b.pivot, 0)); g.rotation = convertRot(v3(b.rotation, 0)); + + const locators = b?.locators && typeof b.locators === 'object' && !Array.isArray(b.locators) + ? b.locators : {}; + for (const [locatorName, locatorData] of Object.entries(locators)) { + const position = Array.isArray(locatorData) + ? locatorData + : locatorData?.offset || locatorData?.position || locatorData?.from; + if (!Array.isArray(position)) continue; + + const locator = new Locator({ + name: `${prefix}${locatorName}`, + from: convertPos(v3(position, 0)), + }); + locator.init(); + locator.addTo(g); + } } // cubes