예제 #1
0
        public override void Load()
        {
            instance = this;
            // Hotkeys
            Hotkeys.DepositAll    = RegisterHotKey("Deposit All", "");
            Hotkeys.LootAll       = RegisterHotKey("Loot All", "");
            Hotkeys.QuickStack    = RegisterHotKey("Quick Stack", "");
            Hotkeys.Restock       = RegisterHotKey("Restock", "");
            Hotkeys.SortChest     = RegisterHotKey("Sort Chest", "");
            Hotkeys.SortInventory = RegisterHotKey("Sort Inventory", "");

            if (!Main.dedServ)
            {
                SortUserInterface = new UserInterface();
                SortUserInterface.SetState(new SortOptionsUI());

                ConfirmationUserInterface = new UserInterface();
                ConfirmationUserInterface.SetState(new ConfirmationUI());

                ChestHoverUserInterface = new UserInterface();
                ChestHoverUserInterface.SetState(new ChestHoverUI());
            }

            ILEdits.Load();
        }
예제 #2
0
        public override void Unload()
        {
            instance = null;

            SortUserInterface         = null;
            ConfirmationUserInterface = null;
            ChestHoverUserInterface   = null;
            ChestHoverUI.chest        = null;

            // Hotkeys
            Hotkeys.DepositAll    = null;
            Hotkeys.LootAll       = null;
            Hotkeys.QuickStack    = null;
            Hotkeys.Restock       = null;
            Hotkeys.SortChest     = null;
            Hotkeys.SortInventory = null;

            base.Unload();
        }