entity changes, classes
This commit is contained in:
parent
bda2b88796
commit
8bd4aedcf9
20 changed files with 1917 additions and 27 deletions
11
Assets/Scripts/AttachToCursor.cs
Normal file
11
Assets/Scripts/AttachToCursor.cs
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
public class AttachToCursor : MonoBehaviour
|
||||
{
|
||||
[SerializeField] private Camera cam;
|
||||
private void Update()
|
||||
{
|
||||
transform.position = cam.ScreenToWorldPoint(Input.mousePosition) + new Vector3(0, 0, cam.nearClipPlane);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue