private void OnTriggerEnter(Collider other) { if (other.tag != "apple") { return; } Apple apple = other.GetComponent <Apple>(); apple.Catch(); }