public static void UnloadUnits() { UnitsControler.StopUnitsUpdate(); GameObject[] AllUnits = new GameObject[UnitInstance.AllUnitInstances.Count]; UnitInstance.AllUnitInstances.CopyTo(AllUnits); for (int i = 0; i < AllUnits.Length; i++) { Destroy(AllUnits[i]); } }
public void OnTerrainChanged() { Markers.MarkersControler.UpdateMarkersHeights(); PropsRenderer.Current.UpdatePropsHeights(); UnitsControler.UpdateUnitsHeights(); DecalsControler.UpdateDecals(); if (ScmapEditor.Current.Slope) { GenerateControlTex.Current.GenerateSlopeTexture(); } }
private void Awake() { Current = this; }