“OnTRiggerenter2d” Code-Antworten

OnTRiggerenter2d

 void OnTriggerEnter2D (Collider2D other) //Make sure to put this out of Voids
     {
         if (other.gameObject.tag == "Object") 
         {
             Debug.Log ("Collided");
         }
Am coder

OnTRiggerenter2d

void OnTriggerEnter2D(Collider2D col)
{
	Debug.Log(gameObject.name + " Collided");
}

Durchsuchen Sie beliebte Code-Antworten nach Sprache

Durchsuchen Sie andere Codesprachen