Exemplo n.º 1
0
    public void StopAct(string reason)
    {
        if (actInProgress)
        {
            main.StopAllAudio();
            actInProgress = false;
            if (reason == "gonged")
            {
                GetComponent<Image>().color = main.gongedColor;
                actStatus = actStatusType.gonged;
            }

            else
            {
                GetComponent<Image>().color = main.goodColor;
                actStatus = actStatusType.finished;
                localTimerText.text = "Score!";
                GetScore();
            }
        }
    }
Exemplo n.º 2
0
    // Update is called once per frame
    void Update()
    {
        if (actInProgress)
        {
            localTimerText.text = main.timer.ToString("###.#");
        }

        if (keyboard != null && keyboard.done && actStatus == actStatusType.finished)
        {
            localTimerText.text = keyboard.text;
            actStatus = actStatusType.scored;
        }
    }