Created
November 4, 2019 12:54
-
-
Save tubakihimeLoveHate/9e4fa82ecb0b6182ca264cb01c31f1dc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.EventSystems; | |
public class ControllerUI : MonoBehaviour,IBeginDragHandler,IDragHandler,IEndDragHandler | |
{ | |
public void OnBeginDrag(PointerEventData eventData){ | |
// ドラックが開始したとき | |
} | |
public void OnDrag(PointerEventData eventData){ | |
// ドラック中の処理 | |
transform.position = eventData.position; | |
} | |
public void OnEndDrag(PointerEventData eventData){ | |
// ドラックが終了したときの処理 | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment