Jump to content

VIVE_chengnay

Employee
  • Posts

    841
  • Joined

  • Last visited

Posts posted by VIVE_chengnay

  1. For developing PCVR, you will need to use VIVE OpenXR Plugin.

    Currently, VBS only supports OpenXR XR_EXT_hand_tracking.

    For pinch and fist gestures will be mapping to controller's trigger and grip button.

    For other gestures, you can follow the methods in below script,

    https://github.com/ViveSoftware/VRS-Studio/blob/main/VRS_Studio/Assets/Scripts/ScissorsPaperRock/ScissorsPaperRock.cs

  2. Hi @jwatson,

    You can use below code to get the language and country to differentiate between Spanish (Latin America) and Spanish (Spain).

    string GetSystemLanguage()
    {
    	AndroidJavaClass lc = new AndroidJavaClass("java/util/Locale");
    	AndroidJavaObject dl = lc.CallStatic<AndroidJavaObject>("getDefault");
    	string language = dl.Call<string>("getLanguage");
    	string country = dl.Call<string>("getCountry");
    
    	return language + "-" + country;
    }

    For Spanish (Latin America), you will get es-419.

  3. Hi @Renan Viewport,

    Not sure if below solution OK for you,

    It required to install Unity Input System plugin.

    bool IsUserPresence()
    {
    	if (ProximitySensor.current != null)
    	{
    		if (!ProximitySensor.current.IsActuated())
    			InputSystem.EnableDevice(ProximitySensor.current);
    
    		return ProximitySensor.current.distance.ReadValue() < 1;
    	}
    
    	return false;
    }

     

    On 8/23/2023 at 4:25 PM, JulienActiveMe said:

    3 minutes is a lot, is there a way I can put the HMD to sleep from script?

    Hi @JulienActiveMe,

    I forgot to reply your question.

    Sorry about that and please try the solution.

×
×
  • Create New...