Esempio n. 1
0
    public void SetPowers(Powers powers)
    {
        StopAllCoroutines();
        SetNormalState();
        switch (powers.Index())
        {
        case 0:
            StartCoroutine(SetLargerBall());
            break;

        case 1:
            StartCoroutine(SetSmallerAndSemiTransparentBall());
            break;

        case 2:
            StartCoroutine(SetLargerPaddle());
            break;

        case 3:
            StartCoroutine(SetSmallerPaddle());
            break;

        default:
            Debug.LogError("Invalid powers");
            break;
        }
        StartCoroutine(SetLargerBall());
    }