Example #1
0
        private void ButtonControl(WndEventArgs args)
        {
            ShowEasyButton = (KoreanUtils.GetParamBool(annie.MainMenu, "showeeasybutton"));

            if (ShowEasyButton)
            {
                if ((args.Msg == (uint)WindowsMessages.WM_LBUTTONUP) &&
                    (MouseOnButton(StunButtonOn) || MouseOnButton(StunButtonOff)))
                {
                    if (StunButtonOn.Visible)
                    {
                        KoreanUtils.SetValueBool(annie.MainMenu, "savestunforcombo", false);
                    }
                    else if (StunButtonOff.Visible)
                    {
                        KoreanUtils.SetValueBool(annie.MainMenu, "savestunforcombo", true);
                    }
                }
                else if ((args.Msg == (uint)WindowsMessages.WM_MOUSEMOVE) && (args.WParam == 5) &&
                         (MouseOnButton(StunButtonOn) || MouseOnButton(StunButtonOff)))
                {
                    MoveButtons(
                        new Vector2(Utils.GetCursorPos().X - (StunButtonOn.Width / 2), Utils.GetCursorPos().Y - 10));
                }

                StunButtonOn.Visible  = KoreanUtils.GetParamBool(annie.MainMenu, "savestunforcombo");
                StunButtonOff.Visible = !StunButtonOn.Visible;
            }
            else
            {
                StunButtonOff.Visible = false;
                StunButtonOn.Visible  = false;
            }
        }
Example #2
0
 private void LoadLambdaExpressions()
 {
     ParamName       = s => KoreanUtils.ParamName(MainMenu, s);
     GetParamBool    = s => KoreanUtils.GetParamBool(MainMenu, s);
     SetValueBool    = (s, b) => KoreanUtils.SetValueBool(MainMenu, s, b);
     GetParamSlider  = s => KoreanUtils.GetParamSlider(MainMenu, s);
     GetParamKeyBind = s => KoreanUtils.GetParamKeyBind(MainMenu, s);
     CanFarm         =
         () =>
         (!GetParamBool("supportmode")) ||
         ((GetParamBool("supportmode")) && (Player.CountAlliesInRange(1500f) == 1));
     CheckStun = () => Player.HasBuff("pyromania_particle");
     SaveStun  = () => (CheckStun() && (GetParamBool("savestunforcombo")));
 }