FishNet icon indicating copy to clipboard operation
FishNet copied to clipboard

3.11.5hf0 NT not spawning or syncing scene object when giving it ownership

Open celojevic opened this issue 2 years ago • 3 comments

General Unity version: 2021.3.27 LTS Fish-Networking version: 3.11.5hf0 (latest at the time of writing) Discord link: https://discord.com/channels/424284635074134018/1166750663015923834/1166756244300763176

Description When having a globally loaded scene object with a default NT on it, network object, and net observer with only a scene condition, it gives some spawning warnings (see screenshot 1). I believe this is causing the NT not to sync to clients (nor from client to host if they are the owner). This occurs with both host and client-only.

Replication Steps to reproduce the behavior:

  1. Make a scene object with an NT, nob, and net observer with only a scene condition as well as a simple controller script.
  2. Globally load this scene and give one of multiple connections ownership of it. Im doing it in the client presence change callback
private void SceneManager_OnClientPresenceChangeEnd(ClientPresenceChangeEventArgs obj)
        {
            if (!obj.Added || gameObject.scene != obj.Scene) return;
            if (RefMan.I.WielderController.Owner != obj.Connection) return;

            // give wielder the control over the cursor
            base.GiveOwnership(RefMan.I.WielderController.Owner);
        }
  1. You will get the warnings and the NT wont sync to clients.

Expected behavior Ownership change shouldnt throw warnings and the NT should sync position.

Screenshots Screenshot 1: image

celojevic avatar Oct 26 '23 15:10 celojevic

Thanks gooby. I'll take a look after 3.11.6 release.

FirstGearGames avatar Oct 27 '23 19:10 FirstGearGames

Issue confirmed but does not seem to be related to any component. Seems to be an error with the client parsing packets under these conditions.

FirstGearGames avatar Oct 28 '23 12:10 FirstGearGames

Lowered priority.

FirstGearGames avatar Nov 08 '23 15:11 FirstGearGames

This does not seem to be a problem in V4. Closing out!

FirstGearGames avatar Apr 04 '24 00:04 FirstGearGames