public override void Dispose() { OnDisposeWorld(); #if Client TickSystem.RemoveTick(this); #elif Server Server.Tick -= Tick; #endif }
public override void Dispose() { #if Client TickSystem.RemoveTick(this); #elif Server Server.Tick -= Tick; #endif _IsEntityReady = false; }
public override void Dispose() { isReady = false; for (int i = 0; i < _trees.Count; i++) { _trees[i].OnDestroy(); } _trees.Clear(); TickSystem.RemoveTick(this); if (_meshRender != null) { _meshRender.Dispose(); } if (_waterMeshRender != null) { _waterMeshRender.Dispose(); } if (ChunkMesh != null) { ChunkMesh.Dispose(); } if (WaterMesh != null) { WaterMesh.Dispose(); } if (_meshCollider != null) { _meshCollider.Dispose(); } }