Beispiel #1
0
    public void PushButtonHako()
    {
        if (keyFlg && !hakoFlg)
        {
            buttonHammerGet.SetActive(true);
            hammer.SetActive(true);
            talk_.DisplayMessage("カチャ");
            hammerFlg = true;
            hakoFlg   = true;
            kuma.SetActive(false);
            buttonCrater.SetActive(true);

            audioSource = GetComponent <AudioSource>();
            audioSource.PlayOneShot(sound);
        }
        if (!hakoFlg)
        {
            talk_.DisplayMessage("カギがかかっている。");
            audioSource = GetComponent <AudioSource>();
            audioSource.PlayOneShot(sound2);
        }

        if (hakoFlg)
        {
            return;
        }
    }