Added animations, two state machines
This commit is contained in:
26
Assets/Scripts/Animation/GardenerChaseBehavior.cs
Normal file
26
Assets/Scripts/Animation/GardenerChaseBehavior.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using UnityEngine;
|
||||
using Pixelplacement;
|
||||
|
||||
public class GardenerChaseBehavior : MonoBehaviour
|
||||
{
|
||||
public Spline ChaseSpline;
|
||||
public Transform GardenerObject;
|
||||
public float chaseDuration;
|
||||
public float chaseDelay;
|
||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||
void Start()
|
||||
{
|
||||
Tween.Spline (ChaseSpline, GardenerObject, 0, 1, false, chaseDuration, chaseDelay, Tween.EaseInOut, Tween.LoopType.PingPong);
|
||||
}
|
||||
|
||||
void Awake()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user