|
@@ -67,8 +67,8 @@ THREE.ViveController = function ( id ) {
|
|
|
|
|
|
var pose = gamepad.pose;
|
|
|
|
|
|
- scope.position.fromArray( pose.position );
|
|
|
- scope.quaternion.fromArray( pose.orientation );
|
|
|
+ if ( pose.position !== null ) scope.position.fromArray( pose.position );
|
|
|
+ if ( pose.orientation !== null ) scope.quaternion.fromArray( pose.orientation );
|
|
|
scope.matrix.compose( scope.position, scope.quaternion, scope.scale );
|
|
|
scope.matrix.multiplyMatrices( scope.standingMatrix, scope.matrix );
|
|
|
scope.matrixWorldNeedsUpdate = true;
|