Answers for "clickable 2d object unity"

C#
3

unity click on 2d object

// Requires for the object to have a collider and this script attached
private void OnMouseDown()
{
	Debug.Log("Clicked on object!");
}
Posted by: Guest on October-08-2021

C# Answers by Framework

Browse Popular Code Answers by Language