com.unity.netcode.gameobjects icon indicating copy to clipboard operation
com.unity.netcode.gameobjects copied to clipboard

OwnerShipID not assigned properly on Server/Client seperated Projects

Open itismarcii opened this issue 3 years ago • 1 comments

Description

Hello,

I have a separate Server project that handles CharacterSpawns, which clients can control via ServerRpc requests. And i have a separate Client project that, except the camera movement, only handles client to server requests. Also in between there is a package that connects them both with the most important features.

I try to spawn several Clients on multiple ClientProjectBuilds and it seems to happen that through the SpawnManager.SpawnLocally Clients can request the same Ids and the OwnerShipId at the end gets confused. I have Clients owned by other Clients, without changing the OwnerShip.

Reproduce Steps

  1. Create Server & Client separated Projects
  2. Server NetworkManager settings over Ipv4
  3. Connect several ClientBuilds to the Server via Ipv4 at once

Actual Outcome

Clients get Owned by different Clients or NetworkObjects that spawn in between.

Expected Outcome

Client should own itself on spawn.

Environment

  • Unity Version: [2021.2.18f1]
  • Netcode Version: [e.g. 1.0.0-pre.7]

itismarcii avatar Apr 28 '22 07:04 itismarcii

MTT-3454

ashwinimurt avatar May 03 '22 23:05 ashwinimurt

Hi @itismarcii Can you try using Unity Transport and let us know if this still reproduces. It would be great if you can attach your projects for easy reproduction.

ashwinimurt avatar Aug 22 '22 18:08 ashwinimurt

Sadly the project was only a throwaway project and doesnt exist anymore, i am sorry about that. But since the latest updates i didnt encounter that problem anymore. It seems like the bug isnt around anymore after updating towards version [1.0.0]

PS: We used Unity Transport while that bug occured.

itismarcii avatar Aug 25 '22 14:08 itismarcii

Thanks for letting us know.

ashwinimurt avatar Aug 25 '22 15:08 ashwinimurt

We consider this fixed because with Netcode for GameObjects version 1.5.2 and Unity LTS version 2022.3.7 we were not able to reproduce the original problem. 👍

PyrateAkananto avatar Aug 25 '23 09:08 PyrateAkananto