using System.Collections; using System.Collections.Generic; //using System.Windows.Forms; using UnityEngine; using AX.MessageSystem; public class PolygonDoubleClick : MonoBehaviour { private PolygonController controller; void Start() { controller = GetComponent(); } private void Update() { //if (Input.GetMouseButtonDown(1)) //{ // Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition); // RaycastHit hit; // if (Physics.Raycast(ray, out hit)) // { // if (hit.transform.gameObject == this.gameObject) // { // if (RecordManager.Instance.IsRecording) // { // TrackRecordHelpClass.RECORDPolygonThreeList(gameObject); // } // MessageDispatcher.SendMessage("ControlPolygonFalse", (object)""); // if (UIController.instance.PolygonPlane != null) // { // UIController.instance.PolygonPlane.SetActive(false); // UIController.instance.PolygonPlane.transform.position = controller.worldPositions[0]; // } // } // } //} } void OnMouseDown() { // 编辑多边形形状下,不会响应 //if (controller.Editable) // return; //TODO: 在这里处理双击事件 //Debug.Log("触发鼠标按下事件!"); } }