Exemplo n.º 1
0
    public void DoomPlayers()
    {
        var dooms = System.Enum.GetNames(typeof(DoomType));
        var doom  = (DoomType)Random.Range(0, dooms.Length);

        switch (doom)
        {
        case DoomType.Greyscale:
            cameraProfile.profile = greyscaleProfile;
            break;

        case DoomType.Red:
            cameraProfile.profile = redProfile;
            break;

        case DoomType.Orthographic:
            cameraAnimator.Doom(doom.ToString());
            break;

        case DoomType.TopDown:
            cameraAnimator.Doom(doom.ToString());
            break;

        default:
            break;
        }
        StartCoroutine(UndoomPlayers());
    }