private bool HandleJumpTouchEvent() { if (!JumpTouching) { return(false); } // If already jump touching if (!JumpStart) { _joystick2.Drag(RightTouch.Value); } return(HandleJumpEvent()); }
private bool HandleWalkTouchEvent() { if (!WalkTouching) { return(false); } // If already dragging if (!WalkBegin) { _joystick1.Drag(LeftTouch.Value, true); } return(HandleWalkEvent()); }
public void OnDrag(PointerEventData eventData) { Joystick.gameObject.transform.position = GetMousePosition(); Joystick.Drag(eventData); }