Hello!
Some might know that i have had this question before, however i wanted to make a Video that in Detail explains my exact Problem since it seems VERY Specific to me.
For Clarification i made a Video:
As you can see in the Video, the Animations are being fired and they play, just not in Playmode. When it comes to code it all seems to work great. But the Animations are just not playing in game mode.
Why is that? Are my Components in the Hierarchy wrong, or am i overseeing something?
If it is needed: This is the Door1 and Door2 script since they have seperate animations.
(They only differ in what Triggers they shoot)
using UnityEngine;
public class Door1 : MonoBehaviour, IInteract
{
Animator animator;
private void Start()
{
animator = GetComponentInParent<Animator>();
}
public void Open()
{ animator.SetTrigger("D1 Open"); }
public void Close()
{ animator.SetTrigger("D1 Close"); }
}
Thank you for your Patience