Exemple #1
0
    private void OnStartBefore(TRANS_ID transID, STATE_ID stateID, STATE_ID preStateID)
    {
        ReactionProcess(dicIndex[stateID].onStartBefore, dicIndex[stateID].onStartBeforeExcuteId);

        UDL.Log(gameObject.name + " OnStartBefore : " + stateID, nLogOption, isDebug, nLogLevel);
    }
Exemple #2
0
    private void OnPause(STATE_ID stateID)
    {
        ReactionProcess(dicIndex[stateID].onPause, dicIndex[stateID].onPauseExcuteId);

        UDL.Log(gameObject.name + " OnPause : " + stateID, nLogOption, isDebug, nLogLevel);
    }
 void OwnerPause(STATE_ID stateID)
 {
     fPauseTIme = UnityEngine.Time.realtimeSinceStartup;
 }
Exemple #4
0
    private void OnEndAfter(TRANS_ID transID, STATE_ID stateID, STATE_ID preStateID)
    {
        ReactionProcess(dicIndex[preStateID].onEndAfter, dicIndex[preStateID].onEndAfterExcuteId);

        UDL.Log(gameObject.name + " OnEndAfter : " + preStateID, nLogOption, isDebug, nLogLevel);
    }
 public Command(CommandType commandType)
 {
     this.CommandType = commandType;
     StateID          = default;
 }
Exemple #6
0
 public State getState(STATE_ID id)
 {
     return all_states [id];
 }
Exemple #7
0
 public create_room_state(STATE_ID id,StateMachine machine)
     : base(id,machine)
 {
 }
 void OnResume_US_EndState(STATE_ID stateId)
 {
     //[x]_End -> HistoryBack
     FSM_Layer.Inst.SetTrigger(FSM_LAYER_ID.UserStory, TRANS_PARAM_ID.TRIGGER_NEXT);
 }
Exemple #9
0
 public login_state(STATE_ID id,StateMachine machine)
     : base(id,machine)
 {
 }
Exemple #10
0
    void StateTransitionConditionEdit(State state, int rowcount, ref STATE_ID removeId)
    {
        //int transMax = EditorGUILayout.IntSlider("전이 개수 : ",
        //    state.arrTransitionList==null?0:state.arrTransitionList.Length,
        //    0,
        //    state.arrTransitionList==null?10:state.arrTransitionList.Length<10?10:state.arrTransitionList.Length);

        GUILayout.BeginHorizontal("box");

        if (dic_isShowBuffer.ContainsKey(state.eID))
        {
            if (GUILayout.Button(dic_isShowBuffer[state.eID] ? "-" : "+", GUILayout.Width(50)))
            {
                dic_isShowBuffer[state.eID] = !dic_isShowBuffer[state.eID];
            }
        }

        GUILayout.Label(state.eID.ToString() + "(" + ((int)state.eID).ToString() + ")", GUILayout.Width(250));

        if (state.eID != STATE_ID.AnyState)
        {
            if (GUILayout.Button("삭제", GUILayout.Width(40)))
            {
                removeId = state.eID;
            }
        }

        GUILayout.Space(30);

        GUILayout.Label("전이 개수 : ", GUILayout.Width(80));


        int transMax = EditorGUILayout.IntField(
            state.arrTransitionList == null ? 0 : state.arrTransitionList.Length, GUILayout.Width(80));

        if (transMax > 0)
        {
            BK_Function.ResizeArr <TransitionCondition>(transMax, ref state.arrTransitionList);
        }
        else
        {
            state.arrTransitionList = null;
        }

        GUILayout.Space(10);

        if (GUILayout.Button("+", GUILayout.Width(50)))
        {
            BK_Function.ResizeArr <TransitionCondition>(transMax + 1, ref state.arrTransitionList);
        }

        if (GUILayout.Button("-", GUILayout.Width(50)))
        {
            if (transMax > 0)
            {
                BK_Function.ResizeArr <TransitionCondition>(transMax - 1, ref state.arrTransitionList);
            }
        }

        state.NoHistory = GUILayout.Toggle(state.NoHistory, "NoHistory", GUILayout.Width(100));

        GUILayout.Label("", GUILayout.ExpandWidth(true));

        GUILayout.EndHorizontal();

        if (dic_isShowBuffer.ContainsKey(state.eID) && !dic_isShowBuffer[state.eID])
        {
            return;
        }

        if (state.arrTransitionList != null)
        {
            for (int i = 0; i < state.arrTransitionList.Length; i++)
            {
                if (state.arrTransitionList[i] == null)
                {
                    state.arrTransitionList[i] = new TransitionCondition(0, 0, 0);
                }

                int TransCondParam_Max = TransitionConditionEdit(state, i);

                if (TransCondParam_Max == -1)
                {
                    continue;
                }

                TransCondParamEdit(state, i, TransCondParam_Max);

                GUILayout.Box("", GUILayout.ExpandWidth(true), GUILayout.Height(1));

                GUILayout.Space(5);
            }
        }
    }
Exemple #11
0
 public hall_state(STATE_ID id,StateMachine machine)
     : base(id,machine)
 {
 }
Exemple #12
0
 public void SetState(STATE_ID id)
 {
     m_SceneState = id;
 }
Exemple #13
0
 public select_room_state(STATE_ID id,StateMachine machine)
     : base(id,machine)
 {
 }
Exemple #14
0
    private void OnStart(TRANS_ID transID, STATE_ID stateID, STATE_ID preStateID)
    {
        ReactionProcess(dicIndex[stateID].onStart, dicIndex[stateID].onStartExcuteId);

        UDL.Log(gameObject.name + " OnStart : " + stateID + " // after active : " + gameObject.activeSelf, nLogOption, isDebug, nLogLevel);
    }
 public State(STATE_ID id)
 {
     eID = id;
 }
Exemple #16
0
 private void OnStart_USLoading(TRANS_ID transID, STATE_ID stateID, STATE_ID preStateID)
 {
     StartCoroutine(LoadUI());
 }
 public void SetNextStateID(STATE_ID nextID)
 {
     nextStateID = nextID;
 }
 void OnStart_US_EndState(TRANS_ID transId, STATE_ID stateId, STATE_ID preStateId)
 {
     FSM_Layer.Inst.ChangeFSM(FSM_LAYER_ID.UserStory, FSM_ID.USMain);
     //[curState]->USMain_OutroToMainMenu
     FSM_Layer.Inst.SetTrigger(FSM_LAYER_ID.UserStory, TRANS_PARAM_ID.TRIGGER_ESCAPE);
 }
 void OwnerEnd(TRANS_ID transID, STATE_ID stateid, STATE_ID preStateID)
 {
 }
 public Command(CommandType commandType, STATE_ID stateID)
 {
     this.CommandType = commandType;
     this.StateID     = stateID;
 }
Exemple #21
0
 public State(STATE_ID id,StateMachine machine)
 {
     this.id = id;
     this.machine = machine;
     this.machine.addState (this);
 }