The options container for the teleportation module


  • IWebXRTeleportationOptions



Optional defaultTargetMeshOptions

Find examples in Playground
defaultTargetMeshOptions: object

Values to configure the default target mesh

Type declaration

  • Optional disableAnimation?: boolean

    Disable the mesh's animation sequence

  • Optional teleportationBorderColor?: string

    Border color for the teleportation area

  • Optional teleportationFillColor?: string

    Fill color of the teleportation area

  • Optional torusArrowMaterial?: Material

    Override the default material of the torus and arrow

Optional floorMeshes

Find examples in Playground
floorMeshes: AbstractMesh[]

A list of meshes to use as floor meshes. Meshes can be added and removed after initializing the feature using the addFloorMesh and removeFloorMesh functions If empty, rotation will still work

Optional teleportationTargetMesh

Find examples in Playground
teleportationTargetMesh: AbstractMesh

Provide your own teleportation mesh instead of babylon's wonderful doughnut. If you want to support rotation, make sure your mesh has a direction indicator.

When left untouched, the default mesh will be initialized.

Optional timeToTeleport

Find examples in Playground
timeToTeleport: number

If main component is used (no thumbstick), how long should the "long press" take before teleporting

Optional useMainComponentOnly

Find examples in Playground
useMainComponentOnly: boolean

Disable using the thumbstick and use the main component (usuallly trigger) on long press. This will be automatically true if the controller doesnt have a thumbstick or touchpad.


Find examples in Playground
xrInput: WebXRInput

Babylon XR Input class for controller

Generated using TypeDoc