Example #1
0
        private void OnStartedSwipe(SwipeEventData ev)
        {
            arrow.gameObject.SetActive(true);
            //座標を求める
            Vector3 pos = ev.detector.From * basePixel;

            arrow.transform.localPosition = pos;
        }
Example #2
0
        private void OnSwiping(SwipeEventData ev)
        {
            //角度
            arrow.eulerAngles = new Vector3(0f, 0f, ev.detector.Angle);
            //大きさ
            Vector2 delta = ev.delta * basePixel;

            arrow.sizeDelta = new Vector2(delta.magnitude, 10f);
        }
Example #3
0
 private void OnEndedSwipe(SwipeEventData ev)
 {
     arrow.gameObject.SetActive(false);
 }