Ejemplo n.º 1
0
    IEnumerator sSacrifice()
    {
        FadeIn();

        yield return(new WaitForSeconds(fadetime / 2));

        Obj.GetComponent <SpriteRenderer>().enabled           = false;
        Obj.GetComponentInChildren <SpriteRenderer>().enabled = false;
        yield return(new WaitForSeconds(fadetime / 2));

        Obj.GetComponent <SpriteRenderer>().enabled           = true;
        Obj.GetComponentInChildren <SpriteRenderer>().enabled = true;

        Sacrifice();
        FadeOut();
    }