Ejemplo n.º 1
0
    IEnumerator setPinkLens()
    {
        Current = Instantiate(Pink);
        StartCoroutine(OverlayC.timerDisplayOn(1f));
        Current.transform.parent = Player.transform;
        lensSet = true;
        StopCoroutine("flicker");
        flickering = false;
        GameControl.control.Freeze();
        thisLight.cookieSize = 6f;
        switch (PlayerC.direction)
        {
        case 0:
            thisLight.cookie = cone0;
            break;

        case 1:
            thisLight.cookie = cone1;
            break;

        case 2:
            thisLight.cookie = cone2;
            break;

        case 3:
            thisLight.cookie = cone3;
            break;
        }
        thisLight.color     = new Color(1f, 0.5f, 1f, 1f); //Fine
        thisLight.intensity = 1f;
        yield return(new WaitForSeconds(1f));

        Destroy(Current);
        thisLight.cookie = normal;
    }