Player's state machine