Created
March 10, 2019 13:25
-
-
Save DataGreed/02aeee0c7f6cbb82dbfaf9e43acfb54a to your computer and use it in GitHub Desktop.
Unity: Custom Event handler in script editor panel
This file contains 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.Events; | |
//will be displayed in editor | |
public UnityEvent yourCustomEvent; | |
public void Foo() { | |
// Trigger the event! | |
yourCustomEvent.Invoke(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment