예제 #1
0
 // Update is called once per frame
 void Update()
 {
     if (dragging)
     {
         Vector3 mousePos = MouseInWorldCoords();
         dragginAction?.OnDraggingInUpdate(mousePos);
         transform.position = new Vector3(mousePos.x - pointerDisplacement.x, mousePos.y - pointerDisplacement.y, transform.position.z);
     }
 }
 // Update is called once per frame
 void Update()
 {
     if (player.dragging)
     {
         Vector3 mousePos = MouseInWorldCoords();
         da.OnDraggingInUpdate();
         //Debug.Log(mousePos);
         transform.position = new Vector3(mousePos.x - pointerDisplacement.x, mousePos.y - pointerDisplacement.y, transform.position.z);
     }
 }