static private void AddResearchDefs(GreatLibrary greatLibrary) { foreach (GreatLibrary.ResearchDef researchDef in researchDefs) { greatLibrary.researchDefs.Add(researchDef); } }
static void Postfix(Building __instance) { GreatLibrary greatLibrary = __instance.GetComponent <GreatLibrary>(); if (greatLibrary != null) { AddResearchDefs(greatLibrary); } ; }
static void Postfix(GreatLibrary s) { AddResearchDefs(s); }