예제 #1
0
    public void Speak(string id, float remain = 3f)
    {
        int randomFace = Random.Range(0, 3);

        ChangeFace((unitychanFace)randomFace, 2f);


        StringPiece temp = StringManager.instance.getStringByID(id);

        balloon.Call(temp.korean, remain, 0.3f, 0.3f);
        if (temp.voice == null)
        {
            Debug.LogError("로딩되지 않은 목소리파일 사용 : " + temp.voiceFile);
        }
        else
        {
            sound.clip = temp.voice;
        }
        sound.Play();
    }