public override void Load() { // Too many people are downloading 0.10 versions on 0.9.... if (ModLoader.version < new Version(0, 10)) { throw new Exception("\nThis mod uses functionality only present in the latest tModLoader. Please update tModLoader to use this mod\n\n"); } instance = this; ToggleChecklistHotKey = RegisterHotKey("Toggle Boss Checklist", "P"); tremorLoaded = ModLoader.GetMod("Tremor") != null; bossTracker = new BossTracker(); if (!Main.dedServ) { bossChecklistUI = new BossChecklistUI(); bossChecklistUI.Activate(); bossChecklistInterface = new UserInterface(); bossChecklistInterface.SetState(bossChecklistUI); UICheckbox.checkboxTexture = GetTexture("checkBox"); UICheckbox.checkmarkTexture = GetTexture("checkMark"); } }
public override void Unload() { instance = null; ToggleChecklistHotKey = null; bossChecklistInterface = null; bossTracker = null; UICheckbox.checkboxTexture = null; UICheckbox.checkmarkTexture = null; }
public override void Load() { instance = this; ToggleChecklistHotKey = RegisterHotKey("Toggle Boss Checklist", "P"); ToggleBossLog = RegisterHotKey("Toggle Boss Log", "L"); tremorLoaded = ModLoader.GetMod("Tremor") != null; FieldInfo itemToMusicField = typeof(SoundLoader).GetField("itemToMusic", BindingFlags.Static | BindingFlags.NonPublic); itemToMusicReference = (Dictionary <int, int>)itemToMusicField.GetValue(null); bossTracker = new BossTracker(); MapAssist.FullMapInitialize(); if (!Main.dedServ) { bossChecklistUI = new BossChecklistUI(); bossChecklistUI.Activate(); bossChecklistInterface = new UserInterface(); UICheckbox.checkboxTexture = GetTexture("UIElements/checkBox"); UICheckbox.checkmarkTexture = GetTexture("UIElements/checkMark"); BossLog = new BossLogUI(); BossLog.Activate(); BossLogInterface = new UserInterface(); BossLogInterface.SetState(BossLog); //important, after setup has been initialized BossRadarUI = new BossRadarUI(); BossRadarUI.Activate(); BossRadarUIInterface = new UserInterface(); BossRadarUIInterface.SetState(BossRadarUI); } /* * // Fix some translation keys automatically -- TODO * FieldInfo translationsField = typeof(Mod).GetField("translations", BindingFlags.Instance | BindingFlags.NonPublic); * var translations = (Dictionary<string, ModTranslation>)translationsField?.GetValue(this); * if (translations != null) { * foreach (var translation in translations) { * if (translation.Value.GetDefault().Contains("ItemID.")) { * ItemID.Search.GetId() * } * } * } */ if (!DebugConfig.ModCallLogVerbose) { Logger.Info("Boss Log integration messages will not be logged."); } }
private void OnLoad() { MainMenu(); AdvCallbacks.Init(_menu); var cdt = new CooldownTracker(_menu); var fT = new FoWTracker(_menu); var ga = new GankAlert(_menu); var rt = new RecallTracker(_menu); var bct = new BossTracker(_menu); var jct = new JungleCampTracker(_menu); var wt = new WardTracker(_menu); var aw = new AdditionalAwareness(_menu); }
public override void Unload() { instance = null; ToggleChecklistHotKey = null; bossChecklistInterface = null; bossTracker = null; ToggleBossLog = null; ServerCollectedRecords = null; BossRadarUIInterface = null; BossRadarUI.arrowTexture = null; ClientConfig = null; DebugConfig = null; BossLogConfig = null; UICheckbox.checkboxTexture = null; UICheckbox.checkmarkTexture = null; }