public void AddSkillshot(EvadeSkillshot skillshot, bool isProcessSpell = false, bool triggerEvent = true) { if (LimitDetectionRange && skillshot.GetPosition().Distance(Player.Instance, true) > (2 * skillshot.SpellData.Range).Pow()) { return; } if (SkillshotActivationDelay <= 10) { skillshot.IsActive = true; } DetectedSkillshots.Add(skillshot); if (triggerEvent && EvadeMenu.IsSkillshotEnabled(skillshot)) { if (OnSkillshotDetected != null) { OnSkillshotDetected(skillshot, isProcessSpell); } if (OnUpdateSkillshots != null) { OnUpdateSkillshots(skillshot, false, isProcessSpell); } } }
public static void Main(string[] args) { Loading.OnLoadingComplete += delegate { _skillshotDetector = new SkillshotDetector(); Evade = new EvadePlus(_skillshotDetector); EvadeMenu.CreateMenu(); }; }
private void OnDraw(EventArgs args) { foreach (var c in DetectedSkillshots) { if (EvadeMenu.IsSkillshotDrawingEnabled(c)) { c.OnDraw(); } } }
private void OnDraw(EventArgs args) { if (EvadeMenu.DrawMenu["disableAllDrawings"].Cast <CheckBox>().CurrentValue) { return; } foreach (var c in DetectedSkillshots) { if (EvadeMenu.IsSkillshotDrawingEnabled(c)) { c.OnDraw(); } } }
public List <Geometry.Polygon> CustomPoly() { Skillshots = (DodgeDangerousOnly ? SkillshotDetector.ActiveSkillshots.Where(c => c.SpellData.IsDangerous && EvadeMenu.IsSkillshotE(c) && Environment.TickCount - c.TimeDetected >= Yasuo.FleeMenu["Evade.WDelay"].Cast <Slider>().CurrentValue) : SkillshotDetector.ActiveSkillshots).ToArray(); _skillshotPolygonCache.Clear(); Polygons = Skillshots.Select(c => { var pol = c.ToPolygon(); _skillshotPolygonCache.Add(c, pol); return(pol); }).ToArray(); return(Geometry.ClipPolygons(Polygons).ToPolygons()); }