xirang/Assets/scripts/playerpoint.cs

34 lines
703 B
C#
Raw Normal View History

2024-11-26 22:01:14 +08:00
using System.Collections;
using System.Collections.Generic;
using Unity.VisualScripting.FullSerializer;
using UnityEngine;
public class playerpoint : MonoBehaviour
{
public Transform playermode;
void Start()
{
}
// Update is called once per frame
void Update()
{
Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
RaycastHit hitInfo;
if (Input.GetMouseButtonDown(0))
{
if (Physics.Raycast(ray, out hitInfo))
{
//<2F><><EFBFBD><EFBFBD>ѡ<EFBFBD><D1A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if (hitInfo.collider.gameObject.name == "showman")
{
}
}
}
}
}