Answers for "mouse right click to game object unity2d"

C#
1

unity2d click on gameobject

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

Code answers related to "mouse right click to game object unity2d"

C# Answers by Framework

Browse Popular Code Answers by Language