public static void Initialize(string ModAssemblyFolderPath) { Log.Message("Initializing ExternalDataSaver..."); if (externalDataSaver != null) { throw new Exception(); } var instance = new ExternalDataSaver(ModAssemblyFolderPath); externalDataSaver = instance; }
public RKTM(ModContentPack pack) : base(pack) { Log.Message("Initializing RKTM language injector by madeline..."); ExternalDataSaver.Initialize(pack.AssembliesFolder); singleton = this; HarmonyInstance HMinstance = HarmonyInstance.Create("Madeline.RKTM"); HarmonyInstance.DEBUG = true; TranslatorPatch.Patch(HMinstance); DefInjectionPatch.Patch(HMinstance); CustomDefInjection.Patch(HMinstance); dataSaver = ExternalDataSaver.externalDataSaver; SecondLanguagePackName = dataSaver.GetData("AlternativeLanguageName"); }