FSM in Pac-Man