Skip to content

fix: NetworkObjects do not honor when Auto Object Parent Sync is turned off#2281

Merged
NoelStephensUnity merged 5 commits intodevelopfrom
fix/in-scene-networkobject-parenting-regression
Oct 28, 2022
Merged

fix: NetworkObjects do not honor when Auto Object Parent Sync is turned off#2281
NoelStephensUnity merged 5 commits intodevelopfrom
fix/in-scene-networkobject-parenting-regression

Conversation

@NoelStephensUnity
Copy link
Copy Markdown
Member

@NoelStephensUnity NoelStephensUnity commented Oct 28, 2022

This fix resolves a regression based bug from the parenting updates and added scale synchronization in V1.1.0.
Auto Object Parent Synchronization was not taken into consideration with those updates.

MTT-5000

Changelog

  • Fixed: Issue where in-scene placed NetworkObjects were not honoring the AutoObjectParentSync property.

Testing and Documentation

  • Includes integration test.

This resolves the issue where NetworkObjects were not taking Auto Object Parent Sync into consideration.
The test to validate that nested in-scene placed NetworkObjects that both have Auto Object Parent Synchronization enabled and disabled synchronize their transforms properly on the client side. The same test covers NetworkObjects nested under GameObjects with no NetworkObject components.  All nested instances have varying position, rotation, and scale values.
@NoelStephensUnity NoelStephensUnity requested a review from a team as a code owner October 28, 2022 00:32
/// Helper class that builds 4 transform lists based on parent-child hierarchy
/// for the <see cref="ParentingInSceneObjectsTests.InSceneNestedAutoSyncObjectTest"/>
/// </summary>
public class ParentinAutoSyncManager : NetworkBehaviour
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
public class ParentinAutoSyncManager : NetworkBehaviour
public class ParentingAutoSyncManager : NetworkBehaviour

Copy link
Copy Markdown
Member Author

@NoelStephensUnity NoelStephensUnity Oct 28, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

! (>.<) DOH!

Thank you for catching that spelling issue.
Added the "g" to the class and filename.

fixing spelling issue.
@NoelStephensUnity NoelStephensUnity enabled auto-merge (squash) October 28, 2022 21:44
@NoelStephensUnity NoelStephensUnity merged commit f43e700 into develop Oct 28, 2022
@NoelStephensUnity NoelStephensUnity deleted the fix/in-scene-networkobject-parenting-regression branch October 28, 2022 22:48
jakobbbb pushed a commit to GooseGirlGames/com.unity.netcode.gameobjects that referenced this pull request Feb 22, 2023
…ed off (Unity-Technologies#2281)

* fix
This resolves the issue where NetworkObjects were not taking Auto Object Parent Sync into consideration.

* test
The test to validate that nested in-scene placed NetworkObjects that both have Auto Object Parent Synchronization enabled and disabled synchronize their transforms properly on the client side. The same test covers NetworkObjects nested under GameObjects with no NetworkObject components.  All nested instances have varying position, rotation, and scale values.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants