-
Notifications
You must be signed in to change notification settings - Fork 3
6. Using UGVR As a Dev Tool
UGVR is designed to be both a mod for end users to play their favorite Godot 4 3D games in VR if the developer does not offer official support AND a tool that Godot 4 3D developers can use to investigate potential VR support for their games when they may have limited or no experience using Godot's XR framework.
Although this is untested to date (hope to start testing soon) in theory a developer who uses the UGVR framework should be able to publish both PCVR and android (e.g., Quest, Pico, HTC Vive Elite) versions of their regular games just by exporting the game in the appropriate format.
This page describes the steps involved to use UGVR as a developer tool rather than as a standalone mod for a completed .exe.
-
Download the most recent release of UGVR if there is one or the project repository.
-
Copy the "xr_injector" folder into the root of your project directory.
-
Open up your project for editing in the editor. Turn on XR and the XR shaders in Project Settings -> XR:
This will require an editor restart, so do that.
- When you reopen your project set xr_injector.gd as an autoload.
- Connect your VR headset to your computer (whether by cable or if your headset is wireless and you have a PCVR capable PC, by Airlink or Virtual Desktop) and have it ready to display VR content. Godot uses "OpenXR." So make sure you know what your OpenXR runtime is set as (Steam, Oculus, etc.). Some runtimes may have problems with Godot, like Windows OpenXR or PicoXR. I would make sure you either have Steam set to OpenXR in the SteamVR settings or use Oculus XR.
Now if all has gone well, when you press the play preview button, your game will launch to your headset in PCVR mode and you should see your game menu or game world in OpenXR. If you try this and it does not work, please report an issue here: https://github.com/teddybear082/UGVR/issues so we can look into what might be causing issues in your game in particular. Usually it's something with shaders or how viewports are set up in your game that UGVR may not be ready to handle.
If you don't have a VR capable PC, assuming your game is very performance friendly in regular mode, you may be able to run / preview your game on your standalone VR headset. I recommend following youtube tutorials by Bastiaan Olij or MalcolmNixon to get yourself set up to do that or jumping on the Godot discord XR channel for assistance. Seems most of the issues with this come from android itself, but you may need to install some additional items in your project / on your computer and if you haven't developed your game for android it is possible you may need to delete your .godot folder and re-import assets in an android-friendly format.
To be updated.
To be updated.