Search Issue Tracker

By Design

Votes

1

Found in

6000.0.56f1

6000.1.16f1

6000.2.1f1

6000.3.0a5

Issue ID

UUM-114761

Regression

No

Animation event is being fired twice in the same frame

-

Reproduction steps:
1. Open the attached “IN-108590_Repro“ project
2. Open the “Assets/Scenes/Testing.unity“ Scene
3. Open the “Assets/Animation/_Controllers/CharacterController.controller“ Animator Controller in the Animator window
4. Enter the Play Mode
5. Press ‘1' to equip the bow
6. In the Animator’s Parameters tab, check the Attack variable
7. Observe the Console

Expected result: Shoot() is called only once
Actual result: Shoot() is called twice in the same frame

Reproducible with: 6000.0.56f1, 6000.1.16f1, 6000.2.1f1, 6000.3.0a5

Reproducible on: M1 Max MacOS 15.5 (Tested by CQA)
Not reproducible on: No other environment tested

  1. Resolution Note:

    Unfortunately, Animation Events only store the function name as a string to be called afterwards during animation evaluation. You have two functions named "Hit" on your player character: "CharacterAnimation.Hit" and "Combat.Hit". If you look at the call stacks, you'll see that the two calls originate from different sources.

    You should also see warnings of duplicate names in the inspector of the animation event if you select it in the Animation Window.

    To fix this issue. Simply give unique names to your animation event functions in your MonoBehaviours.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.