Drag n drop begun

This commit is contained in:
Braedon
2022-01-10 19:17:29 -05:00
parent 00e3791e6d
commit f8a8180061
12 changed files with 823 additions and 47 deletions

View File

@ -6,10 +6,12 @@ namespace RhythmHeavenMania.Common
{
public class FollowMouse : MonoBehaviour
{
public Vector2 offset;
private void Update()
{
var pos = Camera.main.ScreenToWorldPoint(Input.mousePosition);
transform.position = new Vector3(pos.x, pos.y, 0);
transform.position = new Vector3(pos.x - offset.x, pos.y - offset.y, 0);
}
}
}