Beispiel #1
0
        void Awake()
        {
            instance        = this;
            m_selfTransform = this.transform;

            moveStart = OnMoveStart;
            moveEnd   = OnMoveEnd;
            m_guiJoystackController = JoystickController.instance;
        }
        void Awake()
        {
            instance = this;

            #region 添加操作响应函数
            //1.拖拽开始响应函数
            EventTriggrListener.GetEventTriggerListener(gameObject).OnDragDelegate = OnDragDelegate;

            //2.拖拽结束响应函数
            EventTriggrListener.GetEventTriggerListener(gameObject).OnDragEndDelegate = OnDragEndDelegate;

            //3.触摸按钮响应函数
            EventTriggrListener.GetEventTriggerListener(gameObject).OnPointDownDelegate = OnPointerDownDelegate;
            #endregion
        }