Commit 0f959eb
authored
* fix
This resolves the issue where any NetworkObjects created during client synchronization when scene management is enabled. client synchronization mode is set to LoadSceneMode.Single, and the active scene (where the NetworkObjects are created) is unloaded during synchronization.
* fix
This fixes the exception that can occur when there are many (100's) NetworkObjects spawned and the application instance is exited (or you exit play mode in the editor).
* style
removing auto-added namespace
* test
Updating WhenManyObjectsAreSpawnedAtOnce_AllAreReceived test as it was not using the right logic to validate all NetworkObjects had been spawned.
Adding WhenManyObjectsAreSpawnedDuringSynchronization_AllAreReceived to validate this PR.
* update
adding changelog entry
* test
Migrating WhenManyObjectsAreSpawnedDuringSynchronization_AllAreReceived to SpawnNetworkObjectsDuringSynchronizationTest.SpawnNetworkObjectsDuringSynchronization.
* fix
Scenes loaded in single mode, after a client is connected, will defer CreateObjectMessage driven spawning until the scene loading event is completed. Consolidated the logic into a single method.
Added two new SceneEventProgress enums to be returned when a client attempts to load or unload a scene using NetworkSceneManager or any instance type tries to use the NetworkSceneManager when scene management is disabled (as opposed to throwing an exception it just logs a warning and returns the relative SceneEventProgress value).
* test
Made modifications due to SceneEventProgress adjustments.
Renamed SpawnNetworkObjectsDuringSynchronizationTest to SpawnNetworkObjectsDuringSceneEventsTest and migrated it to the test project tests runtime NetworkSceneManager folder.
Added an additional
* update
Updated the change log entry.
* style
removing unused namespace.
* Update CHANGELOG.md
* Update CHANGELOG.md
Fixing bad changelog merge
* Update SceneEventProgress.cs
Fixing the issue with the enum changes breaking the InternalNetcodeError value
* Update SceneEventProgress.cs
* update
Made adjustments based on PR review suggestions.
Added additional changelog entries to better reflect the PR.
1 parent dc8bbc4 commit 0f959eb
File tree
9 files changed
+336
-67
lines changed- com.unity.netcode.gameobjects
- Runtime
- Messaging/Messages
- SceneManagement
- Tests/Runtime/NetworkObject
- testproject/Assets/Tests/Runtime/NetworkSceneManager
9 files changed
+336
-67
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
13 | 16 | | |
14 | 17 | | |
15 | 18 | | |
| 19 | + | |
16 | 20 | | |
17 | 21 | | |
18 | 22 | | |
| |||
21 | 25 | | |
22 | 26 | | |
23 | 27 | | |
| 28 | + | |
| 29 | + | |
24 | 30 | | |
25 | 31 | | |
26 | 32 | | |
| |||
Lines changed: 23 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
1 | 2 | | |
2 | 3 | | |
3 | 4 | | |
| |||
34 | 35 | | |
35 | 36 | | |
36 | 37 | | |
37 | | - | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
38 | 48 | | |
39 | | - | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
40 | 61 | | |
41 | 62 | | |
42 | 63 | | |
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | | - | |
| 30 | + | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| |||
Lines changed: 107 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
4 | 5 | | |
5 | 6 | | |
6 | 7 | | |
| |||
597 | 598 | | |
598 | 599 | | |
599 | 600 | | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
| 640 | + | |
| 641 | + | |
600 | 642 | | |
601 | 643 | | |
602 | 644 | | |
| |||
969 | 1011 | | |
970 | 1012 | | |
971 | 1013 | | |
972 | | - | |
| 1014 | + | |
973 | 1015 | | |
974 | | - | |
| 1016 | + | |
| 1017 | + | |
975 | 1018 | | |
976 | 1019 | | |
977 | | - | |
| 1020 | + | |
978 | 1021 | | |
979 | | - | |
980 | | - | |
981 | | - | |
982 | | - | |
| 1022 | + | |
| 1023 | + | |
983 | 1024 | | |
984 | 1025 | | |
985 | 1026 | | |
| |||
998 | 1039 | | |
999 | 1040 | | |
1000 | 1041 | | |
1001 | | - | |
| 1042 | + | |
1002 | 1043 | | |
1003 | | - | |
| 1044 | + | |
| 1045 | + | |
1004 | 1046 | | |
1005 | | - | |
| 1047 | + | |
| 1048 | + | |
1006 | 1049 | | |
1007 | | - | |
1008 | | - | |
1009 | | - | |
1010 | | - | |
| 1050 | + | |
| 1051 | + | |
1011 | 1052 | | |
1012 | 1053 | | |
1013 | 1054 | | |
| |||
1112 | 1153 | | |
1113 | 1154 | | |
1114 | 1155 | | |
| 1156 | + | |
1115 | 1157 | | |
1116 | 1158 | | |
1117 | 1159 | | |
| |||
1697 | 1739 | | |
1698 | 1740 | | |
1699 | 1741 | | |
| 1742 | + | |
| 1743 | + | |
| 1744 | + | |
1700 | 1745 | | |
1701 | 1746 | | |
1702 | 1747 | | |
| |||
2058 | 2103 | | |
2059 | 2104 | | |
2060 | 2105 | | |
| 2106 | + | |
| 2107 | + | |
| 2108 | + | |
2061 | 2109 | | |
2062 | 2110 | | |
2063 | 2111 | | |
| |||
2549 | 2597 | | |
2550 | 2598 | | |
2551 | 2599 | | |
| 2600 | + | |
| 2601 | + | |
| 2602 | + | |
| 2603 | + | |
| 2604 | + | |
| 2605 | + | |
| 2606 | + | |
| 2607 | + | |
| 2608 | + | |
| 2609 | + | |
| 2610 | + | |
| 2611 | + | |
| 2612 | + | |
| 2613 | + | |
| 2614 | + | |
| 2615 | + | |
| 2616 | + | |
| 2617 | + | |
| 2618 | + | |
| 2619 | + | |
| 2620 | + | |
| 2621 | + | |
| 2622 | + | |
| 2623 | + | |
| 2624 | + | |
| 2625 | + | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
| 2630 | + | |
| 2631 | + | |
| 2632 | + | |
| 2633 | + | |
| 2634 | + | |
| 2635 | + | |
| 2636 | + | |
| 2637 | + | |
| 2638 | + | |
| 2639 | + | |
| 2640 | + | |
| 2641 | + | |
| 2642 | + | |
| 2643 | + | |
| 2644 | + | |
2552 | 2645 | | |
2553 | 2646 | | |
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
50 | 58 | | |
51 | 59 | | |
52 | 60 | | |
| |||
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
60 | | - | |
61 | | - | |
62 | | - | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
0 commit comments