diff --git a/src/animation/__tests__/snippetPreloader.test.ts b/src/animation/__tests__/snippetPreloader.test.ts index fa56fb2..37ce59f 100644 --- a/src/animation/__tests__/snippetPreloader.test.ts +++ b/src/animation/__tests__/snippetPreloader.test.ts @@ -66,6 +66,17 @@ describe('snippetPreloader', () => { expect(storage.removeItem).not.toHaveBeenCalled(); }); + it('anchors bundled head nod snippets to the inherited live head pose', async () => { + for (const name of ['headNodSmall', 'headNodBig']) { + const resolved = await resolveSnippetEntry('speakingAnimationsList', name); + const curves = resolved?.data.curves as Record> | undefined; + + expect(resolved?.source).toBe('bundled'); + expect(curves?.['54']?.[0]).toMatchObject({ inherit: true }); + expect(curves?.['53']?.[0]).toMatchObject({ inherit: true }); + } + }); + it('ignores legacy preloaded bundle entries when reading custom snippet names', () => { const storage = createStorageMock({ bundledAnimationSnippetsManifest: JSON.stringify({ diff --git a/src/animation/snippets/speaking/headNodBig.json b/src/animation/snippets/speaking/headNodBig.json index 344806a..5ec00d9 100644 --- a/src/animation/snippets/speaking/headNodBig.json +++ b/src/animation/snippets/speaking/headNodBig.json @@ -3,7 +3,8 @@ "54": [ { "time": 0.0, - "intensity": 0.0 + "intensity": 0.0, + "inherit": true }, { "time": 0.4, @@ -17,7 +18,8 @@ "53": [ { "time": 0.8, - "intensity": 0.0 + "intensity": 0.0, + "inherit": true }, { "time": 1.4, diff --git a/src/animation/snippets/speaking/headNodSmall.json b/src/animation/snippets/speaking/headNodSmall.json index 9fc8925..d8e758b 100644 --- a/src/animation/snippets/speaking/headNodSmall.json +++ b/src/animation/snippets/speaking/headNodSmall.json @@ -3,7 +3,8 @@ "54": [ { "time": 0.0, - "intensity": 0.0 + "intensity": 0.0, + "inherit": true }, { "time": 0.15, @@ -17,7 +18,8 @@ "53": [ { "time": 0.3, - "intensity": 0.0 + "intensity": 0.0, + "inherit": true }, { "time": 0.45,