public bool changeState(Role_State state) { if (_states.ContainsKey(state)) { if (curState.Role_Type() == state) { return(false); } curState = _states[state]; curState.OnEnter(); return(true); } return(false); }
public dead_State(GameObject role) { _role = role; _type = Role_State.dead; }
public move_State(GameObject role) { _role = role; _type = Role_State.move; }
public idle_State(GameObject role) { _role = role; _type = Role_State.idle; }
public Frozen_State(GameObject role) { _role = role; _type = Role_State.Frozen; }
public decelerate_State(GameObject role) { _role = role; _type = Role_State.decelerate; }
public vertigo_State(GameObject role) { _role = role; _type = Role_State.vertigo; }
public Repelling_State(GameObject role) { _role = role; _type = Role_State.Repelling; }
public hit_State(GameObject role) { _role = role; _type = Role_State.hit; }
public attack_State(GameObject role) { _role = role; _type = Role_State.attack; }