Newer
Older
TheVengeance-Project-IADE-Unity2D / Assets / Scripts / NPC / NPCConroller.cs
@Rackday Rackday on 26 Aug 552 bytes Major Update
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using MyCollections.AI.FinitStateMachine;

public class NPCConroller : MonoBehaviour
{
    [SerializeField] private FSM fsm;
    private Agent agent;

    public Agent Agent => agent;

    private void Awake()
    {
        agent = GetComponent<Agent>();
    }
    // Start is called before the first frame update
    void Start()
    {
        fsm = new FSM(this);
    }

    // Update is called once per frame
    void Update()
    {
        fsm.GUpdate();      
    }
}