Finite state machines are more of an advanced thing to do in HaxeFlixel or in game development full stop. It is a way of inherently restricting your game object to prevent unnecessary errors. This is the first and most important step for your state machine, figuring out how it will work.