My Unity version is 2020.3.2f.
I checked these things below
This animation is non-looping.
This animation have only one event at frame 0 which called twice.
This animation is default animation, and don’t have transition.
When this animation ended, I destroy gameobject which have this animation controller. Destroy event is attached at last frame of this animation.
I tried to delete event right after event called, but event still called twice.
I don’t get user input to play this animation. Just instantiate Prefab which have this animation controller.
This animation have other events too, but only the event at frame 0 called twice. Other events are called once normally.
I searched about this problem, and found this discussion.
Hi everyone, I have been searching all over for answers but have not been successful. I just install the new Unity 4.3 update and add 2 events to one of my animations I called them,
EnableWeaponCollider
DisableWeaponCollider
now in my animator script I call these functions and debug log out when they are called. This is great however, both of these functions are being called twice every time. I don't want to have to do a Boolean check every time to see If it has been called already this is …
This issue was discussed a long time ago, but I can’t know this bug was solved.
There are other things that I can try more? Or this is just bug?
Is the object instantiating twice on accident? Is there some way the animation can be triggered via code and maybe its calling in start when the object instantiates as well as the default anim state? Can you share the code of your script where the object gets instantiated?
The code contains many other actions so it’s bit difficult to share, but I checked the prefab is instantiated once by log. But maybe I can try to change default animation. Thank you.