mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 11:00:32 +00:00
comments
This commit is contained in:
parent
77a3e0f23b
commit
7071a6afc8
@ -129,14 +129,14 @@ static void CleanupNetworkIdentities()
|
|||||||
{
|
{
|
||||||
if (identity != null)
|
if (identity != null)
|
||||||
{
|
{
|
||||||
// scene objects are reset and disabled.
|
// spawned scene objects are reset and disabled.
|
||||||
// they always stay in the scene, we don't destroy them.
|
// they always stay in the scene, we don't destroy them.
|
||||||
if (identity.sceneId != 0)
|
if (identity.sceneId != 0)
|
||||||
{
|
{
|
||||||
identity.Reset();
|
identity.Reset();
|
||||||
identity.gameObject.SetActive(false);
|
identity.gameObject.SetActive(false);
|
||||||
}
|
}
|
||||||
// spawned objects are destroyed
|
// spawned prefabs are destroyed
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
GameObject.Destroy(identity.gameObject);
|
GameObject.Destroy(identity.gameObject);
|
||||||
|
Loading…
Reference in New Issue
Block a user