public void OnCancel(BaseEventData eventData)
 {
     EventBus.Trigger(EventHooks.OnCancel, gameObject, eventData);
 }
 public void OnMove(AxisEventData eventData)
 {
     EventBus.Trigger(EventHooks.OnMove, gameObject, eventData);
 }
 private void Start()
 {
     GetComponent <Button>()?.onClick
     ?.AddListener(() => EventBus.Trigger(EventHooks.OnButtonClick, gameObject));
 }
 public void OnSubmit(BaseEventData eventData)
 {
     EventBus.Trigger(EventHooks.OnSubmit, gameObject, eventData);
 }
Exemple #5
0
 protected virtual void TriggerRegisteredEvent <TArgs>(EventHook hook, TArgs args)
 {
     EventBus.Trigger(hook, args);
 }
 private void Start()
 {
     GetComponent <Slider>()?.onValueChanged?.AddListener((value) =>
                                                          EventBus.Trigger(EventHooks.OnSliderValueChanged, gameObject, value));
 }
 private void OnGUI()
 {
     EventBus.Trigger(EventHooks.OnGUI);
 }
 private void OnAnimatorMove()
 {
     EventBus.Trigger(EventHooks.OnAnimatorMove, gameObject);
 }
 public void OnPointerExit(PointerEventData eventData) =>
 EventBus.Trigger(EventHooks.OnPointerExit, gameObject, eventData);
 private void Start()
 {
     GetComponent <InputField>()?.onEndEdit?.AddListener((value) =>
                                                         EventBus.Trigger(EventHooks.OnInputFieldEndEdit, gameObject, value));
 }
Exemple #11
0
 private void OnTriggerEnter(Collider other)
 {
     EventBus.Trigger(EventHooks.OnTriggerEnter, gameObject, other);
 }
Exemple #12
0
 public void OnBeginDrag(PointerEventData eventData)
 {
     EventBus.Trigger(EventHooks.OnBeginDrag, gameObject, eventData);
 }
 private void OnAnimatorIK(int layerIndex)
 {
     EventBus.Trigger(EventHooks.OnAnimatorIK, gameObject, layerIndex);
 }
 private void OnBecameVisible()
 {
     EventBus.Trigger(EventHooks.OnBecameVisible, gameObject);
 }
 private void OnApplicationQuit()
 {
     EventBus.Trigger(EventHooks.OnApplicationQuit);
 }
 private void OnCollisionExit(Collision collision)
 {
     EventBus.Trigger(EventHooks.OnCollisionExit, gameObject, collision);
 }
 private void OnControllerColliderHit(ControllerColliderHit hit)
 {
     EventBus.Trigger(EventHooks.OnControllerColliderHit, gameObject, hit);
 }