Stay organized with collections Save and categorize content based on your preferences.
Teleportation is a type of locomotion that allows the player to move around a VR environment with minimal discomfort. With teleportation, the player points the controller at a location they'd like to move to, then initiates the teleportation action, they are transitioned to that location via a rapid animation tuned to maintain player comfort.
Inside Elements we provide a high performance teleportation implementation that can customized as desired.
Getting startedYou can add Teleportation to an existing scene as follows:
TeleportController
prefab must be pointing in the same direction as the player character for teleporting to function.Player
game object into the Player Transform slot. This transform will be used to move your player around the scene while teleporting.The core of the Teleportation implementation is the Visualizer, Detector, and Transition scripts. Each is independent and can be customized to fit your app's needs.
The Visualizer
script handles the visualization associated with the teleportation. In the default app this consists of a disk showing the target location and a drawn arc from the player to the location.
You can adjust this visualization by creating your own prefabs and assigning them to the Target Prefab property on the TeleportController
object.
The Detector
script handles raycasting that determines a valid teleportation location. By default this is arc-raycasting, but it can be customized to line or any other kind of raycasting by subclassing BaseTeleportDetector
and implementing your own raycasting.
The Transition
script handles the visual transition that occurs when a player initiates a teleportation ction. By default we provide LinearTeleportTransition
which is a rapid movement animation from the current location to the target location. You can create custom animations by subclassing BaseTeleportTransition
and setting your custom transition to the Transition property on the Teleport Controller
object.
You can customize which controller buttons trigger teleporting by changing the Teleport Trigger property on TeleportController
. Triggers are used as a way to decouple the teleport code from the controller (or logic) that makes it operate. If you'd like to change the button that triggers teleproting you can find more tiggers inside Common/Scripts/Utility/Triggers. We provide triggers for a few common configurations such as using the trackpad click, app button click, and trackpad edge contact.
You can easily build your own triggers by subclassing BaseActionTrigger
and overriding TriggerActive()
.
All rights reserved. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-10-09 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-10-09 UTC."],[[["Teleportation in VR allows players to move around comfortably by selecting a target location and quickly transitioning there."],["The Elements package provides a customizable teleportation system with a visualizer, detector, and transition component."],["You can modify the teleportation visualization, target detection method, and transition animation to suit your application."],["Controller button mappings can be customized to trigger teleportation using different inputs or actions."]]],["Teleportation moves the player in a VR environment via controller input. Key actions include: pointing the controller, then triggering teleportation to move to a desired location. To implement, add the `TeleportController` prefab, and set the Player and Controller transforms. Customization is available through `Visualizer`, `Detector`, and `Transition` scripts, allowing changes to the target visualization, raycasting method, and transition animation. The trigger button for teleportation can also be modified by changing the `Teleport Trigger`.\n"]]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4