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
using UnityEngine; | |
public class ExampleNonUIMonoBehaviour : MonoBehaviour | |
{ | |
private void Start() | |
{ | |
//Example of how to check for a position. This is the equivalent of EventSystem.current.IsPointerOverGameObject() except for UI Elements. | |
if (UIToolkitRaycastChecker.IsPointerOverUI()) | |
{ | |
//I'm under a part of the UI that's set to block raycasts! Don't try to raycast or something. |
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
public class DemoAirHorn : MonoBehaviour, IThingBehaviour | |
{ | |
public void DoAThing() | |
{ | |
Debug.Log("EEEEEEEEEEEEEEEEEEEEEEEEERRRRRRRRRRRRRRRRRRRRRRRRRRRRRRR"); | |
} | |
public int ReturnAThing(int number) | |
{ | |
return number + 1; |