Skip to content

Commit 4de5946

Browse files
committed
corrected additional APIs
1 parent 97bd8e0 commit 4de5946

File tree

7 files changed

+21
-3
lines changed

7 files changed

+21
-3
lines changed

com.unity.netcode.gameobjects/Runtime/Configuration/NetworkPrefab.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ public bool Equals(NetworkPrefab other)
7474
/// <summary>
7575
/// Gets the GlobalObjectIdHash of the source prefab based on the current override settings
7676
/// </summary>
77-
/// <returns>The hash value identifying the source prefab</returns>
77+
/// <value>The hash value identifying the source prefab</value>
7878
/// <exception cref="InvalidOperationException">Thrown when required prefab references are missing or invalid</exception>
7979
/// <exception cref="ArgumentOutOfRangeException">Thrown when Override has an invalid value</exception>
8080
public uint SourcePrefabGlobalObjectIdHash
@@ -112,7 +112,7 @@ public uint SourcePrefabGlobalObjectIdHash
112112
/// <summary>
113113
/// Gets the GlobalObjectIdHash of the target prefab when using prefab overrides
114114
/// </summary>
115-
/// <returns>The hash value identifying the target prefab, or 0 if no override is set</returns>
115+
/// <value>The hash value identifying the target prefab, or 0 if no override is set</value>
116116
/// <exception cref="InvalidOperationException">Thrown when required prefab references are missing or invalid</exception>
117117
/// <exception cref="ArgumentOutOfRangeException">Thrown when Override has an invalid value</exception>
118118
public uint TargetPrefabGlobalObjectIdHash

com.unity.netcode.gameobjects/Runtime/Configuration/NetworkPrefabs.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,9 @@ private void RemoveTriggeredByNetworkPrefabList(NetworkPrefab networkPrefab)
6565
m_Prefabs.Remove(networkPrefab);
6666
}
6767

68+
/// <summary>
69+
/// Finalizer that ensures proper cleanup of network prefab resources
70+
/// </summary>
6871
~NetworkPrefabs()
6972
{
7073
Shutdown();
@@ -87,7 +90,7 @@ internal void Shutdown()
8790
/// Processes the <see cref="NetworkPrefabsList"/> if one is present for use during runtime execution,
8891
/// else processes <see cref="Prefabs"/>.
8992
/// </summary>
90-
/// /// <param name="warnInvalid">When true, logs warnings about invalid prefabs that are removed during initialization</param>
93+
/// <param name="warnInvalid">When true, logs warnings about invalid prefabs that are removed during initialization</param>
9194
public void Initialize(bool warnInvalid = true)
9295
{
9396
m_Prefabs.Clear();

com.unity.netcode.gameobjects/Runtime/NetworkVariable/AnticipatedNetworkVariable.cs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,10 @@ public class AnticipatedNetworkVariable<T> : NetworkVariableBase
9494
/// the anticipationTime value, and that callback can be used to calculate a new anticipated value.
9595
/// </summary>
9696
#pragma warning restore IDE0001
97+
98+
/// <summary>
99+
/// Controls how this network variable handles authoritative updates that are older than the current anticipated state
100+
/// </summary>
97101
public StaleDataHandling StaleDataHandling;
98102

99103
/// <summary>
@@ -334,6 +338,9 @@ public override void Dispose()
334338
}
335339
}
336340

341+
/// <summary>
342+
/// Finalizer that ensures proper cleanup of network variable resources
343+
/// </summary>
337344
~AnticipatedNetworkVariable()
338345
{
339346
Dispose();

com.unity.netcode.gameobjects/Runtime/NetworkVariable/Collections/NetworkList.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,9 @@ public NetworkList(IEnumerable<T> values = default,
4949
}
5050
}
5151

52+
/// <summary>
53+
/// Finalizer that ensures proper cleanup of network list resources
54+
/// </summary>
5255
~NetworkList()
5356
{
5457
Dispose();

com.unity.netcode.gameobjects/Runtime/NetworkVariable/NetworkVariable.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,7 @@ public virtual T Value
156156
/// If you invoked this when a collection is dirty, it will not trigger the <see cref="OnValueChanged"/> unless you set forceCheck param to true. <br />
157157
/// </remarks>
158158
/// <param name="forceCheck"> when true, this check will force a full item collection check even if the NetworkVariable is already dirty</param>
159+
/// <returns>True if the variable is dirty and needs synchronization, false otherwise</returns>
159160
public bool CheckDirtyState(bool forceCheck = false)
160161
{
161162
var isDirty = base.IsDirty();

com.unity.netcode.gameobjects/Runtime/NetworkVariable/NetworkVariableBase.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ internal void LogWritePermissionError()
6565
/// <summary>
6666
/// Gets the NetworkBehaviour instance associated with this network variable
6767
/// </summary>
68+
/// <returns>The NetworkBehaviour that owns this network variable</returns>
6869
public NetworkBehaviour GetBehaviour()
6970
{
7071
return m_NetworkBehaviour;

com.unity.netcode.gameobjects/Runtime/Spawning/NetworkSpawnManager.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1800,6 +1800,9 @@ internal NetworkSpawnManager(NetworkManager networkManager)
18001800
NetworkManager = networkManager;
18011801
}
18021802

1803+
/// <summary>
1804+
/// Finalizer that ensures proper cleanup of spawn manager resources
1805+
/// </summary>
18031806
~NetworkSpawnManager()
18041807
{
18051808
Shutdown();

0 commit comments

Comments
 (0)