示例#1
0
    public IEnumerator EndPhase()
    {
        GameManager.Player.GetComponent <PlayerController>().hasControl = false;
        for (int i = 0; i < 50; i++)
        {
            colorGrading.brightness.value -= 1f;
            yield return(new WaitForSeconds(.1f));
        }
        yield return(new WaitForSeconds(2f));

        OnPhaseEnd.Invoke();
    }
示例#2
0
    private IEnumerator _EndPhase()
    {
        lastPhase    = currentPhase;
        currentPhase = Phase.None;

        yield return(new WaitForSeconds(1));

        OnPhaseEnd?.Invoke();

        NextPhase();

        Debug.Log(currentPhase + " phase");

        OnPhaseStart?.Invoke();
    }