UxrTeleportSpawnCollider.GetSpawnPos Method

If there are two spawn positions (one side and other side) it will return the farthest one to the avatar. This is useful to simulate ladders and other spawn elements that will allow to go from one side to the other. Otherwise it will just return the single spawn position.

Namespace: UltimateXR.Locomotion
Assembly: UltimateXR (in UltimateXR.dll) Version: 0.0.0.0

Syntax

C#

public Transform GetSpawnPos(
	UxrAvatar avatar,
	out Vector3 targetPosition
)

Parameters

 

avatar
Type: UltimateXR.Avatar.UxrAvatar
Avatar
targetPosition
Type: Vector3
Where the target position should be rendered. This is useful when you want a user to teleport to a chair, where the spawn position would be the base of the chair, but the target should be rendered on top of the seat instead.

Return Value

Type: Transform
Farthest spawn position to the player available

See Also

Reference

UxrTeleportSpawnCollider Class
UltimateXR.Locomotion Namespace