Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save flushpot1125/ea4b4af662d7ef8f648efeb5968aadb9 to your computer and use it in GitHub Desktop.
Save flushpot1125/ea4b4af662d7ef8f648efeb5968aadb9 to your computer and use it in GitHub Desktop.
//left:Y, right:B
webVRController.onSecondaryButtonStateChangedObservable.add((stateObject)=>{
if(webVRController.hand ==='left'){
if(stateObject.pressed === true){
console.log("Left Y button pressed");
}
}else{
if(stateObject.pressed === true){
console.log("Right B button pressed");
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment