Beispiel #1
0
    // Update is called once per frame
    void Update()
    {
        int time = (int)startTime;

        timerTexter.text = time.ToString();

        if (startTime > 0)
        {
            if (gamePaused == false && gameHasFinished == false)
            {
                startTime -= Time.deltaTime;
            }
        }

        if (gameHasFinished == true)
        {
            playerOneScript.enabled = false;
            playerTwoScript.enabled = false;
        }


        if (startTime <= 0)
        {
            playerPoints.determineAfterTime();
        }
    }