Пример #1
0
        /// <summary>
        /// Initializes Prediction Services
        /// </summary>
        public static void Initialize(Menu mainMenu, string prefMenuName = "SPRED")
        {
            if (blInitialized)
            {
                throw new Exception("SPrediction Already Initialized");
            }

            PathTracker.Initialize();
            StasisPrediction.Initialize();
            ConfigMenu.Initialize(mainMenu, prefMenuName);
            Drawings.Initialize();

            blInitialized = true;
        }
Пример #2
0
        public Prediction()
        {
            Program.Menu = new Menu("SPrediction", "SPrediction", true)
            {
                new MenuBool("SPREDWINDUP", "Check for target AA Windup", false),
                new MenuSlider("SPREDMAXRANGEIGNORE", "Max Range Dodge Ignore (%)", 50),
                new MenuSlider("SPREDREACTIONDELAY", "Ignore Rection Delay", 0, 0, 200),
                new MenuSlider("SPREDDELAY", "Spell Delay", 0, 0, 200),
                new MenuBool("SPREDDRAWINGS", "Enable Drawings", false)
            };
            Program.Menu.Attach();

            PathTracker.Initialize();
            StasisPrediction.Initialize();
        }
Пример #3
0
        /// <summary>
        /// Initializes Prediction Services
        /// </summary>
        public static void Initialize(Menu mainMenu)
        {
            if (mainMenu == null)
            {
                throw new NullReferenceException("Menu cannot be null!");
            }

            PathTracker.Initialize();
            Collision.Initialize();
            StasisPrediction.Initialize();
            ConfigMenu.Initialize(mainMenu);
            Drawings.Initialize();

            blInitialized = true;
        }
Пример #4
0
        /// <summary>
        /// Initializes Prediction Services
        /// </summary>
        public static void Initialize(Menu mainMenu, string prefMenuName = "SPRED")
        {
            if (blInitialized)
            {
                Console.WriteLine("SPrediction Already Initialized");
                return;
            }

            PathTracker.Initialize();
            Collision.Initialize();
            StasisPrediction.Initialize();
            ConfigMenu.Initialize(mainMenu, prefMenuName);
            Drawings.Initialize();

            blInitialized = true;
        }
Пример #5
0
        public static void Initialize()
        {
            try
            {
                PathTracker.Initialize();
                Collision.Initialize();
                StasisPrediction.Initialize();
                ConfigMenu.Initialize();
                Drawings.Initialize();

                blInitialized = true;
            }
            catch
            {
                Menu m = MainMenu.AddMenu("SPrediction", "SPREDX");
                m.Add("PREDICTONLIST", new Slider("Prediction Method (0 : SPrediction | 1 : EB/Common Prediction)", 0, 0, 1));
            }
        }
Пример #6
0
        public static Menu Initialize()
        {
            if (blInitialized)
            {
                throw new Exception("SPrediction Already Initialized");
            }

            PathTracker.Initialize();
            Collision.Initialize();
            StasisPrediction.Initialize();
            Menu spredMenu = ConfigMenu.Initialize();

            Drawings.Initialize();

            blInitialized = true;

            return(spredMenu);
        }
Пример #7
0
        /// <summary>
        ///     Initializes Prediction Services
        /// </summary>
        public static void Initialize(Menu mainMenu, string prefMenuName = "SPRED")
        {
            if (blInitialized)
            {
                throw new Exception("SPrediction Already Initialized");
            }

            if (mainMenu == null)
            {
                throw new NullReferenceException("Menu cannot be null!");
            }

            PathTracker.Initialize();
            Collision.Initialize();
            StasisPrediction.Initialize();
            ConfigMenu.Initialize(prefMenuName);
            Drawings.Initialize();

            blInitialized = true;
        }
Пример #8
0
        public static Menu Initialize()
        {
            try
            {
                PathTracker.Initialize();
                Collision.Initialize();
                StasisPrediction.Initialize();
                Menu spredMenu = ConfigMenu.Initialize();
                Drawings.Initialize();

                blInitialized = true;
                return(spredMenu);
            }
            catch
            {
                Menu m = new Menu("SPrediction", "SPREDX");
                m.AddItem(new MenuItem("PREDICTONLIST", "Prediction Method").SetValue(new StringList(new[] { "SPrediction", "Common Prediction" }, 1)));
                return(m);
            }
        }
Пример #9
0
        public static Menu Initialize()
        {
            try
            {
                PathTracker.Initialize();
                StasisPrediction.Initialize();
                Menu spredMenu = ConfigMenu.Initialize();
                Drawings.Initialize();

                blInitialized = true;
                return(spredMenu);
            }
            catch
            {
                Menu m = new Menu("SPREDX", "SPrediction");
                m.Add(new MenuList <string>("PREDICTONLIST", "Prediction Method", new[] { "SPrediction", "Common Prediction" })
                {
                    Index = 1
                });
                return(m);
            }
        }
Пример #10
0
 /// <summary>
 /// Unregisters spell callback from stasis prediction
 /// </summary>
 /// <param name="s">The spell.</param>
 /// <param name="fn">The eventhandler.</param>
 public static void UnregisterStasisCallback(this Spell s, EventHandler <StasisPrediction.Result> fn)
 {
     StasisPrediction.UnregisterSpell(s);
     StasisPrediction.OnGuaranteedHit -= fn;
 }
Пример #11
0
 /// <summary>
 /// Registers spell callback to stasis prediction
 /// </summary>
 /// <param name="s">The spell.</param>
 /// <param name="fn">The eventhandler.</param>
 public static void RegisterStasisCallback(this LeagueSharp.Common.Spell s, EventHandler <StasisPrediction.Result> fn)
 {
     StasisPrediction.RegisterSpell(s);
     StasisPrediction.OnGuaranteedHit += fn;
 }