01-29-2024 12:48 PM - edited 01-29-2024 12:52 PM
I am integrating the MetaXR plugin into my game for body tracking. All is well, but now the multiplayer servers always crash. After extensive testing, I decided to just launch the MovementSample as a client with a dedicated server, and notice that crashes on startup as well, isolating the problem to the MetaXR plugin and not my game.
This render multiplayer usage currently not possible. Am I missing a step perhaps?
Would be great to use it within multiplayer.
The logs don't really provide any context. There are these few errors, which may be the culprit, however, I will note the console continues to log for awhile before the crash. The crash occurs when the player connects to the server. The server alone will live on its own indefinitely.
Solved! Go to Solution.
03-08-2024 06:25 AM - edited 03-08-2024 10:42 AM
You don't need tracking features in your server code (the server version of your player).
The tracking components in your player such as BodyTrackingComponent should only exist on client side.You got two options: Add a Is dedicated server check in your player Construction script and only create those components in runtime if you are NOT a server or Destroy said components if you are indeed server (this last option is generally not the safest).
Your Server won't be wearing a quest headset, thus it doesn't have the tracking info, thats probably why it fails to initialize. You need to handle body transform data replication on your own.
02-08-2024 01:32 PM
Bump. Any ideas?
The Meta XR plugin cannot be used with dedicated servers. This is a large bug!
02-15-2024 02:09 PM
you may need to put all of that into a function library, and create a another version of the function library that use use to build your server where you have all the same functions but they don't link to any oculus code.
02-16-2024 12:58 PM
Is there any further guidance or reference you can give me on how to achieve this? I got kind of decently far with ChatGPT (lol). Trying to make it not execute any Oculus functions if its a server, but I also don't know if that's the proper answer. At this point, trying to get it to work at all
02-18-2024 01:11 PM - edited 03-07-2024 10:13 AM
Bump!
03-07-2024 10:13 AM
Any clue yet? This is a huge bottleneck for multiplayer games with cloud servers
03-08-2024 06:25 AM - edited 03-08-2024 10:42 AM
You don't need tracking features in your server code (the server version of your player).
The tracking components in your player such as BodyTrackingComponent should only exist on client side.You got two options: Add a Is dedicated server check in your player Construction script and only create those components in runtime if you are NOT a server or Destroy said components if you are indeed server (this last option is generally not the safest).
Your Server won't be wearing a quest headset, thus it doesn't have the tracking info, thats probably why it fails to initialize. You need to handle body transform data replication on your own.
03-09-2024 09:12 AM
I knew this concept was correct, but wasn't sure how to best apply it. I was messing with C++ and everything. Good grief.
Using the Remote path on a SwitchHasAuthority node before all of the tracking related blueprint nodes on Begin Play and Event Tick fixed this for me. I can confirm the tracking is working in a Dedicated Server session now. WHOOP WHOOP!
Thank you! I was stuck on this for such a ridiculously much longer time than I should have been *facepalm*