Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Unity Generic Event
public class UnityGenericEvent<T0> : UnityEvent<T0> { }
public class UnityGenericEvent<T0, T1> : UnityEvent<T0, T1> { }
public class UnityGenericEvent<T0, T1, T2> : UnityEvent<T0, T1, T2> { }
public class UnityGenericEvent<T0, T1, T2, T3> : UnityEvent<T0, T1, T2, T3> { }
Then all you have to do is create events like:
public UnityGenericEvent<bool> onChange = new UnityGenericEvent<bool>();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.