📓

DieAtEndOfUnityAnimation

public class DieAtEndOfUnityAnimation : MonoBehaviour
{
    void Start()
    {
        Destroy(gameObject, this.GetComponent<Animator>().GetCurrentAnimatorStateInfo(0).length);
    }

}

Attach this to a Unity GameObject with animation on it. When the animation ends the GameObject is destroyed. I do not recommend using this script on Network Entities