Пример #1
0
 public void OnLeave(IState nextState)
 {
     sceneManager.rightEvents.TriggerPressed  -= rightTriggerPressed;
     sceneManager.rightEvents.TriggerReleased -= rightTriggerReleased;
     sceneManager.leftEvents.TriggerPressed   -= leftTriggerPressed;
     sceneManager.leftEvents.TriggerReleased  -= leftTriggerReleased;
     if (transforming && curObj != null && curObj.transform.parent != null)
     {
         curObj.transform.parent = null;
     }
     if (curObj != null)
     {
         curObj.ResetStatus();
         curObj = null;
     }
 }
Пример #2
0
 public void OnLeave(IState nextState)
 {
     sceneManager.rightEvents.TriggerPressed -= rightTriggerPressed;
     if (curObject != null)
     {
         curObject.ResetStatus();
         if (curObject.transform.parent != null)
         {
             curObject = null;
         }
     }
 }
Пример #3
0
 private void SelectObject(MObject obj)
 {
     if (curObj != obj)
     {
         if (curObj != null)
         {
             curObj.ResetStatus();
         }
         if (obj != null)
         {
             obj.Select();
         }
         curObj = obj;
     }
 }
Пример #4
0
 private void SelectObject(MObject obj)
 {
     if (curObj != obj)
     {
         if (curObj != null)
         {
             curObj.ResetStatus();
             curObj.InactiveTextMesh();
         }
         if (obj != null)
         {
             obj.Select();
             obj.ActiveTextMesh();
             obj.SetMeshText("按右手手柄侧键,\n删除当前选中模型");
         }
         curObj = obj;
     }
 }