For the tank AI, the NPCTankController class will inherit from AdvanceFSM. This is how we set up the states for our NPC tanks:
... private void ConstructFSM() { PatrolState patrol = new PatrolState(waypoints); patrol.AddTransition(Transition.SawPlayer, FSMStateID.Chasing); patrol.AddTransition(Transition.NoHealth, FSMStateID.Dead); ChaseState chase = new ChaseState(waypoints); chase.AddTransition(Transition.LostPlayer, FSMStateID.Patrolling); chase.AddTransition(Transition.ReachPlayer, FSMStateID.Attacking); chase.AddTransition(Transition.NoHealth, FSMStateID.Dead); AttackState attack = new AttackState(waypoints); attack.AddTransition(Transition.LostPlayer, FSMStateID.Patrolling); attack.AddTransition(Transition.SawPlayer, ...