Ejemplo n.º 1
0
        public AutoHealsMenu(Menu rootMenu)
        {
            var menu = new Menu("HP/MP restore", "autoHealUsage");

            AutoBottleMenu      = new AutoBottleMenu(menu);
            AutoArcaneBootsMenu = new AutoArcaneBootsMenu(menu);
            AutoTangoMenu       = new AutoTangoMenu(menu);
            AutoMagicStickMenu  = new InstantHealthRestoreItemMenu(menu, "Magic stick");
            AutoCheeseMenu      = new InstantHealthRestoreItemMenu(menu, "Cheese");
            AutoFaerieFireMenu  = new InstantHealthRestoreItemMenu(menu, "Faerie fire", false);
            LivingArmorMenu     = new LivingArmorMenu(menu);
            rootMenu.AddSubMenu(menu);
        }
Ejemplo n.º 2
0
        public InstantHealthRestoreItem(Manager manager, MenuManager menu, AbilityId abilityId)
        {
            this.manager = manager;
            this.menu    = menu.AutoActionsMenu.AutoHealsMenu.GetMenuFor(abilityId);

            AbilityId = abilityId;
            Refresh();

            if (this.menu.IsEnabled)
            {
                Entity.OnInt32PropertyChange += OnInt32PropertyChange;
            }
            this.menu.OnEnabledChange += MenuOnEnabledChange;
        }