airfirier, car goof
This commit is contained in:
19
Assets/Scripts/Animation/AnimationEventWrapper.cs
Normal file
19
Assets/Scripts/Animation/AnimationEventWrapper.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using Core.SaveLoad;
|
||||
using UnityEngine;
|
||||
|
||||
public class AnimationEventWrapper : MonoBehaviour
|
||||
{
|
||||
public AppleMachine stateMachine;
|
||||
|
||||
public void ChangeState(string stateName)
|
||||
{
|
||||
if (stateMachine == null)
|
||||
{
|
||||
Debug.Log($"Error: No statemachine found on Animation Event Wrapper {name}");
|
||||
}
|
||||
if (stateMachine != null)
|
||||
{
|
||||
stateMachine.ChangeState(stateName);
|
||||
}
|
||||
}
|
||||
}
|
||||
2
Assets/Scripts/Animation/AnimationEventWrapper.cs.meta
Normal file
2
Assets/Scripts/Animation/AnimationEventWrapper.cs.meta
Normal file
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f8e15a40af555ec459e94d7c4c5ac1b7
|
||||
Reference in New Issue
Block a user