isChasing, isAttacking, isStunned, and then I spent an hour figuring out why an enemy is somehow doing all three at once! I figured out a much more efficient way of making enemies behave the way I wanted to later on. The discovery of FSM, or Finite State Machines! In this article, I'll go over what it is and the best way to implement it. And of course, the when, where, and how.Let's untangle this one!


