예제 #1
0
 /// <summary>
 /// Sync only.
 /// </summary>
 public void UnloadSafely(Action callback = null)
 {
     SaveAsNeeded(callback);
     clearentities();
     if (FCO != null)
     {
         OwningRegion.RemoveChunkQuiet(FCO);
         FCO = null;
     }
     OwningRegion.RemoveCloudsFrom(this);
 }
예제 #2
0
 /// <summary>
 /// Safely unload the chunk.
 /// </summary>
 /// <param name="callback">Callback for when it's fully saved and unloaded.</param>
 public void UnloadSafely(Action callback = null)
 {
     SaveAsNeeded(callback);
     Clearentities();
     if (FCO != null)
     {
         OwningRegion.RemoveChunkQuiet(FCO);
         FCO = null;
     }
     OwningRegion.ForgetChunkForUpperArea(WorldPosition);
     OwningRegion.RemoveCloudsFrom(this);
 }