Esempio n. 1
0
    public void SwitchPhase(int phase)
    {
        ReleaseFocus();

        phaseArr[currentPhase - 1].SetActive(false);
        phaseArr[phase - 1].SetActive(true);

        //GameObject.Find("Phase"+currentPhase).SetActive(false);
        //GameObject.Find("Phase"+phase).SetActive(true);
        currentPhase = phase;

        holds.SwitchPhase(phase);
    }
Esempio n. 2
0
    public void SwitchPhase(int phase)
    {
        ReleaseFocus();

/*
 *              for(int i = 0 ; i < phaseArr.Length ; i++){
 *                      if (i == phase-1){
 *                              phaseArr[i].SetActive(true);
 *                      }else{
 *                              phaseArr[i].SetActive(false);
 *                      }
 *              }*/

        if (phase == (int)Observer.Phase.HOLD_EDIT)
        {
            phaseArr[(int)Observer.Phase.HOLD_EDIT].SetActive(true);
            phase1.SwitchSubMenu((int)Phase1.TYPE.DEFAULT);
        }
        else
        {
            phaseArr[(int)Observer.Phase.HOLD_EDIT].SetActive(false);
        }

        if (phase == (int)Observer.Phase.SCENE_EDIT)
        {
            phaseArr[(int)Observer.Phase.SCENE_EDIT].SetActive(true);
            threeDModel.ChangeMode((int)ThreeDModel.Mode.WINDOW);
        }
        else
        {
            phaseArr[(int)Observer.Phase.SCENE_EDIT].SetActive(false);
            threeDModel.ChangeMode((int)ThreeDModel.Mode.DEFAULT);
        }
        //GameObject.Find("Phase"+currentPhase).SetActive(false);
        //GameObject.Find("Phase"+phase).SetActive(true);
        currentPhase = phase;

        holds.SwitchPhase(phase);
    }