Child NetworkTransforms causes the main NetworkTransform in the root/parent to stop synching with client

Child NetworkTransforms causes the main NetworkTransform in the root/parent to stop synching with client.

This can be easily replicated. Create a PlayerObject that can move via sending inputs to the server/hosting player. This playerobject should have a NetworkTransform attached to it and set to “Server” Authority. Once you confirm that it is working, add an empty gameobject into the PlayerObject, and then add a NetworkTransform to that child empty gameobject and set it to “Owner” Authority. Build the game and you will notice that Clients that connect to ther hosting player, will not move locally on the client. Their PlayerObject will only move on the host/server. Hence there is something preventing the Player’s NetworkTransform from synching between the server and client when there is are nested NetworkTransform (Owner Authority) existing in the PlayerObject’s children.

Here’s my Player Object NetworkTransform Setup:

And here’s the 4 NetworkTransforms setup attached in the children of the Player Object above:

My Setup: (The highlighted gameobjects have NetworkTransforms attached to them, only the one in the root object “Porky” has been set to “Server” Authority. The rest of the NetworkTransforms have been set to “Owner” Authority and the “Local Space” checkbox is ticked as seen)

I’m also using the Rig package components here:

The Issue:
On 1 of the non-hosting Client, I press the arrow keys to move the character. The input is sent to the hosting player/server and the server takes the input and moves the playerobject while the networktransform syncs the position of the playerobject with the client. This works with no issues UNTIL I attach 4 new networktransform component to the children objects/IK (Head, Spine, Hand, Gun). With these new components attached, the Player Object only moves on the Server side. The PlayerObject’s NetworkTransform does not sync the movement back to the client. However the 4 new NetworkTransform components on the children object syncs with the Server with no issues.

To summarize what I’m trying to do:

  1. 4 IK/GameObjects (Children of the Player Object) that are moved on the Client side when the player moves the cursor (Gun, Spine, Head, Hand). These 4 objects have each their own NetworkTransform component attached to them. (These are all set to “Owner” Authority)
  2. Player movement is handled on the Server side (The main Player Object has a NetworkTransform set to “Server” Authority.)
    I’m using a mixture of the “constraints” component in the unity’s rig package to move the character’s IK/bones. This is a similar setup rig setup I have which is based of this tutorial:
    https://youtu.be/fB0P0C_3sPU?si=l2EofpT0Zs_pa-kI

I need to know if this is a bug/limitation or if it is something I did wrong in my setup that is causing this issue.

Bump, any assistance? Is anyone else able to replicate this issue by following this procedure:

This can be easily replicated.

Create a PlayerObject that can move via sending inputs to the server/hosting player. This playerobject should have a NetworkTransform attached to it and set to “Server” Authority.

Once you confirm that it is working, add an empty gameobject into the PlayerObject, and then add a NetworkTransform to that child empty gameobject and set it to “Owner” Authority.

Build the game and you will notice that Clients that connect to ther hosting player, will not move locally on the client. Their PlayerObject will only move on the host/server. Hence there is something preventing the Player’s NetworkTransform from synching between the server and client when there is are nested NetworkTransform (Owner Authority) existing in the PlayerObject’s children.

@neoangelique
Is there a way you could submit a replication project?
You can do this a few ways (up to your preference):

  • Via editor by reporting a bug and including your project.
    • If you do this, then post back here with the bug ticket number so I can get QA to assign it to me.
  • A repository link.
  • As a zip file (you only need to include the Assets, Packages, and ProjectSettings folders).

This will expedite my ability to determine if there is just an adjustment you need to make or if this is indeed some form of bug.

@NoelStephens_Unity

Thanks for the response and could I trouble the team to reproduce the issue before I attempt the last resort of sending in my project? (I would have to remove confidential/credentials information (Firebase and other 3rd party sdks) which could take some time)

The issue can be easily replicated:
Unity 6000 + NGO 2.2.0

  1. Create a PlayerObject that can move via sending inputs to the server/hosting player. This playerobject should have a NetworkTransform attached to it and set to “Server” Authority.

  2. Once you confirm that it is working, add an empty gameobject into the PlayerObject, and then add a NetworkTransform to that child empty gameobject and set it to “Owner” Authority.
    As seen in this screenshot (Which also shows the issue where the host (Top) is moving the client’s player object, while the client (bottom) is no longer moving/sync-ed with the server):

  3. Build the game and you will notice that Clients that connect to ther hosting player, will not move locally on the client. Their PlayerObject will only move on the host/server. Hence there is something preventing the Player’s NetworkTransform from synching between the server and client when there is are nested NetworkTransform (Owner Authority) existing in the PlayerObject’s children.

In short, the player setup should look like this:

Player Network Object:
NetworkTransform Component with “Server” Authority

Empty GameObject added as a children to the above Player Network Object:
NetworkTransform Component with “Owner” Authority

@NoelStephens_Unity Basically to summarize, I’ve discovered that it may not have anything to do with the Rig package components since I’ve disabled the components and the issue is still reproduceable. Hence the issue is easily reproduceable if you/your team follow the simple procedure in my previous reply post above. Just attach an empty gameobject with a NetworkTransform set to “Owner” Authority, to any PlayerObject with a NetworkTransform set to “Server” authority.

Parent = “Server” authority
Child = “Owner” authority

I’ve tested it via Editor (Host) + a Windows Build (Client)
Unity 6000 + NGO 2.2.0

Monitor that the above causes the Parent’s NetworkTransform to no longer sync. The Client is able to move on the Server, but the movement doesn’t gets sync to the Client.

Quite a critical bug that is blocking my project from further progress.

Hi @neoangelique,
I replied to your GitHub issue and think I know what is happening and thank you for providing that as an issue on the GitHub repository.

Let me fiddle around with replicating the issue and then once I can replicate it I will make some adjustments to how NetworkTransform handles synchronizing nested NetworkTransforms (there was an update that provides synchronized updates between the root parrent and children that I think could be the cause of this).

Will update you on the GitHub issue with my findings/results.

@NoelStephens_Unity Thank you! Looking forward to the update! If it is indeed a bug will I have to pull the update directly from the github repo or will it be added directly to the next version of NGO? E.g NGO 2.2.1

1 Like