Created
December 15, 2014 15:05
-
-
Save eelstork/96526237babe6bf5fa6c to your computer and use it in GitHub Desktop.
Demonstrates how to write custom event handler for the event system in Unity 4.6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function OnPointerClick(event:UnityEngine.EventSystems.PointerEventData){ | |
Debug.Log("pointer clicked: "+gameObject); | |
Debug.Log("Position: "+event.worldPosition); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment