Browse Source

Merge pull request #10444 from Vbitz/oculus-touch-support

Added Basic Oculus Touch Support to HTC Vive Controller WebVR Examples
Mr.doob 8 years ago
parent
commit
999387a28c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      examples/js/vr/ViveController.js

+ 1 - 1
examples/js/vr/ViveController.js

@@ -27,7 +27,7 @@ THREE.ViveController = function ( id ) {
 
 
 			var gamepad = gamepads[ i ];
 			var gamepad = gamepads[ i ];
 
 
-			if ( gamepad && gamepad.id === 'OpenVR Gamepad' ) {
+			if ( gamepad && ( gamepad.id === 'OpenVR Gamepad' || gamepad.id === 'Oculus Touch (Left)' || gamepad.id === 'Oculus Touch (Right)' ) ) {
 
 
 				if ( j === id ) return gamepad;
 				if ( j === id ) return gamepad;