Printing Collided Object

Hi,

is there a way I can tell the name of an object that collides with my trigger object? Like “‘Ball x’ touched the trigger!” - couldn’t find any documentation on it, but then again, I might have just been looking in all the wrong places :frowning:

Something like -

function OnTriggerEnter (other : Collider) {  
Debug.Log ("Name of Object here" has hit the trigger);

}

Hi again,

function OnTriggerEnter (other : Collider) {  
      Debug.Log (other.gameObject.tag);    
}

or

function OnTriggerEnter (other : Collider) {  
          Debug.Log (other.gameObject.name);    
    }

depending on what you want.