Example #1
0
    IEnumerator PinsHaveSettled()
    {
        yield return(new WaitForSeconds(secondsToWait));

        StopAllCoroutines();

        ballLeftBox = false;

        pinCounterText.color = Color.green;

        if ((10 - countStanding) != countFallen)
        {
            lastMaxFallen -= countFallen;
            countFallen    = lastMaxFallen - CountStandingPins();
        }
        else
        {
            countFallen = 0;
        }

        Debug.Log("It left " + countStanding + " pins, so there is " + countFallen + " pins falled at this turn.");

        gameManager.Bowl(countFallen);

        pinSetter.pinSetterReadyState = false;

        cameraController.ActivateSwippeCam();
    }