示例#1
0
 private void OnTriggerEnter(Collider other)
 {
     if (other.GetComponent <Beast>())
     {
         _detectedBeast = other.GetComponent <Beast>();
     }
 }
示例#2
0
        private IEnumerator ClearDetectedBeastAfterDelay()
        {
            yield return(new WaitForSeconds(3f));

            _detectedBeast = null;
        }