Answers for "unity mouse position and angle"

C#
27

unity get mouse position

Vector3 worldPosition = Camera.main.ScreenToWorldPoint(Input.mousePosition);
Posted by: Guest on July-16-2020
0

unity get mouse position

using UnityEngine;
using System.Collections;

public class ExampleClass : MonoBehaviour
{
    void Update()
    {
        Vector3 mousePos = Input.mousePosition;            
    }
}
Posted by: Guest on February-16-2022

C# Answers by Framework

Browse Popular Code Answers by Language