private static void KillstealMode() { var invisibleEnemies = KSMenu.GetBoolean("ks.invisibleTargets"); var possibleEnemies = EntitiesManager.EnemyTeam.Where(x => x.IsValid && !x.Living.IsDead && !x.HasProjectileBlocker()); if (!invisibleEnemies) { possibleEnemies = possibleEnemies.Where(x => !x.CharacterModel.IsModelInvisible); } foreach (var enemy in possibleEnemies) { if (KSMenu.GetBoolean("ks.useEX1") && LastAbilityFired == null && enemy.Living.Health <= (TrueEX1Damage) && enemy.Distance(JadeHero) < M2Range && MiscUtils.CanCast(AbilitySlot.EXAbility1)) //EX1 { var testPred = TestPrediction.GetNormalLinePrediction(MyPos, enemy, M2Range, M2Speed, M2Radius, true); if (testPred.CanHit) { LocalPlayer.PressAbility(AbilitySlot.EXAbility1, true); } } if (KSMenu.GetBoolean("ks.useR") && LastAbilityFired == null && enemy.Living.Health <= 6f && enemy.Distance(JadeHero) < RRange && MiscUtils.CanCast(AbilitySlot.Ability6)) //R { var testPred = TestPrediction.GetNormalLinePrediction(MyPos, enemy, RRange, RSpeed, RRadius, true); if (testPred.CanHit) { LocalPlayer.PressAbility(AbilitySlot.Ability6, true); LocalPlayer.EditAimPosition = true; LocalPlayer.Aim(testPred.CastPosition); } } if (KSMenu.GetBoolean("ks.useR") && LastAbilityFired == null && enemy.Living.Health <= 6f * 3f && enemy.Distance(JadeHero) < 1.25f && MiscUtils.CanCast(AbilitySlot.Ability6)) //R { var testPred = TestPrediction.GetNormalLinePrediction(MyPos, enemy, RRange, RSpeed, RRadius, true); if (testPred.CanHit) { LocalPlayer.PressAbility(AbilitySlot.Ability6, true); LocalPlayer.EditAimPosition = true; LocalPlayer.Aim(testPred.CastPosition); } } } }