UNiTY检测是否点击UI: Unity 检测点击UI EventSystem eventSystem = EventSystem.current; PointerEventData pointerEventData = new PointerEventData(eventSystem); pointerEventData.position = Input.mousePosition; //射线检测ui List<RaycastResult> uiRaycastResultCache