I’m having an issue on a multiplayer game I’m trying to make. I have an animation that does not have Root Motion enabled. I created an Anim Montage with a Notify State for collision.
Inside this Notify State, I override NotifyBegin and NotifyEnd, which call Turn On Collision and Turn Off Collision.
Problem:
When the animation is not Root Motion enabled, on every frame of my Anim Montage it keeps toggling: open, close, open, close… This prevents my Event Tick and my collision trace from working properly.
multiple ways to solve it, I remember this happening to me. NotifyStates are evaluated per pose update, so without RootMotion they can enter every frame.
Gate events, do once on TurnOnCollision, wait animation finish : OnBlendingOut OnMontageEnded → TurnOffCollision
You can use retrigrable tick delays but it’s not cool.
I understand that you want to systemize it and the root motion is causing a case where you cannot. Think using just events rather than AnimNotifyState is better. You can always bind your component BPCollision to Owner->SkeletalMesh->AnimInstance->SpecificNotify
So if you go this way, you will start not thinking about it. Example you have AnimNotify_MeleeStart and AnimNotify_MeleeEnd and you bind to these events on your component. Whatever animation you play in AnimBp . your component will always do the same thing accurately on the animation timings. Infact this is crucial since in melee combat timing and poisition of animation is pretty much everything.