#Seamlessly Changing Offline to Online Scenes

2 messages · Page 1 of 1 (latest)

dawn phoenix
#

Unity editor: 2022.3.10f1
Fishnet 4.3.8R

Hi 👋

I'm trying to add an offline scene to my game, which originally only contained one online scene. I'm using the DefaultScene component on a DDOL network manager.

However, I'm running into several problems:

  1. The online scene is loaded asyncronously, meaning that for a short while, both scenes are active, and I get warnings about duplicate cameras, UI eventsystems, etc
  2. On my headless server, when a new client joins, the server seems to reload or load the online scene yet again, as I see a Start message twice. Is this something to worry about?
  3. How can I ensure that the offline scene's state is entirely reset when the client goes to the online scene, and vise versa?

Attached is my DefaultScene component. In my build settings (both for headless & client), the first scene is MENU, and the second scene is GAME.

Would someone be able to guide me in the right direction?

hazy notch
#

Hi there!
So FishNet loads all its scenes async, I'm not sure there's a way around that. I guess you could manually unload the old scene first. Loading as a global scene may also work.

The scene won't be reloaded on the server, so Start shouldn't call twice in it, most likely it's from a different object?

The offline scene gets loaded and unloaded, so its state will be reset automatically by Unity