FSM for general action is developed more and some bugs are removed