public static void RemoveExitListener(this GameObject go, UnityAction <GameObject> callback) { EventObject eventObject = go.transform.GetComponent <EventObject>(); eventObject?.AddExitListener(callback); }
public static void RemoveClickListener(this GameObject go, UnityAction callback) { EventObject eventObject = go.transform.GetComponent <EventObject>(); eventObject.RemoveClickListener(callback); }