コード例 #1
0
        private void InitializeLater()
        {
            Window.AllowUserResizing  = true;
            Window.ClientSizeChanged += new System.EventHandler <System.EventArgs>(Window_ClientSizeChanged);

            renderTarget = new RenderTarget2D(GraphicsDevice, 1920, 1080);

            windowResX = renderTarget.Width / 2;
            windowResY = renderTarget.Height / 2;

            ContentLoader.Initialize(Content, GraphicsDevice, new Random());
            DrawM.Initialize(GraphicsDevice);
            spriteBatch = new SpriteBatch(GraphicsDevice);
            G.batch     = spriteBatch;
            Drawer.Initialize(spriteBatch);
            Input.Initialize();
            Rules.Initialize();
            Save.Initialize();
            RunningContent.LoadAll(GraphicsDevice);


            G.Initialize(new Int2(renderTarget.Width / samplingZoom, renderTarget.Height / samplingZoom), GraphicsDevice);


            //InitPatcher();

            inputRecorderManager = new InputRecorderManager();

            Restart(null);

            ToggleFullscreen();
        }
コード例 #2
0
ファイル: GameBase.cs プロジェクト: dhoeltge/BotChallenge
        public static void ToggleFullscreen()
        {
            isFullScreen = !isFullScreen;

            changeResolution = true;

            if (isFullScreen)
            {
                window.IsBorderless = true;
                window.Position     = new Point(0, 0);
                graphics.PreferredBackBufferWidth  = GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Width;  //System.Windows.Forms.Screen.PrimaryScreen.Bounds.Width;
                graphics.PreferredBackBufferHeight = GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Height; //System.Windows.Forms.Screen.PrimaryScreen.Bounds.Height;
                graphics.ApplyChanges();
            }
            else
            {
                window.IsBorderless = false;
                graphics.PreferredBackBufferWidth  = windowResX;
                graphics.PreferredBackBufferHeight = windowResY;
                graphics.ApplyChanges();

                CenterWindow();
            }

            changeResolution = false;

            DrawM.ResizeWindow();
        }
コード例 #3
0
 private static void DrawingsMenu()
 {
     DrawM = Menu.AddSubMenu("线圈", "draw");
     DrawM.Add("Q", new CheckBox("显示 Q 范围"));
     DrawM.Add("W", new CheckBox("显示 W 范围", false));
     DrawM.Add("WPos", new CheckBox("显示 W 位置", false));
     DrawM.Add("E", new CheckBox("显示 E 范围", false));
     DrawM.AddSeparator();
     DrawM.Add("line", new CheckBox("显示 线至可击杀目标"));
     DrawM.Add("dist", new Slider("最大线形距离", 1000, 500, 3000));
 }
コード例 #4
0
 private static void DrawingsMenu()
 {
     DrawM = Menu.AddSubMenu("Gösterge", "draw");
     DrawM.Add("Q", new CheckBox("Göster Q v"));
     DrawM.Add("W", new CheckBox("Göster W Menzili", false));
     DrawM.Add("WPos", new CheckBox("Göster W Pozisyonu", false));
     DrawM.Add("E", new CheckBox("Göster E Menzili", false));
     DrawM.AddSeparator();
     DrawM.Add("line", new CheckBox("Öldürülebilir hedef çizgisini göster"));
     DrawM.Add("dist", new Slider("en fazla çizgi mesafesi", 1000, 500, 3000));
 }
コード例 #5
0
 private static void DrawingsMenu()
 {
     DrawM = Menu.AddSubMenu("Drawings", "draw");
     DrawM.Add("Q", new CheckBox("Draw Q range"));
     DrawM.Add("W", new CheckBox("Draw W range", false));
     DrawM.Add("WPos", new CheckBox("Draw W Position", false));
     DrawM.Add("E", new CheckBox("Draw E range", false));
     DrawM.AddSeparator();
     DrawM.Add("line", new CheckBox("Draw line to killable target"));
     DrawM.Add("dist", new Slider("Max line distance", 1000, 500, 3000));
 }
コード例 #6
0
ファイル: GameBase.cs プロジェクト: dhoeltge/BotChallenge
        protected override void Initialize()
        {
            Window.AllowUserResizing  = true;
            Window.ClientSizeChanged += new System.EventHandler <System.EventArgs>(Window_ClientSizeChanged);

            CenterWindow();

            DrawM.Initialize(GraphicsDevice);
            Input.Initialize();

            base.Initialize();
        }
コード例 #7
0
ファイル: Ahri.cs プロジェクト: volder1/PortAIO
        public static void Ahri_Load()
        {
            if (EloBuddy.Player.Instance.ChampionName != "Ahri")
            {
                return;
            }

            Main = MainMenu.AddMenu("AhriSharp", "AhriSharp");

            ComboM = Main.AddSubMenu("Combo", "Combo");
            ComboM.Add("comboQ", new CheckBox("Use Q"));
            ComboM.Add("comboW", new CheckBox("Use W"));
            ComboM.Add("comboE", new CheckBox("Use E"));
            ComboM.Add("comboR", new CheckBox("Use R"));
            ComboM.Add("comboROnlyUserInitiate", new CheckBox("Use R only if user initiated", false));
            HarassM = Main.AddSubMenu("Harass", "Harass");
            HarassM.Add("harassQ", new CheckBox("Use Q"));
            HarassM.Add("harassE", new CheckBox("Use E"));
            HarassM.Add("harassPercent", new Slider("Skills until Mana %", 20, 0, 100));

            FarmM = Main.AddSubMenu("LaneClear", "Lane Clear");
            FarmM.Add("farmQ", new CheckBox("use  Q"));
            FarmM.Add("farmW", new CheckBox("Use W", false));
            FarmM.Add("farmPercent", new Slider("Skills until Mana %", 20, 0, 100));

            DrawM = Main.AddSubMenu("Draw", "Draws");
            DrawM.Add("drawQE", new CheckBox("Draw Q, E range"));
            DrawM.Add("drawW", new CheckBox("Draw W range"));
            DrawM.Add("DamageAfterCombo", new CheckBox("Draw Combo Damage"));

            Misc = Main.AddSubMenu("Misc", "Misc");
            Misc.Add("charmRange", new Slider("Only Charm if Target is in X distance from you : ", 1000, 100, 1000));
            Misc.Add("autoE", new CheckBox("Auto E on gapclosing targets"));
            Misc.Add("autoEI", new CheckBox("Auto E to interrupt"));


            _spellQ = new LeagueSharp.Common.Spell(EloBuddy.SpellSlot.Q, 1000);
            _spellW = new LeagueSharp.Common.Spell(EloBuddy.SpellSlot.W, 795 - 95);
            _spellE = new LeagueSharp.Common.Spell(EloBuddy.SpellSlot.E, 1000);
            _spellR = new LeagueSharp.Common.Spell(EloBuddy.SpellSlot.R, 1000 - 100);

            _spellQ.SetSkillshot(0.25f, 50, 1600f, false, LeagueSharp.Common.SkillshotType.SkillshotLine);
            _spellW.SetSkillshot(0.70f, _spellW.Range, float.MaxValue, false, LeagueSharp.Common.SkillshotType.SkillshotCircle);
            _spellE.SetSkillshot(0.25f, 60, 1550f, true, LeagueSharp.Common.SkillshotType.SkillshotLine);

            LeagueSharp.Common.Utility.HpBarDamageIndicator.DamageToUnit = GetComboDamage;
            LeagueSharp.Common.AntiGapcloser.OnEnemyGapcloser           += AntiGapcloser_OnEnemyGapcloser;
            LeagueSharp.Common.Interrupter2.OnInterruptableTarget       += Interrupter2_OnInterruptableTarget;
            EloBuddy.Drawing.OnEndScene += Drawing_OnDraw;
            EloBuddy.Game.OnUpdate      += Game_OnUpdate;
            Helper = new Helper();
        }
コード例 #8
0
        public void ToggleFullscreen()
        {
            isFullScreen = !isFullScreen;

            changeResolution = true;

            if (isFullScreen)
            {
                Rectangle screenRect = GetCurrentScreenRectangle();

                window.Position = screenRect.Location;
                //window.Position = new Point((((int)window.Position.X + window.ClientBounds.Width / 2) / 1920) * 1920, 0);

                Thread.Sleep(50);                                       // testing (maybe prevent fullscreen not working??)

                graphics.PreferredBackBufferWidth  = screenRect.Width;  //GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Width;//System.Windows.Forms.Screen.PrimaryScreen.Bounds.Width;
                graphics.PreferredBackBufferHeight = screenRect.Height; // GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Height;//System.Windows.Forms.Screen.PrimaryScreen.Bounds.Height;
                graphics.ApplyChanges();
#if DIRECTX
                window.IsBorderless = true;
#else
                graphics.ToggleFullScreen();
#endif
            }
            else
            {
#if DIRECTX
                window.IsBorderless = false;
#else
                graphics.ToggleFullScreen();
#endif
                graphics.PreferredBackBufferWidth  = windowResX;
                graphics.PreferredBackBufferHeight = windowResY;
                graphics.ApplyChanges();

                CenterWindow();
            }

            changeResolution = false;

            DrawM.ResizeWindow();
        }
コード例 #9
0
ファイル: GameBase.cs プロジェクト: dhoeltge/BotChallenge
        public void Window_ClientSizeChanged(object sender, EventArgs e)
        {
            if (!changeResolution)
            {
                changeResolution = true;

                graphics.PreferredBackBufferWidth  = Window.ClientBounds.Width;
                graphics.PreferredBackBufferHeight = Window.ClientBounds.Height;
                graphics.ApplyChanges();

                if (!isFullScreen)
                {
                    windowResX = resX;
                    windowResY = resY;
                }

                changeResolution = false;
            }

            DrawM.Initialize(graphics.GraphicsDevice);
        }
コード例 #10
0
ファイル: Game1.cs プロジェクト: bytinggames/LD48
        protected override void Initialize()
        {
            Window.IsBorderless = true;
            Window.Position     = new Point(0, 0);
            graphics.PreferredBackBufferWidth  = GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Width;
            graphics.PreferredBackBufferHeight = GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Height;

#if !WINDOWS
            graphics.IsFullScreen = true;
#endif
            graphics.ApplyChanges();

            Input.Initialize();
            DrawM.Initialize(GraphicsDevice);

            windowHelper = new WindowHelper(graphics, Window);

            G.Initialize(GraphicsDevice);

            this.IsFixedTimeStep   = true;
            this.TargetElapsedTime = TimeSpan.FromSeconds(1d / 60d);

            base.Initialize();
        }
コード例 #11
0
        private static void MenuLoad()
        {
            Menu = MainMenu.AddMenu("Ahri Buddy", "Ahri Buddy");

            HarassM = Menu.AddSubMenu("Harass", "Harass");
            HarassM.Add("Harass Q", new CheckBox("Use Q", true));
            HarassM.Add("Harass W", new CheckBox("Use W", false));
            HarassM.Add("Harass E", new CheckBox("Use E", true));

            AutoHarassM = Menu.AddSubMenu("Auto Harass", "Auto Harass");
            AutoHarassM.Add("Auto Harass Q", new CheckBox("Use Q", true));
            AutoHarassM.Add("Auto Harass W", new CheckBox("Use W", false));
            AutoHarassM.Add("Auto Harass E", new CheckBox("Use E", false));
            AutoHarassM.Add("Auto Harass Key", new KeyBind("Auto Harass Toggle Key", false, KeyBind.BindTypes.PressToggle, 'H'));

            LaneClearM = Menu.AddSubMenu("LaneClear", "LaneClear");
            LaneClearM.Add("LaneClear Q", new CheckBox("Use Q", true));
            LaneClearM.Add("LaneClear W", new CheckBox("Use W", false));
            LaneClearM.Add("LaneClear E", new CheckBox("Use E", false));
            LaneClearM.Add("LaneClearKey", new KeyBind("Lane Clear Toggle Key", false, KeyBind.BindTypes.PressToggle, 'L'));

            JungleClearM = Menu.AddSubMenu("JungleClear", "JungleClear");
            JungleClearM.Add("JungleClear Q", new CheckBox("Use Q", true));
            JungleClearM.Add("JungleClear W", new CheckBox("Use W", false));
            JungleClearM.Add("JungleClear E", new CheckBox("Use E", false));
            JungleClearM.Add("JungleClearKey", new KeyBind("Jungle Clear Toggle Key", false, KeyBind.BindTypes.PressToggle, 'J'));

            ComboM = Menu.AddSubMenu("Combo", "Combo");
            ComboM.Add("Combo Q", new CheckBox("Use Q", true));
            ComboM.Add("Combo W", new CheckBox("Use W", true));
            ComboM.Add("Combo E", new CheckBox("Use E", true));
            ComboM.Add("Combo Ignite", new CheckBox("Use Ignite", true));
            ComboM.Add("Combo Mode", new ComboBox("Combo Logic", 0, "Random", "E -> Q -> Random"));
            ComboM.Add("Combo R", new ComboBox("Combo R Mode(Mouse Pos)", 1, "Never", "Killble", "Always"));
            ComboM.Add("Combo EFlash", new KeyBind("Use E + Flash", false, KeyBind.BindTypes.HoldActive, 'G'));

            KillStealM = Menu.AddSubMenu("KillSteal", "KillSteal");
            KillStealM.Add("KillSteal Q", new CheckBox("Use Q", true));
            KillStealM.Add("KillSteal E", new CheckBox("Use E", true));

            MiscM = Menu.AddSubMenu("Misc", "Misc");
            MiscM.Add("Interrupter", new CheckBox("Auto Interrupter to Use E", true));
            MiscM.Add("gapcloser", new CheckBox("Auto Anti-gapcloser to Use E", true));
            //MiscM.Add("Assassin Manager", new Checkbox("Use Assassin Manager", true));

            FleeM = Menu.AddSubMenu("Flee", "Flee");
            FleeM.Add("Flee Q", new CheckBox("Use Q", true));
            FleeM.Add("Flee R", new CheckBox("Use R", false));

            SkinM = Menu.AddSubMenu("Skin Hack", "SKin Hack");
            SkinM.Add("Skin H onoff", new CheckBox("Skin Hack Off/ On", false));
            StringList(SkinM, "Skin H", "Skin Change", new[] { "Classic", "Dynasty", "Midnight", "Foxfire", "Popstar", "Challenger", "Academy" }, 0);

            DrawM = Menu.AddSubMenu("Draw", "Draw");
            DrawM.Add("Draw Q", new CheckBox("Use Q", false));
            DrawM.Add("Draw W", new CheckBox("Use W", false));
            DrawM.Add("Draw E", new CheckBox("Use E", false));
            DrawM.Add("Draw E Target", new CheckBox("Use E Target", true));
            DrawM.Add("Draw R", new CheckBox("Use R", false));
            DrawM.Add("Draw Damage", new CheckBox("Draw Damage Incidator", true));
        }
コード例 #12
0
ファイル: Menu.cs プロジェクト: chienhao10/CHOP
        public static void Init()
        {
            try
            {
                //Main Menu
                RengarMenu = MainMenu.AddMenu("RengarPro Revamped", "RengarProMenu");
                RengarMenu.AddGroupLabel("狮子狗!Meow~");
                RengarMenu.AddLabel("Its loaded. Have Fun ! :)");
                //Combo Menu
                ComboM = RengarMenu.AddSubMenu("连招");
                ComboM.AddGroupLabel("连招菜单");
                ComboM.AddLabel("1- 秒杀 | 2- 定身 | 3- AP 狮子狗");
                ComboM.Add("combo.mode", new Slider("连招模式", 1, 1, 3));
                var switcher = ComboM.Add("switch",
                                          new KeyBind("连招切换按键", false, KeyBind.BindTypes.HoldActive, 'T'));
                switcher.OnValueChange += delegate(ValueBase <bool> sender, ValueBase <bool> .ValueChangeArgs args1)
                {
                    if (args1.NewValue)
                    {
                        var cast = ComboM["combo.mode"].Cast <Slider>();
                        if (cast.CurrentValue == cast.MaxValue)
                        {
                            cast.CurrentValue = 0;
                        }
                        else
                        {
                            cast.CurrentValue++;
                        }
                    }
                };

                ComboM.Add("combo.useEoutofQ", new CheckBox("超出Q 范围使用 E"));
                ComboM.AddSeparator();
                ComboM.AddLabel("以下为推荐设置");
                ComboM.AddLabel("非脚本开发者请勿调整");
                ComboM.AddSeparator();
                ComboM.AddLabel("BetaQ => 激活大招前使用Q");
                ComboM.Add("betaq.active", new CheckBox("BetaQ 开启"));
                ComboM.Add("betaq.range", new Slider("Beta Q 范围", 875, 600, 1000));

                //Lane Clear Menu
                LaneM = RengarMenu.AddSubMenu("清线");
                LaneM.AddGroupLabel("清线设置");
                LaneM.Add("lane.useQ", new CheckBox("使用 Q"));
                LaneM.Add("lane.useW", new CheckBox("使用 W"));
                LaneM.Add("lane.useE", new CheckBox("使用 E"));
                LaneM.Add("lane.save", new CheckBox("保留叠加层数", false));

                //Jungle Clear Menu
                JungleM = RengarMenu.AddSubMenu("清野");
                JungleM.AddGroupLabel("清野设置");
                JungleM.Add("jungle.useQ", new CheckBox("使用 Q"));
                JungleM.Add("jungle.useW", new CheckBox("使用 W"));
                JungleM.Add("jungle.useE", new CheckBox("使用 E"));
                JungleM.Add("jungle.save", new CheckBox("保留叠加层数", false));

                //Draw  Menu
                DrawM = RengarMenu.AddSubMenu("线圈");
                DrawM.AddGroupLabel("线圈设置");
                DrawM.Add("draw.mode", new CheckBox("显示连招模式"));
                DrawM.Add("draw.selectedenemy", new CheckBox("显示所选敌人"));

                //Misc Menu
                MiscM = RengarMenu.AddSubMenu("杂项");
                MiscM.AddGroupLabel("杂项菜单");
                MiscM.Add("misc.autoyoumuu", new CheckBox("R时自动幽梦"));

                /*MiscM.Add("misc.magnet", new CheckBox("Enable Magnet"));
                 * MiscM.Add("magnet.range", new Slider("Magnet Range", 225, 100, 500));*/
                MiscM.Add("misc.smite", new CheckBox("连招使用惩戒"));
                MiscM.Add("misc.autohp", new CheckBox("自动激活回血"));
                MiscM.Add("misc.hp.value", new Slider("血量%", 30, 1));
                MiscM.AddLabel("1- HeadHunter 2- NightHunter 3- SSW");
                MiscM.Add("skin.active", new CheckBox("开启换肤"));
                MiscM.Add("skin.value", new Slider("皮肤", 1, 1, 3));
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #13
0
        public static void Init()
        {
            try
            {
                //Main Menu
                RengarMenu = MainMenu.AddMenu("RengarPro Revamped", "RengarProMenu");
                RengarMenu.AddGroupLabel("RengarPro Revamped");
                RengarMenu.AddLabel("Its loaded. Have Fun ! :)");
                //Combo Menu
                ComboM = RengarMenu.AddSubMenu("Combo");
                ComboM.AddGroupLabel("Combo Menu");
                ComboM.AddLabel("1- OneShot | 2- Snare | 3- AP Rengo");
                ComboM.Add("combo.mode", new Slider("Combo Mode", 1, 1, 3));
                var switcher = ComboM.Add("switch",
                                          new KeyBind("Combo Mode Switcher", false, KeyBind.BindTypes.HoldActive, 'T'));
                switcher.OnValueChange += delegate(ValueBase <bool> sender, ValueBase <bool> .ValueChangeArgs args1)
                {
                    if (args1.NewValue)
                    {
                        var cast = ComboM["combo.mode"].Cast <Slider>();
                        if (cast.CurrentValue == cast.MaxValue)
                        {
                            cast.CurrentValue = 0;
                        }
                        else
                        {
                            cast.CurrentValue++;
                        }
                    }
                };

                ComboM.Add("combo.useEoutofQ", new CheckBox("Use E out Q Range"));
                ComboM.AddSeparator();
                ComboM.AddLabel("The settings on the bottom are the recommended settings");
                ComboM.AddLabel("I suggest dont change settings, if you are not a developer");
                ComboM.AddSeparator();
                ComboM.AddLabel("BetaQ => Its Cast Your Q before jump when ulti activated");
                ComboM.Add("betaq.active", new CheckBox("BetaQ Active"));
                ComboM.Add("betaq.range", new Slider("Beta Q Range", 875, 600, 1000));

                //Lane Clear Menu
                LaneM = RengarMenu.AddSubMenu("Lane Clear");
                LaneM.AddGroupLabel("Lane Clear Settings");
                LaneM.Add("lane.useQ", new CheckBox("Use Q"));
                LaneM.Add("lane.useW", new CheckBox("Use W"));
                LaneM.Add("lane.useE", new CheckBox("Use E"));
                LaneM.Add("lane.save", new CheckBox("Save Stacks", false));

                //Jungle Clear Menu
                JungleM = RengarMenu.AddSubMenu("Jungle Clear");
                JungleM.AddGroupLabel("Jungle Clear Settings");
                JungleM.Add("jungle.useQ", new CheckBox("Use Q"));
                JungleM.Add("jungle.useW", new CheckBox("Use W"));
                JungleM.Add("jungle.useE", new CheckBox("Use E"));
                JungleM.Add("jungle.save", new CheckBox("Save Stacks", false));

                //Draw  Menu
                DrawM = RengarMenu.AddSubMenu("Draw");
                DrawM.AddGroupLabel("Draw Settings");
                DrawM.Add("draw.mode", new CheckBox("Draw Combo Mode"));
                DrawM.Add("draw.selectedenemy", new CheckBox("Draw Selected Enemy"));

                //Misc Menu
                MiscM = RengarMenu.AddSubMenu("Misc");
                MiscM.AddGroupLabel("Misc Menu");
                MiscM.Add("misc.autoyoumuu", new CheckBox("Auto Youmuu when Ulti"));

                /*MiscM.Add("misc.magnet", new CheckBox("Enable Magnet"));
                 * MiscM.Add("magnet.range", new Slider("Magnet Range", 225, 100, 500));*/
                MiscM.Add("misc.smite", new CheckBox("Use Smite On Combo"));
                MiscM.Add("misc.autohp", new CheckBox("Auto HP Active"));
                MiscM.Add("misc.hp.value", new Slider("Auto HP %", 30, 1));
                MiscM.AddLabel("1- HeadHunter 2- NightHunter 3- SSW");
                MiscM.Add("skin.active", new CheckBox("Enable Skin Hack"));
                MiscM.Add("skin.value", new Slider("Skin Hack Value", 1, 1, 3));
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }