using System.Collections; using System.Collections.Generic; using UnityEngine; public class CarSkillTest : MonoBehaviour { private void OnGUI() { if (Input.GetMouseButton(0)) { Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition); RaycastHit hit; if (Physics.Raycast(ray, out hit)) { //施放举臂技能 gameObject.GetComponent().ArmLifting(hit.point); } } } }