From f1a9ff4ca6e9d84ca9896fea19bf8e420a10fa14 Mon Sep 17 00:00:00 2001 From: Noel Stephens Date: Thu, 20 Nov 2025 11:41:55 -0600 Subject: [PATCH 1/2] update Updating documentation on SceneMigrationSynchronization --- .../Documentation~/components/core/networkobject.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/com.unity.netcode.gameobjects/Documentation~/components/core/networkobject.md b/com.unity.netcode.gameobjects/Documentation~/components/core/networkobject.md index 492ea0d2af..d991f44950 100644 --- a/com.unity.netcode.gameobjects/Documentation~/components/core/networkobject.md +++ b/com.unity.netcode.gameobjects/Documentation~/components/core/networkobject.md @@ -112,9 +112,10 @@ Similar to [`NetworkObject.ActiveSceneSynchronization`](#active-scene-synchroniz `NetworkObject.ActiveSceneSynchronization` can be used with `NetworkObject.SceneMigrationSynchronization` as long as you take into consideration that if you migrate a NetworkObject into a non-active scene via `SceneManager.MoveGameObjectToScene` and later change the active scene, then the NetworkObject instance will be automatically migrated to the newly set active scene. -:::warning -Scene migration synchronization is enabled by default. For NetworkObjects that don't require it, such as those that generate static environmental objects like trees, it's recommended to disable scene migration synchronization to avoid additional processing overheads. -::: +> [!NOTE] +> **Performance Check** +> The `NetworkObject.SceneMigrationSynchronization` field is enabled by default! If your project can have many (600-1000+) spawned objects at any given time, this setting can cause performance issues. This setting only provides the ability to automatically synchronize the scene a NetworkObject is migrated to while it is spawned. If your `NetworkObject` does not change scenes and you have no need for automatic scene migration synchronization (_only applies when the integration scene management is enabled_), then it is recommended to disable this property to avoid additional processing overheads. + ## Additional resources From 33d0f439ab5e93bc71548c5e87c4debe57ce5ae4 Mon Sep 17 00:00:00 2001 From: Noel Stephens Date: Thu, 20 Nov 2025 11:42:27 -0600 Subject: [PATCH 2/2] update adding break --- .../Documentation~/components/core/networkobject.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/com.unity.netcode.gameobjects/Documentation~/components/core/networkobject.md b/com.unity.netcode.gameobjects/Documentation~/components/core/networkobject.md index d991f44950..45a6dd8c96 100644 --- a/com.unity.netcode.gameobjects/Documentation~/components/core/networkobject.md +++ b/com.unity.netcode.gameobjects/Documentation~/components/core/networkobject.md @@ -113,7 +113,7 @@ Similar to [`NetworkObject.ActiveSceneSynchronization`](#active-scene-synchroniz `NetworkObject.ActiveSceneSynchronization` can be used with `NetworkObject.SceneMigrationSynchronization` as long as you take into consideration that if you migrate a NetworkObject into a non-active scene via `SceneManager.MoveGameObjectToScene` and later change the active scene, then the NetworkObject instance will be automatically migrated to the newly set active scene. > [!NOTE] -> **Performance Check** +> **Performance Check**
> The `NetworkObject.SceneMigrationSynchronization` field is enabled by default! If your project can have many (600-1000+) spawned objects at any given time, this setting can cause performance issues. This setting only provides the ability to automatically synchronize the scene a NetworkObject is migrated to while it is spawned. If your `NetworkObject` does not change scenes and you have no need for automatic scene migration synchronization (_only applies when the integration scene management is enabled_), then it is recommended to disable this property to avoid additional processing overheads.