File tree Expand file tree Collapse file tree
doc/docs/guides/game-objects Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -102,9 +102,9 @@ public class MyComponent : MonoBehaviour
102102 {
103103 Debug .Log ($" The object {identity } was spawned on the server" );
104104 }
105- private void OnServerUnspawn (NetworkIdentity identity )
105+ private void OnServerUnspawn (uint netId , NetworkIdentity identity )
106106 {
107- Debug .Log ($" The object {identity } was unspawned on the server" );
107+ Debug .Log ($" The object {identity } (netId={ netId }) was unspawned on the server" );
108108 }
109109
110110 private void ClientStarted ()
@@ -116,9 +116,9 @@ public class MyComponent : MonoBehaviour
116116 {
117117 Debug .Log ($" The object {identity } was spawned on the client" );
118118 }
119- private void OnClientUnspawn (NetworkIdentity identity )
119+ private void OnClientUnspawn (uint netId , NetworkIdentity identity )
120120 {
121- Debug .Log ($" The object {identity } was unspawned on the client" );
121+ Debug .Log ($" The object {identity } (netId={ netId }) was unspawned on the client" );
122122 }
123123}
124124```
You can’t perform that action at this time.
0 commit comments