# Issue with Position Syncing after playing animation through Animancer

**URL:** <https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555>\
**Category:** Help\
**Created:** [July 28, 2024, 9:52am UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555 "2024-07-28T09:52:07Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![haruruu](https://avatars.discourse-cdn.com/v4/letter/h/c57346/32.png) [@haruruu](https://community.coherence.io/u/haruruu)\
**Post date:** [July 28, 2024, 9:52am UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555/1 "2024-07-28T09:52:07Z")

</div>

Hello. I’ve been integrating coherence into my single-player RPG, and I’ve run into an issue where entity positions stop syncing right after playing an animation via Animancer. Attached below is a quick clip of the issue.

Has this bug come up before with coherence and animation? I’ve spent a good few hours trying to figure out _why_ it’s happening, but haven’t gotten anywhere.

---

<div class="post-metadata">

**Author:** ![brit](https://dub1.discourse-cdn.com/flex017/user_avatar/community.coherence.io/brit/32/34_2.png) [@brit](https://community.coherence.io/u/brit)\
**Post date:** [July 28, 2024, 11:04am UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555/2 "2024-07-28T11:04:40Z")

</div>

We may need some code snippets to understand what’s going on here. My best guess, though, is that the animation playing on the client is overriding the position of the game object, and so your synced coherence position updates are getting overwritten.

Could you perhaps provide a movie of the client’s component and perhaps some code snippets?

---

<div class="post-metadata">

**Author:** ![ciro](https://dub1.discourse-cdn.com/flex017/user_avatar/community.coherence.io/ciro/32/82_2.png) [@ciro](https://community.coherence.io/u/ciro)\
**Post date:** [July 28, 2024, 2:30pm UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555/3 "2024-07-28T14:30:49Z")

</div>

Yes, it’s probably the case. Are you aware of the concept of Root Motion?  
Some animation clip contain Root Motion data, it means that they want to move the whole object. If there’s only one position key, you might see your character not move anymore after the clip is done.

So either turn off Root Motion on your Animator (my suggestion), or remove Root Motion data from the clip you play.

* * *

Btw, it’s very possible that it’s not coherence that is picking up the wrong position, but you had the issue also before, and you didn’t realise. If the Animation position is applied before your character controller, you might be able to move anyway because your character controller overwrites the animation position given by the Root Motion. Do you move the character in FixedUpdate?

When coherence is added, it just takes the position from the Animator before you override it. So it’s like:

Animator (Root Motion) → coherence sampling → Your script

What I’m saying is that, even if you decide to remove coherence, you should look into this issue because otherwise it might hit you later on, or when you release the game!

---

<div class="post-metadata">

**Author:** ![haruruu](https://avatars.discourse-cdn.com/v4/letter/h/c57346/32.png) [@haruruu](https://community.coherence.io/u/haruruu)\
**Post date:** [July 29, 2024, 12:44am UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555/4 "2024-07-29T00:44:04Z")

</div>

I responded on Discord earlier today, but wanted to thank both of you again. The issue stemmed from a mix of root motion _and_ my own scripts overriding the position of the character.

I fixed those issues earlier today, and everything else I’ve worked on has been smooth sailing!

I’ll be sure to post any other questions / problems I encounter.

---

<div class="post-metadata">

**Author:** ![brit](https://dub1.discourse-cdn.com/flex017/user_avatar/community.coherence.io/brit/32/34_2.png) [@brit](https://community.coherence.io/u/brit)\
**Post date:** [July 29, 2024, 11:02am UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555/5 "2024-07-29T11:02:24Z")

</div>

Great to hear! This is looking fantastic! Keep us updated on your progress

---

<div class="post-metadata">

**Author:** ![ciro](https://dub1.discourse-cdn.com/flex017/user_avatar/community.coherence.io/ciro/32/82_2.png) [@ciro](https://community.coherence.io/u/ciro)\
**Post date:** [July 31, 2024, 7:36am UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555/6 "2024-07-31T07:36:50Z")

</div>

> [@haruruu](#):
>
> I’ll be sure to post any other questions / problems I encounter.

Nice, and thanks for posting the video: the project looks great!!

(which toon shader are you using, by the way? did you make it yourself?)

---

<div class="post-metadata">

**Author:** ![haruruu](https://avatars.discourse-cdn.com/v4/letter/h/c57346/32.png) [@haruruu](https://community.coherence.io/u/haruruu)\
**Post date:** [July 31, 2024, 8:23am UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555/7 "2024-07-31T08:23:36Z")

</div>

Thanks! I’ve been working on this with two friends for a bit over a month now so it’s still a bit raw 😅 but I’ll keep posting updates!

As for the toon shader, I’m using a tweaked RealToon on URP

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex017/uploads/coherence/original/1X/b3aa79eb9519fac7aad7eba18f15a1e8ce60f6e2.png) [@system](https://community.coherence.io/u/system)\
**Post date:** [October 29, 2024, 8:24am UTC](https://community.coherence.io/t/issue-with-position-syncing-after-playing-animation-through-animancer/555/8 "2024-10-29T08:24:32Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
