itch.io is community of indie game creators and players

Devlogs

Update #2: Oops I did the update thing again

Lemon Atoll
A browser game made in HTML5

Wow. Over a year since I finished my first ever VR game. For a 3-day game jam no less! A lot has changed since then. I've gotten a lot more experience, and along with that experience I've had a lot of exposure to WebXR. WebXR is a really exciting field right now, and when I realized that I actually might be able to port my game to WebXR, I knew I had to try.


So what exactly does porting a game built on SteamVR to WebXR entail? First you have to consider what it is you'll be taking out. The SteamVR player prefab, hands, interactable/grabbable scripts, and built-in teleportation will all have to go. Thankfully, through the efforts of both myself and members of the community, I was able to substitute all of them. For this project, I made use of De-Panther's WebXR exporter for Unity, a fork of the one originally by Mozilla. This gives you a camera rig for your player and the ability to export the project for WebXR by doing a WebGL build. From there, I brought in some scripts I'd already written for teleportation, and adapted the code already provided in De-Panther's WebXR Interactions. After that, it was mostly just a whole bunch of bugfixes and making sure everything actually worked together properly.

And here's the result! Fun fact, the size of the WebXR build is less than a fifth the size of the native one (15 MB vs 100 MB). The only thing I wasn't able to bring over was my Wwise integration, as currently Wwise is not able to be used in WebGL products, though they have stated it may come in the future. I think in future projects I may look at integrating FMOD or Resonance, as these will both work in WebGL builds and could prove to be a decent replacement.

So yeah, very happy to have finally made this happen. Looking forward to uploading more WebXR projects in the future.

Files

  • Lemon Atoll WebXR.zip 14 MB
    Dec 23, 2020
Download Lemon Atoll
Leave a comment