public void destroyActors() { root.remove(); foreach (KeyValuePair <string, CActor> kvp in actors) { kvp.Value.remove(); } }
private void _destroyActors(bool hardDelete = true) { root.remove(); root = null; foreach (KeyValuePair <string, CActor> kvp in actors) { if (hardDelete) { Map.CMapManager.removeFromActorRegistry(kvp.Value); } kvp.Value.remove(); } actors.Clear(); Map.CMapManager.removeComponent(this); }