Browse Source

Merge pull request #19090 from Mugen87/dev49

WebXRManager: Clarify parameter of getController()/getControllerGrip().
Mr.doob 5 years ago
parent
commit
569231e228
1 changed files with 6 additions and 6 deletions
  1. 6 6
      src/renderers/webxr/WebXRManager.js

+ 6 - 6
src/renderers/webxr/WebXRManager.js

@@ -49,14 +49,14 @@ function WebXRManager( renderer, gl ) {
 
 	this.isPresenting = false;
 
-	this.getController = function ( id ) {
+	this.getController = function ( index ) {
 
-		var controller = controllers[ id ];
+		var controller = controllers[ index ];
 
 		if ( controller === undefined ) {
 
 			controller = new WebXRController();
-			controllers[ id ] = controller;
+			controllers[ index ] = controller;
 
 		}
 
@@ -64,14 +64,14 @@ function WebXRManager( renderer, gl ) {
 
 	};
 
-	this.getControllerGrip = function ( id ) {
+	this.getControllerGrip = function ( index ) {
 
-		var controller = controllers[ id ];
+		var controller = controllers[ index ];
 
 		if ( controller === undefined ) {
 
 			controller = new WebXRController();
-			controllers[ id ] = controller;
+			controllers[ index ] = controller;
 
 		}