示例#1
0
    public void PreviousStage()
    {
        LevelsManager.LevelsStage stage = LevelsManager.Instance.GetLevelStage(curr_stage - 1);

        if (stage != null)
        {
            state = StageSelectionState.CHANGE_STAGE_FADE_IN;
            change_stage_timer.Start();

            stage_to_change = curr_stage - 1;

            change_state_image.gameObject.SetActive(true);
            change_state_image.DOFade(1, change_stage_time * 0.5f);
        }
    }
示例#2
0
    private void UpdateNextPreviousButtons()
    {
        LevelsManager.LevelsStage next_stage = LevelsManager.Instance.GetLevelStage(curr_stage + 1);

        if (next_stage == null)
        {
            next_stage_button.gameObject.SetActive(false);
        }
        else
        {
            next_stage_button.gameObject.SetActive(true);
        }

        LevelsManager.LevelsStage prev_stage = LevelsManager.Instance.GetLevelStage(curr_stage - 1);

        if (prev_stage == null)
        {
            prev_stage_button.gameObject.SetActive(false);
        }
        else
        {
            prev_stage_button.gameObject.SetActive(true);
        }
    }