Exemple #1
0
 private void ActivateAvailableController()
 {
     if (Application.platform == RuntimePlatform.Android)
     {
         if (HVRPluginCore.IsPhoneController())
         {
             HVRLogCore.LOGI(TAG, "on phonecontroller mode");
             m_IsPhoneControllerMode = true;
             m_DefaultControllerObj.SetActive(false);
             m_PhoneControllerObj.SetActive(true);
             m_ControllerObj = m_PhoneControllerObj;
         }
         else
         {
             m_IsPhoneControllerMode = false;
             HVRLogCore.LOGI(TAG, "on controller mode");
             m_DefaultControllerObj.SetActive(true);
             m_PhoneControllerObj.SetActive(false);
             m_ControllerObj = m_DefaultControllerObj;
         }
     }
 }
Exemple #2
0
 void Start()
 {
     if (Application.platform == RuntimePlatform.Android)
     {
         if (HVRPluginCore.IsPhoneController())
         {
             HVRLogCore.LOGI(TAG, "show phoneController help msg");
             m_IsPhoneControllerMode = true;
             m_phoneHelpMessage.gameObject.SetActive(true);
             m_controllerHelpMessage.gameObject.SetActive(false);
             m_helpMessage = m_phoneHelpMessage;
             InitPhoneControllerMsg();
         }
         else
         {
             HVRLogCore.LOGI(TAG, "show controller help msg");
             m_IsPhoneControllerMode = false;
             m_controllerHelpMessage.gameObject.SetActive(true);
             m_phoneHelpMessage.gameObject.SetActive(false);
             m_helpMessage = m_controllerHelpMessage;
             InitDefaultControllerMsg();
         }
     }
     else
     {
         InitDefaultControllerMsg();
     }
     if (transform.parent.name == "HVRLeftController")
     {
         m_IsRightController = false;
     }
     else
     {
         m_IsRightController = true;
     }
 }