Пример #1
0
 // 主线程循环
 internal static void MainThreadUpdate()
 {
     FocusEventHandler.MainThreadUpdate();
     ScreenResizeEventHandler.MainThreadUpdate();
     CollisionEventHandler.MainThreadUpdate();
     TriggerEventHandler.MainThreadUpdate();
     PointerEventHandlerForScreen.MainThreadUpdate();
     PointerEventHandlerForUI.MainThreadUpdate();
     PointerEventHandlerForMesh.MainThreadUpdate();
     KeyboardEventHandler.MainThreadUpdate();
     FrameLoopEventHandler.MainThreadUpdate();
     IntervalEventHandler.MainThreadUpdate();
     CustomEventHandler.MainThreadUpdate();
     TraceEventHandler.MainThreadUpdate();
 }
Пример #2
0
 /// <summary> 添加指针交互事件侦听 ( UI ) </summary>
 /// <param name="target">侦听对象 ( UGUI GameObject ) </param>
 /// <param name="listener">指针交互事件侦听函数 ( Params - 侦听对象,指针交互数据 ) </param>
 /// <param name="priority">设置侦听函数执行优先级,数值越高优先级越高。同数值情况下,先添加的侦听函数优先级更高,默认为 0 </param>
 public void AddPointerListenerForUI(GameObject target, Action <GameObject, PointerData> listener, int priority = 0)
 => PointerEventHandlerForUI.AddListener(target, listener, priority);
Пример #3
0
 /// <summary> 移除指针交互事件侦听 ( UI ) </summary>
 /// <param name="target">侦听对象 ( UGUI GameObject ) </param>
 /// <param name="listener">指针交互事件侦听函数 ( Params - 侦听对象,指针交互数据 ) </param>
 public void RemovePointerListenerForUI(GameObject target, Action <GameObject, PointerData> listener)
 => PointerEventHandlerForUI.RemoveListener(target, listener);