I'm working on a FSM that ticks on every frame. The inner workings can be simplified to this:
Emulate Animator's SetTrigger() behavior on Finite State Machine
- I create the States:
Code (CSharp):- private IdleState idle;
- private ChaseState chase;
- private DeadState dead;
- // And so on...
- I create the Conditions for the upcoming Transitions:
Code (CSharp):- bool targetOutOfSight => onSight == false;
- bool targetOnSight => onSight == true;
- // And so on...
- I creates the...
Emulate Animator's SetTrigger() behavior on Finite State Machine