Open dpggit opened 4 years ago
GetState for a binding to the proximity sensor should return false if it's not on your head. Maybe double check your binding is correct in the Input Debugger screen in the Binding UI?
I use public SteamVR_Action_Boolean headsetOnHead = SteamVR_Input.GetBooleanAction("HeadsetOnHead"); if (headsetOnHead.GetState(SteamVR_Input_Sources.Head)) and always enter. There is no way to set the binding for headset just for hand controllers and i dont know what input debugger screen you mean, i dont find any
My binding_vive.json is
{
"controller_type": "vive",
"description": "",
"name": "vive defaults",
"bindings": {
"/actions/default": {
"chords": [],
"sources": [
{
"path": "/user/head/proximity",
"mode": "button",
"parameters": {},
"inputs": {
"click": {
"output": "/actions/default/in/headsetonhead"
}
}
}
],
"poses": [],
"haptics": [],
"skeleton": []
},
"/actions/htc_viu": {
"chords": [],
"sources": [
{
"path": "/user/head/proximity",
"mode": "button",
"parameters": {},
"inputs": {
"click": {
"output": "/actions/htc_viu/in/viu_press_31"
}
}
}
],
"poses": [],
"haptics": [],
"skeleton": []
}
}
}
And i point the headsetOnHead variable to /actions/htc_viu/in/viu_press_31
I can check if you put the headset while the app is running using the proximity sensor, but if you already had the headset on it doesnt work. Using GetState gives always true, so its useless for this