Raanan Weber 5 年之前
父节点
当前提交
ffebe02d13
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      src/XR/features/WebXRControllerTeleportation.ts

+ 2 - 2
src/XR/features/WebXRControllerTeleportation.ts

@@ -330,8 +330,8 @@ export class WebXRMotionControllerTeleportation extends WebXRAbstractFeature {
      * This is used to remove the selection rays when moving.
      * @param selectionFeature the feature to disable when forward movement is enabled
      */
-    public setSelectionFeature(selectionFeature?: IWebXRFeature) {
-        this._selectionFeature = selectionFeature || null;
+    public setSelectionFeature(selectionFeature: Nullable<IWebXRFeature>) {
+        this._selectionFeature = selectionFeature;
     }
 
     protected _onXRFrame(_xrFrame: XRFrame) {