コード例 #1
0
        /// <summary>
        /// Called when the game updates itself.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs"/> instance containing the event data.</param>
        public static void Game_OnGameUpdate(EventArgs args)
        {
            if (!ObjectManager.Player.IsDead)
            {
                if (Variables.Menu.Item($"{Variables.MainMenuName}.defensives").GetValue <bool>())
                {
                    Defensives.Execute(args);
                }

                if (Variables.Menu.Item($"{Variables.MainMenuName}.spells").GetValue <bool>())
                {
                    Spells.Execute(args);
                }

                if (Variables.Menu.Item($"{Variables.MainMenuName}.cleansers").GetValue <bool>())
                {
                    Cleansers.Execute(args);
                }

                if (Variables.Menu.Item($"{Variables.MainMenuName}.consumables").GetValue <bool>())
                {
                    Consumables.Execute(args);
                }

                if (Variables.Menu.Item($"{Variables.MainMenuName}.combo_button").GetValue <KeyBind>().Active&&
                    Variables.Menu.Item($"{Variables.MainMenuName}.offensives").GetValue <bool>())
                {
                    Offensives.Execute(args);
                }
            }
        }
コード例 #2
0
ファイル: NabbActivator.cs プロジェクト: ShineSharp/ExoryREPO
        /// <summary>
        /// Called when the game updates itself.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs"/> instance containing the event data.</param>
        public static void OnUpdate(EventArgs args)
        {
            if (ObjectManager.Player.IsDead)
            {
                return;
            }

            /// <summary>
            /// Load the Defesive items.
            /// </summary>
            if (Variables.Menu.Item($"{Variables.MainMenuName}.defensives").GetValue <bool>())
            {
                Defensives.Execute(args);
            }

            /// <summary>
            /// Load the Spells.
            /// </summary>
            if (Variables.Menu.Item($"{Variables.MainMenuName}.spells").GetValue <bool>())
            {
                Spells.Execute(args);
            }

            /// <summary>
            /// Load the Cleanser items.
            /// </summary>
            if (Variables.Menu.Item($"{Variables.MainMenuName}.cleansers").GetValue <bool>())
            {
                Cleansers.Execute(args);
                SCleansers.Execute(args);
            }

            /// <summary>
            /// Load the Consumable items.
            /// </summary>
            if (Variables.Menu.Item($"{Variables.MainMenuName}.consumables").GetValue <bool>())
            {
                Consumables.Execute(args);
            }

            /// <summary>
            /// Load the Offensive items.
            /// </summary>
            if (Variables.Menu.Item($"{Variables.MainMenuName}.offensives").GetValue <bool>() &&
                (Variables.Menu.Item($"{Variables.MainMenuName}.combo_button").GetValue <KeyBind>().Active ||
                 Variables.Menu.Item($"{Variables.MainMenuName}.laneclear_button").GetValue <KeyBind>().Active))
            {
                Offensives.Execute(args);
            }
        }