public static void InitAndClearTechList() { TechList = new KCTObservableList <TechItem>(); if (KerbalConstructionTime.Instance != null) // Can be null/destroyed in the main menu scene { TechList.Updated += KerbalConstructionTime.Instance.ForceUpdateRndScreen; } }
public static void InitAndClearTechList() { if (TechList != null) { TechList.Clear(); } else { TechList = new KCTObservableList <TechItem>(); } TechList.Updated += KerbalConstructionTime.Instance.UpdateTechlistIconColor; }
public string GetBlockingTech(KCTObservableList <TechItem> techList) { string blockingTech = null; List <string> parentList = KerbalConstructionTimeData.techNameToParents[TechID]; foreach (var t in techList) { if (parentList != null && parentList.Contains(t.TechID)) { blockingTech = t.TechName; break; } } return(blockingTech); }
public static void InitAndClearTechList() { TechList = new KCTObservableList <TechItem>(); TechList.Updated += KerbalConstructionTime.Instance.ForceUpdateRndScreen; }