protected void Initialize() { StateBathroom = GetComponentInChildren(typeof(BathroomState)) as BathroomState; StateKitchen = GetComponentInChildren(typeof(KitchenState)) as KitchenState; StateBedroom = GetComponentInChildren(typeof(BedroomState)) as BedroomState; StateCloset = GetComponentInChildren(typeof(ClosetState)) as ClosetState; FSM = new FiniteStateMachine<MovingVoice>(this); }
protected void Initialize() { StateBathroom = GetComponentInChildren(typeof(BathroomState)) as BathroomState; StateKitchen = GetComponentInChildren(typeof(KitchenState)) as KitchenState; StateBedroom = GetComponentInChildren(typeof(BedroomState)) as BedroomState; StateCloset = GetComponentInChildren(typeof(ClosetState)) as ClosetState; FSM = new FiniteStateMachine <MovingVoice>(this); }