Exemple #1
0
 private void OnClosetSound(SoundTrigger.Type type, float perceivedVolume)
 {
     if (perceivedVolume >= suspicionThreshold)
     {
         Debug.Log("Boyfriend: What was that?");
     }
 }
Exemple #2
0
    private void OnClosetSound(SoundTrigger.Type type, float volume)
    {
        print("I AM TOO LOAUD! " + volume);
        if (volume < noiseThreshold)
        {
            return;
        }

        //do something
        eventOcurred = true;
        if (timesAngry == 0)
        {
            StartCoroutine(GetAngryShort());
            timesAngry++;
            return;
        }

        GetAngry();
    }