Inheritance: MonoBehaviour
Exemplo n.º 1
0
 public GunnerSpell(int e_d, int s_r, int s_a, Spell.TYPE t)
 {
     effect_damage = e_d;
     spell_range = s_r;
     spell_area = s_a;
     type = t;
 }
Exemplo n.º 2
0
        private GamePlayer EffectOwner;			// Owner of the effect

        public MinionRescueEffect()
            : base(RealmAbilities.MinionRescueAbility.DURATION)
        {
            // Init NPC & Timer array
            spirits = new GameNPC[spiritCount];
            spiritTimer = new RegionTimer[spiritCount];

            // Build spell
            DBSpell tSpell = new DBSpell();
            tSpell.AllowAdd = false;
            tSpell.Description = "Target is stunned and can't move or do any action during spell duration.";
            tSpell.Name = "Rescue stun";
            tSpell.Target = "Enemy";
            tSpell.Radius = 0;
            tSpell.Range = WorldMgr.VISIBILITY_DISTANCE;
            tSpell.CastTime = 0;
            tSpell.Duration = spellDuration;
            tSpell.Uninterruptible = true;
            tSpell.Type = "Stun";
            tSpell.ResurrectMana = 1;
            tSpell.ResurrectHealth = 1;
            tSpell.Damage = 0;
            tSpell.DamageType = 0;
            tSpell.Value = 0;
            tSpell.Icon = 7049;
            tSpell.ClientEffect = 7049;
            spiritSpell = new Spell(tSpell, 1);
            spiritSpellLine = new SpellLine("RAs", "RealmAbilitys", "RealmAbilitys", true);
        }
Exemplo n.º 3
0
		public SpellForm(XmlNode node)
		{
			InitializeComponent();



			#region 

			RangeBox.BeginUpdate();
			RangeBox.Items.Clear();
			foreach (string name in Enum.GetNames(typeof(SpellRange)))
				RangeBox.Items.Add(name);
			RangeBox.EndUpdate();
			#endregion




			Spell spell = new Spell();
			spell.Load(node);

			RangeBox.SelectedItem = spell.Range.ToString();
			DescriptionBox.Text = spell.Description;
			DurationBox.Value = (int) spell.Duration.TotalSeconds;
			CastingTimeBox.Value = (int) spell.CastingTime.TotalSeconds;
			LevelBox.Value = (int) spell.Level;
			ScriptBox.SetValues<ISpell>(spell.Script);
			ClassBox.SelectedItem = spell.Class.ToString();

			Spell = spell;
		}
Exemplo n.º 4
0
    public IEnumerator SpellCast(Spell spell)
    {
        //If not out of mana.
        if (spell.spellManaCost <= Player.Instance.mana)
        {
            SkillsUI.Instance.disableSkill(1);// TMP TEMPORAL
            castingSpell = true;
            Player.Instance.mana -= spell.spellManaCost;

            //Wait for choosen spell cast time.
            Player.Instance.anim.SetBool("InvokeSpell", true);
            yield return new WaitForSeconds(spell.spellCastTime);

            Player.Instance.anim.SetTrigger("SpellNormalAttack");
            Player.Instance.anim.SetBool("InvokeSpell", false);

            //Set up a spell and cast it.
            SpellSetUp(spell);

            SkillsUI.Instance.enableSkill(1);// TMP TEMPORAL
        }

        castingSpell = false;
        yield break;
    }
Exemplo n.º 5
0
    protected static Spell AddSpell(   string name, string description, string icon, int mana, 
                                int damage, int purchase, int upgrade,
                                bool arcane, int requirement,
                                Spell.CastSpellCallback effector)
    {
        Spell spell = new Spell(arcane);
        spell.Name = name;
        spell.IconImage = icon;
        spell.Description = description;
        spell.MagicCost = mana;
        spell.Damage = damage;
        spell.CastSpell = effector;
        spell.Purchase = purchase;
        spell.Upgrade = upgrade;
        spell.MaxLevel = 5;
        spell.Range = 10;
        spell.Requirements.Add((arcane ? "Arcane " : "Divine ") + requirement.ToString());

        spell.SkillType = Skill.SkillTypes.Spell;

        spell.AnimType = Skill.ActiveAnimationTypes.Casting;

        spell.SpellEffect = CharacterObject.HitType.GenericSpell;

        Spells.Add(spell.Name, spell);
        return spell;
    }
Exemplo n.º 6
0
 public RandomEffectAreaSpell(Spell spell, BaseCombatant holder)
     : base(spell, holder)
 {
     Timer = new Timer();
     CurrentEffectCount = 0;
     IsEnding = false;
 }
		/// <summary>
		/// FIXME this has nothing to do here !
		/// </summary>
		/// <param name="line"></param>
		/// <param name="spell"></param>
		/// <returns></returns>
		public override bool CanChangeCastingSpeed(SpellLine line, Spell spell)
		{
			if (spell.SpellType == "Chamber")
				return false;

			if ((line.KeyName == "Cursing"
				 || line.KeyName == "Cursing Spec"
				 || line.KeyName == "Hexing"
				 || line.KeyName == "Witchcraft")
				&& (spell.SpellType != "ArmorFactorBuff"
					&& spell.SpellType != "Bladeturn"
					&& spell.SpellType != "ArmorAbsorptionBuff"
					&& spell.SpellType != "MatterResistDebuff"
					&& spell.SpellType != "Uninterruptable"
					&& spell.SpellType != "Powerless"
					&& spell.SpellType != "Range"
					&& spell.Name != "Lesser Twisting Curse"
					&& spell.Name != "Twisting Curse"
					&& spell.Name != "Lesser Winding Curse"
					&& spell.Name != "Winding Curse"
					&& spell.Name != "Lesser Wrenching Curse"
					&& spell.Name != "Wrenching Curse"
					&& spell.Name != "Lesser Warping Curse"
					&& spell.Name != "Warping Curse"))
			{
				return false;
			}

			return true;
		}
Exemplo n.º 8
0
        public MagicInfo (BinaryReader reader, int version = int.MaxValue, int Customversion = int.MaxValue)
        {
            Name = reader.ReadString();
            Spell = (Spell)reader.ReadByte();
            BaseCost = reader.ReadByte();
            LevelCost = reader.ReadByte();
            Icon = reader.ReadByte();
            Level1 = reader.ReadByte();
            Level2 = reader.ReadByte();
            Level3 = reader.ReadByte();
            Need1 = reader.ReadUInt16();
            Need2 = reader.ReadUInt16();
            Need3 = reader.ReadUInt16();
            DelayBase = reader.ReadUInt32();
            DelayReduction = reader.ReadUInt32();
            PowerBase = reader.ReadUInt16();
            PowerBonus = reader.ReadUInt16();
            MPowerBase = reader.ReadUInt16();
            MPowerBonus = reader.ReadUInt16();

            if (version > 66)
                Range = reader.ReadByte();
            if (version > 70)
            {
                MultiplierBase = reader.ReadSingle();
                MultiplierBonus = reader.ReadSingle();
            }
        }
Exemplo n.º 9
0
        private int currentTick = 0;		// Count ticks

        public SearingPetEffect(GamePlayer owner)
            : base(RealmAbilities.SearingPetAbility.DURATION)
        {
            EffectOwner = owner;

            // Build spell
            DBSpell tSpell = new DBSpell();
            tSpell.AllowAdd = false;
            tSpell.Description = "Damage the target.";
            tSpell.Name = "PBAoE damage";
            tSpell.Target = "Enemy";
            tSpell.Radius = 0;
            tSpell.Range = WorldMgr.VISIBILITY_DISTANCE;
            tSpell.CastTime = 0;
            tSpell.Duration = 0;
            tSpell.Frequency = 0;
            tSpell.Pulse = 0;
            tSpell.Uninterruptible = true;
            tSpell.Type = "DirectDamage";
            tSpell.Damage = spellDamage;
            tSpell.DamageType = (int)eDamageType.Heat;
            tSpell.Value = 0;
            tSpell.Icon = 476;			// not official effect
            tSpell.ClientEffect = 476;	// not official effect
            petSpell = new Spell(tSpell, 1);
            petSpellLine = new SpellLine("RAs", "RealmAbilitys", "RealmAbilitys", true);
        }
Exemplo n.º 10
0
        public void LoadOKTW()
        {
            Q = new Spell(SpellSlot.Q);
            E = new Spell(SpellSlot.E);
            W = new Spell(SpellSlot.W);
            R = new Spell(SpellSlot.R);

            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("AutoWard", "Auto Ward").SetValue(true));
            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("autoBuy", "Auto buy blue trinket after lvl 6").SetValue(false));
            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("AutoWardBlue", "Auto Blue Trinket").SetValue(true));
            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("AutoWardCombo", "Only combo mode").SetValue(true));
            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("AutoWardPink", "Auto VisionWard, OracleLens").SetValue(true));

            foreach (var hero in ObjectManager.Get<Obj_AI_Hero>())
            {
                if (hero.IsEnemy)
                {
                    if (hero.ChampionName == "Rengar")
                        rengar = true;
                    if (hero.ChampionName == "Vayne")
                        Vayne = hero;
                }
            }
            
            Game.OnUpdate += Game_OnUpdate;
            Obj_AI_Base.OnProcessSpellCast += Obj_AI_Base_OnProcessSpellCast;
            GameObject.OnCreate +=GameObject_OnCreate;
            GameObject.OnDelete += GameObject_OnDelete;
        }
Exemplo n.º 11
0
        public static PositionInfo InitPositionInfo(Vector2 pos, float extraDelayBuffer, float extraEvadeDistance, Vector2 lastMovePos, Spell lowestEvadeTimeSpell) //clean this shit up
        {
            var extraDist = Evade.menu.SubMenu("MiscSettings").SubMenu("ExtraBuffers").Item("ExtraCPADistance").GetValue<Slider>().Value;

            var posInfo = canHeroWalkToPos(pos, myHero.MoveSpeed, extraDelayBuffer + Game.Ping, extraDist);
            posInfo.isDangerousPos = CheckDangerousPos(pos, 6);
            posInfo.hasExtraDistance = extraEvadeDistance > 0 ? CheckDangerousPos(pos, extraEvadeDistance) : false;// ? 1 : 0;            
            posInfo.closestDistance = posInfo.distanceToMouse;
            posInfo.intersectionTime = GetIntersectTime(lowestEvadeTimeSpell, myHero.ServerPosition.To2D(), pos);
            posInfo.distanceToMouse = pos.Distance(lastMovePos);
            posInfo.posDistToChamps = GetDistanceToChampions(pos);

            if (Evade.menu.SubMenu("MiscSettings").SubMenu("FastEvade").Item("RejectMinDistance").GetValue<Slider>().Value > 0
            && Evade.menu.SubMenu("MiscSettings").SubMenu("FastEvade").Item("RejectMinDistance").GetValue<Slider>().Value >
                posInfo.closestDistance) //reject closestdistance
            {
                posInfo.rejectPosition = true;
            }

            if (Evade.menu.SubMenu("MiscSettings").SubMenu("ExtraBuffers").Item("MinComfortZone").GetValue<Slider>().Value >
                posInfo.posDistToChamps)
            {
                posInfo.hasComfortZone = false;
            }

            return posInfo;
        }
Exemplo n.º 12
0
	public static TileGroup GetAttackRange(Unit caster, Spell spell)
	{
		List<Tile> AttackRange = new List<Tile>();
		AttackRange.Add(caster.CurrentTile);

		for (int ii = spell.MaxRange; ii > 0; ii--)
		{
			for (int jj = AttackRange.Count - 1; jj >= 0; jj--)
			{
				Tile rootTile = AttackRange[jj];
				foreach (Tile curTile in rootTile.NeighboringTiles.Tiles)
				{
					if (!AttackRange.Contains(curTile))
					{
						AttackRange.Add(curTile);
					}
				}
			}
		}

		for (int ii = AttackRange.Count - 1; ii >= 0; ii--)
		{
			if(Knowledge.NaiveDistance(caster.CurrentTile, AttackRange[ii]) < spell.MinRange)
			{
				AttackRange.RemoveAt(ii);
			}
		}

		return new TileGroup(AttackRange);
	}
Exemplo n.º 13
0
 public SpellState(Spell spellToTrack, byte priority)
 {
     TrackedSpell = spellToTrack;
     _Cooldown = 0M;
     _ActiveOnTarget = 0M;
     Priority = priority;
 }
Exemplo n.º 14
0
      private static void OnGameLoad(EventArgs args)
        {

            if (Player.ChampionName != "Riven") return;
            Game.PrintChat("Hoola Riven - Loaded Successfully, Good Luck! :):)");
            Q = new Spell(SpellSlot.Q);
            W = new Spell(SpellSlot.W);
            E = new Spell(SpellSlot.E, 300);
            R = new Spell(SpellSlot.R, 900);
            R.SetSkillshot(0.25f, 45, 1600, false, SkillshotType.SkillshotCone);

            OnMenuLoad();


            Timer = new Render.Text("Q Expiry =>  " + ((double)(LastQ - Utils.GameTimeTickCount + 3800) / 1000).ToString("0.0"), (int)Drawing.WorldToScreen(Player.Position).X - 140, (int)Drawing.WorldToScreen(Player.Position).Y + 10, 30, Color.MidnightBlue, "calibri");
            Timer2 = new Render.Text("R Expiry =>  " + (((double)LastR - Utils.GameTimeTickCount + 15000) / 1000).ToString("0.0"), (int)Drawing.WorldToScreen(Player.Position).X - 60, (int)Drawing.WorldToScreen(Player.Position).Y + 10, 30, Color.IndianRed, "calibri");

            Game.OnUpdate += OnTick;
            Drawing.OnDraw += Drawing_OnDraw;
            Drawing.OnEndScene += Drawing_OnEndScene;
            Obj_AI_Base.OnProcessSpellCast += OnCast;
            Obj_AI_Base.OnDoCast += OnDoCast;
            Obj_AI_Base.OnDoCast += OnDoCastLC;
            Obj_AI_Base.OnPlayAnimation += OnPlay;
            Obj_AI_Base.OnProcessSpellCast += OnCasting;
            Interrupter2.OnInterruptableTarget += Interrupt;
        }
Exemplo n.º 15
0
		protected override void Apply()
		{
			var channel = m_aura.Controller as SpellChannel;
			SpellCast origCast = null;
			if (spell == null)
			{
				if (channel != null)
				{
					origCast = channel.Cast;
				}
				else
				{
					origCast = m_aura.Auras.Owner.SpellCast;
				}

				spell = m_spellEffect.TriggerSpell;
				if (spell == null)
				{
					LogManager.GetCurrentClassLogger().Warn("Found invalid periodic TriggerSpell in Spell {0} ({1}) ",
						m_aura.Spell, 
						(uint)m_spellEffect.TriggerSpellId);
					return;
				}
			}

			SpellCast.ValidateAndTriggerNew(spell, m_aura.CasterReference, Owner, Owner, channel, origCast != null ? origCast.UsedItem : null,
				null, m_spellEffect);
		}
Exemplo n.º 16
0
    public static void RewardSpell(Spell _SpellProc, float _Reward)
    {
        if(_SpellProc.Category == "Ice")
        {
            Character.GiveExpToSkill(Character.SkillList[(int)SkillName.IceMage],_Reward/Mathf.Pow (Character.SkillList[(int)SkillName.IceMage].Level,1.50f));
        }
        else if(_SpellProc.Category == "Fire")
        {
            Character.GiveExpToSkill(Character.SkillList[(int)SkillName.FireMage],_Reward/Mathf.Pow (Character.SkillList[(int)SkillName.FireMage].Level,1.50f));
        }

        switch(_compToLevelOnSpell)
        {
            case "Damage":
                _SpellProc.DamageCurExp += _Reward/Mathf.Pow(_SpellProc.DamageLevel + 1 ,2);
                if(_SpellProc.DamageCurExp >= 100.0f) {_SpellProc.DamageCurExp -= 100.0f; _SpellProc.DamageLevel++;}
                break;
            case "Cd":
                _SpellProc.CdCurExp += _Reward/Mathf.Pow(_SpellProc.CdLevel + 1,2);
                if(_SpellProc.CdCurExp >= 100.0f) {_SpellProc.CdCurExp -= 100.0f; _SpellProc.CdLevel++;}
                break;
            case "Mana":
                _SpellProc.ManaCurExp += _Reward/Mathf.Pow(_SpellProc.ManaLevel + 1,2);
                if(_SpellProc.ManaCurExp >= 100.0f) {_SpellProc.ManaCurExp -= 100.0f; _SpellProc.ManaLevel++;}
                break;
        }
        UpdateSpellStats();
    }
 void SelectMask(Spell sp)
 {
     v0.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 0)) == 0 ? false : true;
     v1.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 1)) == 0 ? false : true;
     v2.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 2)) == 0 ? false : true;
     v3.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 3)) == 0 ? false : true;
     v4.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 4)) == 0 ? false : true;
     v5.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 5)) == 0 ? false : true;
     v6.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 6)) == 0 ? false : true;
     v7.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 7)) == 0 ? false : true;
     v8.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 8)) == 0 ? false : true;
     v9.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 9)) == 0 ? false : true;
     v10.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 10)) == 0 ? false : true;
     v11.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 11)) == 0 ? false : true;
     v12.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 12)) == 0 ? false : true;
     v13.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 13)) == 0 ? false : true;
     v14.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 14)) == 0 ? false : true;
     v15.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 15)) == 0 ? false : true;
     v16.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 16)) == 0 ? false : true;
     v17.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 17)) == 0 ? false : true;
     v18.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 18)) == 0 ? false : true;
     v19.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 19)) == 0 ? false : true;
     v20.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 20)) == 0 ? false : true;
     v21.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 21)) == 0 ? false : true;
     v22.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 22)) == 0 ? false : true;
     v23.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 23)) == 0 ? false : true;
     v24.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 24)) == 0 ? false : true;
     v25.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 25)) == 0 ? false : true;
     v26.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 26)) == 0 ? false : true;
     v27.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 27)) == 0 ? false : true;
     v28.IsChecked = (sp.EquippedItemInventoryTypeMask & (1 << 28)) == 0 ? false : true;
 }
Exemplo n.º 18
0
 public static void CastE(Spell.Skillshot E, Obj_AI_Base target)
 {
     var pred = E.GetPrediction(target);
     if (Config.EHitChance == 3)
     {
         if (pred.HitChance >= HitChance.High)
         {
             E.Cast(target);
         }
         return;
     }
     if (Config.EHitChance == 2)
     {
         if (pred.HitChance >= HitChance.AveragePoint)
         {
             E.Cast(target);
         }
         return;
     }
     if (Config.EHitChance == 1)
     {
         if (pred.HitChance >= HitChance.Medium)
         {
             E.Cast(target);
             return;
         }
     }
     if (Config.EHitChance == 0)
     {
         if (pred.HitChance >= HitChance.Low)
         {
             E.Cast(target);
         }
     }
 }
Exemplo n.º 19
0
        public void Load(S.ObjectSpell info)
        {
            CurrentLocation = info.Location;
            MapLocation = info.Location;
            GameScene.Scene.MapControl.AddObject(this);
            Spell = info.Spell;

            switch (Spell)
            {
                case Spell.TrapHexagon:
                    BodyLibrary = Libraries.Magic;
                    DrawFrame = 1390;
                    FrameInterval = 100;
                    FrameCount = 10;
                    break;
                case Spell.FireWall:
                    BodyLibrary = Libraries.Magic;
                    DrawFrame = 1630;
                    FrameInterval = 120;
                    FrameCount = 6;
                    Light = 3;
                    break;
                case Spell.PoisonField:
                    BodyLibrary = Libraries.Magic2;
                    DrawFrame = 1650;
                    FrameInterval = 120;
                    FrameCount = 20;
                    Light = 3;
                    break;
            }

            NextMotion = CMain.Time + FrameInterval;
            NextMotion -= NextMotion % 100;
        }
    public override void Do(Mage caster, Spell origin_spell)
    {
        SEDispelOldestSlot dispel = Instantiate(this);
        dispel.StartCoroutine(dispel.UpdateDispel(caster));

        base.Do(caster, origin_spell);
    }
Exemplo n.º 21
0
        /// <summary>
        /// Uses MEC to get the perfect position on Circle Skillshots
        /// </summary>
        /// <param name="spell">Give it a spell and it will do the rest of the logic for you</param>
        /// <param name="targetHero">If you give it a target it will look around that target for other targets but will always focus that target</param>
        /// <returns></returns>
        internal static OptimizedLocation? GetOptimizedCircleLocation(Spell.Skillshot spell,
            AIHeroClient targetHero = null)
        {
            if (targetHero != null)
            {
                if (!targetHero.IsValidTarget(spell.Range + spell.Radius))
                    return null;

                var champs =
                    EntityManager.Heroes.Enemies.Where(e => e.Distance(targetHero) < spell.Radius)
                        .Select(
                            champ =>
                                Prediction.Position.PredictUnitPosition(champ,
                                    ((int)Player.Instance.Distance(champ) / spell.Speed) + spell.CastDelay))
                        .ToList();
                return GetOptimizedCircleLocation(champs, spell.Width, spell.Range);
            }
            if (EntityManager.Heroes.Enemies.Any(e => e.Distance(Player.Instance) < spell.Radius + spell.Range))
            {
                var champs =
                    EntityManager.Heroes.Enemies.Where(e => e.Distance(Player.Instance) < spell.Radius + spell.Range)
                        .Select(
                            champ =>
                                Prediction.Position.PredictUnitPosition(champ,
                                    ((int)Player.Instance.Distance(champ) / spell.Speed) + spell.CastDelay)).ToList();

                return GetOptimizedCircleLocation(champs, spell.Width, spell.Range);
            }
            return null;
        }
Exemplo n.º 22
0
 // constructor
 public CureMezzSpellHandler(GameLiving caster, Spell spell, SpellLine line)
     : base(caster, spell, line)
 {
     // RR4: now it's a list
     m_spellTypesToRemove = new List<string>();
     m_spellTypesToRemove.Add("Mesmerize");
 }
Exemplo n.º 23
0
        public static void CastSpell(Spell.Skillshot QWER, Obj_AI_Base target)
        {
            if (QWER.Slot == SpellSlot.W)
            {
                var pred = W.GetPrediction(target);
                if (pred.HitChancePercent >= MenuConfig.Wpred)
                {
                    QWER.Cast(pred.CastPosition);
                }
            }
            if (QWER.Slot == SpellSlot.E)
            {
                var pred = E.GetPrediction(target);
                QWER.Cast(pred.CastPosition);

            }

            if (QWER.Slot == SpellSlot.R)
            {
                var pred = R.GetPrediction(target);
                if (pred.HitChancePercent >= MenuConfig.Rpred)
                {
                    QWER.Cast(pred.CastPosition);
                }
            }
        }
Exemplo n.º 24
0
 public Input(Obj_AI_Base _target, Spell s, Vector3 _from, Vector3 _rangeCheckFrom)
 {
     Target = _target;
     SpellDelay = s.Delay;
     SpellMissileSpeed = s.Speed;
     SpellWidth = s.Width;
     SpellRange = s.Range;
     SpellCollisionable = s.Collision;
     SpellSkillShotType = s.Type;
     Path = Target.GetWaypoints();
     if (Target is Obj_AI_Hero)
     {
         Obj_AI_Hero t = Target as Obj_AI_Hero;
         AvgReactionTime = t.AvgMovChangeTime();
         LastMovChangeTime = t.LastMovChangeTime();
         AvgPathLenght = t.AvgPathLenght();
     }
     else
     {
         AvgReactionTime = 0;
         LastMovChangeTime = 0;
         AvgPathLenght = 0;
     }
     From = _from;
     RangeCheckFrom = _rangeCheckFrom;
 }
Exemplo n.º 25
0
 public void DoSpellUnlocked(Spell spell, RectTransform overlayEndRect = null)
 {
     var toast = Instantiate(_spellUnlockedPrefab) as SpellUnlockedToast;
     toast.OverlayEndRect = overlayEndRect;
     toast.SetupToast(spell);
     QueueToast(toast);
 }
Exemplo n.º 26
0
 public SpellDamage(Spell.SpellBase spell, float[] spellDamageValue, float[] spellDamageModifier, DamageType damageType)
 {
     Spell = spell;
     SpellDamageValue = spellDamageValue;
     SpellDamageModifier = spellDamageModifier;
     DamageType = damageType;
 }
Exemplo n.º 27
0
 public void Start()
 {
     player = GameMainReferences.Instance.PlayerCharacter;
     _spell = player.GetSpellAtIndex(_spellIndex);
     ChangeSpellIcon(_spell);
     player.OnSpellChanged += OnSpellChanged;
 }
 public SpellShapeshiftFormSelector(Spell spell, bool stance)
 {
     InitializeComponent();
     _spell = spell;
     _stance = stance;
     Load();
 }
Exemplo n.º 29
0
        public virtual Vector3 FarmCastCircular(Spell.Skillshot spell, IEnumerable<Obj_AI_Minion> mobList, int minHit = 2)
        {
            var bestPos = Vector3.Zero;
            var countBestPos = 0;

            foreach (var aiBase in mobList)
            {
                if (countBestPos == 0)
                {
                    bestPos = aiBase.ServerPosition;
                    countBestPos =
                        EntityManager.MinionsAndMonsters.CombinedAttackable.Count(
                            t => t != null && t.IsValidTarget(spell.Radius));
                }
                else
                {
                    var newBestPos = EntityManager.MinionsAndMonsters.CombinedAttackable.Count(
                            t => t != null && t.IsValidTarget(spell.Radius));

                    if (newBestPos <= countBestPos) continue;

                    countBestPos = newBestPos;
                    bestPos = aiBase.ServerPosition;
                }
            }

            return countBestPos >= minHit ? bestPos : Vector3.Zero;
        }
Exemplo n.º 30
0
 /// <summary>
 /// Triggers a spell refresh event. The spell refresh indicates that the spells destroy timer has been refreshed. 
 /// Typically this will be an attached spell refreshing the timer.
 /// </summary>
 /// <param name="obj"></param>
 private void TriggerSpellRefresh(Spell obj)
 {
     if(OnSpellRefresh != null)
     {
         OnSpellRefresh();
     }
 }
Exemplo n.º 31
0
        internal static bool CanLastHit(this Spell spell, Obj_AI_Base unit, double dmg, double subDmg = 0)
        {
            var hpPred = spell.GetHealthPrediction(unit);

            return(hpPred > 0 && hpPred - subDmg < dmg);
        }
Exemplo n.º 32
0
 internal static bool CanHitCircle(this Spell spell, Obj_AI_Base unit)
 {
     return(spell.GetPredPosition(unit).DistanceToPlayer() < spell.Range);
 }
Exemplo n.º 33
0
        public Caitlyn()
        {
            Q = new Spell(SpellSlot.Q, 1240);
            W = new Spell(SpellSlot.W, 820);
            E = new Spell(SpellSlot.E, 800);
            R = new Spell(SpellSlot.R, 2000);

            Q.SetSkillshot(0.25f, 60f, 2000f, false, SkillshotType.SkillshotLine);
            W.SetSkillshot(1.5f, 20f, float.MaxValue, false, SkillshotType.SkillshotCircle);
            E.SetSkillshot(0.25f, 80f, 1600f, true, SkillshotType.SkillshotLine);

            var comboMenu = new Menu("Combo Settings", "Combo Settings");
            {
                comboMenu.AddItem(new MenuItem("q.combo", "Use (Q)", true).SetValue(true));
                comboMenu.AddItem(new MenuItem("w.combo", "Use (W)", true).SetValue(true));
                comboMenu.AddItem(new MenuItem("e.combo", "Use (E)", true).SetValue(true));
                comboMenu.AddItem(new MenuItem("r.combo", "Use (R)", true).SetValue(true));
                Initializer.Config.AddSubMenu(comboMenu);
            }

            var harassMenu = new Menu("Harass Settings", "Harass Settings");
            {
                harassMenu.AddItem(new MenuItem("q.harass", "Use (Q)", true).SetValue(true));
                harassMenu.AddItem(new MenuItem("e.harass", "Use (E)", true).SetValue(true));
                harassMenu.AddItem(new MenuItem("harass.mana", "Harass Mana Percent", true).SetValue(new Slider(30, 1, 99)));
                Initializer.Config.AddSubMenu(harassMenu);
            }

            var clearmenu = new Menu("LaneClear Settings", "LaneClear Settings");
            {
                clearmenu.AddItem(new MenuItem("q.laneclear", "Use (Q)", true).SetValue(true));
                clearmenu.AddItem(new MenuItem("q.minion.count", "(Q) Min. Minion Count", true).SetValue(new Slider(3, 1, 5)));
                clearmenu.AddItem(new MenuItem("clear.mana", "Clear Mana Percent", true).SetValue(new Slider(30, 1, 99)));
                Initializer.Config.AddSubMenu(clearmenu);
            }

            var junglemenu = new Menu("Jungle Settings", "Jungle Settings");
            {
                junglemenu.AddItem(new MenuItem("q.jungle", "Use (Q)", true).SetValue(true));
                junglemenu.AddItem(new MenuItem("e.jungle", "Use (E)", true).SetValue(true));
                junglemenu.AddItem(new MenuItem("jungle.mana", "Jungle Mana Percent", true).SetValue(new Slider(30, 1, 99)));
                Initializer.Config.AddSubMenu(junglemenu);
            }

            var miscMenu = new Menu("Misc Settings", "Misc Settings");
            {
                var dashinterrupter = new Menu("Dash Interrupter", "Dash Interrupter");
                {
                    dashinterrupter.AddItem(new MenuItem("dash.block", "Use (W) for Block Dash!", true).SetValue(true));
                    miscMenu.AddSubMenu(dashinterrupter);
                }
                Initializer.Config.AddSubMenu(miscMenu);
            }

            var drawMenu = new Menu("Draw Settings", "Draw Settings");

            {
                var drawDamageMenu = new MenuItem("RushDrawEDamage", "Combo Damage").SetValue(true);
                var drawFill       = new MenuItem("RushDrawEDamageFill", "Combo Damage Fill").SetValue(new Circle(true, System.Drawing.Color.Gold));

                drawMenu.SubMenu("Damage Draws").AddItem(drawDamageMenu);
                drawMenu.SubMenu("Damage Draws").AddItem(drawFill);

                DamageIndicator.DamageToUnit = TotalDamage;
                DamageIndicator.Enabled      = drawDamageMenu.GetValue <bool>();
                DamageIndicator.Fill         = drawFill.GetValue <Circle>().Active;
                DamageIndicator.FillColor    = drawFill.GetValue <Circle>().Color;

                drawDamageMenu.ValueChanged +=
                    delegate(object sender, OnValueChangeEventArgs eventArgs)
                {
                    DamageIndicator.Enabled = eventArgs.GetNewValue <bool>();
                };

                drawFill.ValueChanged +=
                    delegate(object sender, OnValueChangeEventArgs eventArgs)
                {
                    DamageIndicator.Fill      = eventArgs.GetNewValue <Circle>().Active;
                    DamageIndicator.FillColor = eventArgs.GetNewValue <Circle>().Color;
                };
                Initializer.Config.AddSubMenu(drawMenu);
            }

            Game.OnUpdate         += CaitlynOnUpdate;
            Obj_AI_Base.OnNewPath += ObjAiHeroOnOnNewPath;
        }
Exemplo n.º 34
0
        private static void SpellDamageReward(TyState playerState, TyState opponentState, Controller player, Controller opponent, PlayerTask task, Spell spell, int damage, float reward)
        {
            var targetMinion = task.Target as Minion;

            if (spell.IsAffectedBySpellpower)
            {
                damage += player.CurrentSpellPower;
            }

            if (targetMinion.HasDivineShield && damage > 1)
            {
                //punishment for wasting damage for divine shield
                playerState.BiasValue -= 5.0f;
                return;
            }

            var targetHealth = targetMinion.Health;

            int diff = targetHealth - damage;

            float finalReward = diff * reward;

            //if the spell kills a minion on point, give additional bonus:
            if (diff == 0)
            {
                finalReward += reward;
            }

            playerState.BiasValue += finalReward;
        }
Exemplo n.º 35
0
            protected override RunStatus Run(object context)
            {
                const string dpsSpell = "Renew";

                // Cast PWS first if its needed
                // 6788 - Weakened Soul
                if (!Self.IsHealthPercentAbove(Settings.PowerWordShieldHealth) && !Self.IsBuffOnMe(6788, Self.AuraCheck.AllAuras) && Spell.CanCast("Power Word: Shield"))
                {
                    Spell.Cast("Power Word: Shield", Me);
                    Utils.LagSleep();
                    while (Spell.IsGCD)
                    {
                        System.Threading.Thread.Sleep(250);
                    }
                }

                Spell.Cast(dpsSpell);
                Utils.LagSleep();

                bool result = Self.IsBuffOnMe(dpsSpell);

                return(result ? RunStatus.Success : RunStatus.Failure);
            }
Exemplo n.º 36
0
        private static void Game_OnGameLoad(EventArgs args)
        {
            if (Player.BaseSkinName != "MasterYi")
            {
                return;
            }
            if (Player.IsDead)
            {
                return;
            }

            Q = new Spell(SpellSlot.Q, 600f);
            W = new Spell(SpellSlot.W);
            E = new Spell(SpellSlot.E, 200f);
            R = new Spell(SpellSlot.R);

            Q.SetTargetted(0.50f, 75f);

            PlayerSpellList.Add(Q);
            PlayerSpellList.Add(W);
            PlayerSpellList.Add(E);
            PlayerSpellList.Add(R);


            //Create the menu
            Config = new Menu("xQx | MasterYi", "MasterYi", true);

            var targetSelectorMenu = new Menu("Target Selector", "Target Selector");

            TargetSelector.AddToMenu(targetSelectorMenu);
            Config.AddSubMenu(targetSelectorMenu);

            new AssassinManager();
            Config.AddSubMenu(new Menu("Orbwalking", "Orbwalking"));
            Orbwalker = new Orbwalking.Orbwalker(Config.SubMenu("Orbwalking"));
            Orbwalker.SetAttack(true);

            // Combo
            Config.AddSubMenu(new Menu("Combo", "Combo"));
            Config.SubMenu("Combo").AddItem(new MenuItem("UseQCombo", "Use Q").SetValue(true));
            Config.SubMenu("Combo")
            .AddItem(new MenuItem("UseQComboDontUnderTurret", "Don't Under Turret Q").SetValue(true));
            Config.SubMenu("Combo").AddItem(new MenuItem("UseECombo", "Use E").SetValue(true));
            Config.SubMenu("Combo").AddItem(new MenuItem("UseRCombo", "Use R").SetValue(true));
            Config.SubMenu("Combo")
            .AddItem(
                new MenuItem("ComboActive", "Combo!").SetValue(
                    new KeyBind(Config.Item("Orbwalk").GetValue <KeyBind>().Key, KeyBindType.Press)));

            // Harass
            Config.AddSubMenu(new Menu("Harass", "Harass"));
            Config.SubMenu("Harass").AddItem(new MenuItem("UseQHarass", "Use Q").SetValue(true));
            Config.SubMenu("Harass")
            .AddItem(new MenuItem("UseQHarassDontUnderTurret", "Don't Under Turret Q").SetValue(true));
            Config.SubMenu("Harass").AddItem(new MenuItem("UseEHarass", "Use E").SetValue(true));
            Config.SubMenu("Harass")
            .AddItem(new MenuItem("HarassMana", "Min. Mana Percent: ").SetValue(new Slider(50, 100, 0)));
            Config.SubMenu("Harass")
            .AddItem(
                new MenuItem("HarassActive", "Harass").SetValue(
                    new KeyBind("C".ToCharArray()[0], KeyBindType.Press)));

            // Lane Clear
            Config.AddSubMenu(new Menu("LaneClear", "LaneClear"));
            Config.SubMenu("LaneClear").AddItem(new MenuItem("UseQLaneClear", "Use Q").SetValue(false));
            Config.SubMenu("LaneClear")
            .AddItem(new MenuItem("UseQLaneClearDontUnderTurret", "Don't Under Turret Q").SetValue(true));
            Config.SubMenu("LaneClear").AddItem(new MenuItem("UseELaneClear", "Use E").SetValue(false));
            Config.SubMenu("LaneClear")
            .AddItem(new MenuItem("LaneClearMana", "Min. Mana Percent: ").SetValue(new Slider(50, 100, 0)));
            Config.SubMenu("LaneClear")
            .AddItem(
                new MenuItem("LaneClearActive", "LaneClear").SetValue(
                    new KeyBind("V".ToCharArray()[0], KeyBindType.Press)));

            // Jungling Farm
            Config.AddSubMenu(new Menu("JungleFarm", "JungleFarm"));
            Config.SubMenu("JungleFarm").AddItem(new MenuItem("UseQJungleFarm", "Use Q").SetValue(true));
            Config.SubMenu("JungleFarm").AddItem(new MenuItem("UseEJungleFarm", "Use E").SetValue(false));
            Config.SubMenu("JungleFarm")
            .AddItem(new MenuItem("JungleFarmMana", "Min. Mana Percent: ").SetValue(new Slider(50, 100, 0)));
            Config.SubMenu("JungleFarm")
            .AddItem(
                new MenuItem("JungleFarmActive", "JungleFarm").SetValue(
                    new KeyBind("V".ToCharArray()[0], KeyBindType.Press)));

            Config.AddSubMenu(new Menu("HealSettings", "HealSettings"));
            Config.SubMenu("HealSettings").AddItem(new MenuItem("HealUseW", "Use W").SetValue(true));
            Config.SubMenu("HealSettings")
            .AddItem(new MenuItem("HealPercent", "Min. HP Percent").SetValue(new Slider(50, 100, 0)));

            Config.SubMenu("HealSettings")
            .AddItem(new MenuItem("JungleFarmMana", "Min. Mana Percent:").SetValue(new Slider(50, 100, 0)));

            // Extras
            MenuExtras = new Menu("Extras", "Extras");
            Config.AddSubMenu(MenuExtras);

            // Extras -> Use Items
            var menuUseItems = new Menu("Use Items", "menuUseItems");

            MenuExtras.AddSubMenu(menuUseItems);

            // Extras -> Use Items -> Targeted Items
            MenuTargetedItems = new Menu("Targeted Items", "menuTargetItems");
            menuUseItems.AddSubMenu(MenuTargetedItems);
            MenuTargetedItems.AddItem(new MenuItem("item3153", "Blade of the Ruined King").SetValue(true));
            MenuTargetedItems.AddItem(new MenuItem("item3144", "Bilgewater Cutlass").SetValue(true));
            MenuTargetedItems.AddItem(new MenuItem("item3146", "Hextech Gunblade").SetValue(true));
            MenuTargetedItems.AddItem(new MenuItem("item3184", "Entropy ").SetValue(true));

            // Extras -> Use Items -> AOE Items
            MenuNonTargetedItems = new Menu("AOE Items", "menuNonTargetedItems");
            menuUseItems.AddSubMenu(MenuNonTargetedItems);
            MenuNonTargetedItems.AddItem(new MenuItem("item3180", "Odyn's Veil").SetValue(true));
            MenuNonTargetedItems.AddItem(new MenuItem("item3143", "Randuin's Omen").SetValue(true));
            MenuNonTargetedItems.AddItem(new MenuItem("item3131", "Sword of the Divine").SetValue(true));
            MenuNonTargetedItems.AddItem(new MenuItem("item3074", "Ravenous Hydra").SetValue(true));
            MenuNonTargetedItems.AddItem(new MenuItem("item3142", "Youmuu's Ghostblade").SetValue(true));


            MenuSupportedSpells = new Menu("Q Dodge Spells", "suppspells");

            foreach (var xEnemy in ObjectManager.Get <Obj_AI_Hero>().Where(enemy => enemy.IsEnemy))
            {
                Obj_AI_Hero enemy = xEnemy;
                foreach (var ccList in SpellList.BuffList.Where(xList => xList.ChampionName == enemy.ChampionName))
                {
                    MenuSupportedSpells.AddItem(new MenuItem(ccList.BuffName, ccList.DisplayName)).SetValue(true);
                }
            }
            Config.AddSubMenu(MenuSupportedSpells);


            // Drawing
            Config.AddSubMenu(new Menu("Drawings", "Drawings"));
            Config.SubMenu("Drawings")
            .AddItem(
                new MenuItem("DrawQRange", "Q range").SetValue(
                    new Circle(true, System.Drawing.Color.FromArgb(255, 255, 255, 255))));

            new PotionManager();

            Config.AddToMainMenu();


            Game.OnUpdate  += Game_OnUpdate;
            Drawing.OnDraw += Drawing_OnDraw;
            Obj_AI_Base.OnProcessSpellCast += Game_OnProcessSpellCast;

            Game.PrintChat(
                String.Format(
                    "<font color='#70DBDB'>xQx | </font> <font color='#FFFFFF'>{0}" +
                    "</font> <font color='#70DBDB'> Loaded!</font>", ChampionName));
        }
Exemplo n.º 37
0
        static void Game_OnGameLoad()
        {
            _player = ObjectManager.Player;

            if (_player.ChampionName != ChampionName) return;

            _q = new Spell(SpellSlot.Q, 675);
            _q1 = new Spell(SpellSlot.Q, 900);
            _w = new Spell(SpellSlot.W, 900, TargetSelector.DamageType.Magical);
            _w2 = new Spell(SpellSlot.W, 900, TargetSelector.DamageType.Magical);
            _e = new Spell(SpellSlot.E, 475f);
            _r = new Spell(SpellSlot.R, 1200);


            _q.SetTargetted(0.25f, 1400f);
            _q1.SetSkillshot(0.5f, 50, float.MaxValue, false, SkillshotType.SkillshotLine);
            _w.SetSkillshot(0.30f, 80f, 1600f, true, SkillshotType.SkillshotLine);
            _w2.SetSkillshot(0.30f, 80f, 1600f, false, SkillshotType.SkillshotCircle);
            _r.SetSkillshot(0.2f, 110f, 2500, true, SkillshotType.SkillshotLine);

            _youmuu = new Items.Item(3142, 10);
            _bilge = new Items.Item(3144, 450f);
            _blade = new Items.Item(3153, 450f);

            //D Graves
            _config = new Menu("D-Lucian", "D-Lucian", true);

            //TargetSelector
            var targetSelectorMenu = new Menu("Target Selector", "Target Selector");
            TargetSelector.AddToMenu(targetSelectorMenu);
            _config.AddSubMenu(targetSelectorMenu);

            //Orbwalker
            _config.AddSubMenu(new Menu("Orbwalking", "Orbwalking"));
            Orbwalker = new Orbwalking.Orbwalker(_config.SubMenu("Orbwalking"));

            //Combo
            _config.AddSubMenu(new Menu("Combo", "Combo"));
            _config.SubMenu("Combo").AddItem(new MenuItem("UseQC", "Use Q")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("UseWC", "Use W")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("UseEC", "Use E")).SetValue(true);
            _config.SubMenu("Combo")
                .AddItem(
                    new MenuItem("useRaim", "Use R(Semi-Manual)").SetValue(
                        new KeyBind("T".ToCharArray()[0], KeyBindType.Press)));
            _config.SubMenu("Combo")
                .AddItem(new MenuItem("ActiveCombo", "Combo!").SetValue(new KeyBind(32, KeyBindType.Press)));

            //Harass
            _config.AddSubMenu(new Menu("Harass", "Harass"));
            _config.SubMenu("Harass").AddItem(new MenuItem("UseQH", "Use Q")).SetValue(true);
            _config.SubMenu("Harass").AddItem(new MenuItem("UseWH", "Use W")).SetValue(false);
            _config.SubMenu("Harass")
                .AddItem(
                    new MenuItem("harasstoggle", "AutoHarass (toggle)").SetValue(
                        new KeyBind("G".ToCharArray()[0], KeyBindType.Toggle)));
            _config.SubMenu("Harass")
                .AddItem(new MenuItem("Harrasmana", "Minimum Mana").SetValue(new Slider(70, 1, 100)));
            _config.SubMenu("Harass")
                .AddItem(
                    new MenuItem("ActiveHarass", "Harass!").SetValue(
                        new KeyBind("C".ToCharArray()[0], KeyBindType.Press)));

            //Farm
            _config.AddSubMenu(new Menu("Farm", "Farm"));
            //Last Hit
            _config.SubMenu("Farm").AddSubMenu(new Menu("LastHit", "LastHit"));
            _config.SubMenu("Farm").SubMenu("LastHit").AddItem(new MenuItem("UseQLH", "Q LastHit")).SetValue(true);
            _config.SubMenu("Farm").SubMenu("LastHit").AddItem(new MenuItem("UseWLH", "W LastHit")).SetValue(false);
            _config.SubMenu("Farm")
                .SubMenu("LastHit")
                .AddItem(new MenuItem("Lastmana", "Minimum Mana").SetValue(new Slider(70, 1, 100)));
            _config.SubMenu("Farm")
                .SubMenu("LastHit")
                .AddItem(
                    new MenuItem("ActiveLast", "LastHit!").SetValue(
                        new KeyBind("X".ToCharArray()[0], KeyBindType.Press)));
            //Lane Clear
            _config.SubMenu("Farm").AddSubMenu(new Menu("LaneClear", "LaneClear"));
            _config.SubMenu("Farm").SubMenu("LaneClear").AddItem(new MenuItem("UseQLP", "Q To Harass")).SetValue(true);
            _config.SubMenu("Farm").SubMenu("LaneClear").AddItem(new MenuItem("UseQL", "Q LaneClear")).SetValue(true);
            _config.SubMenu("Farm")
                .SubMenu("LaneClear")
                .AddItem(new MenuItem("minminions", "Minimum minions to use Q").SetValue(new Slider(3, 1, 6)));
            _config.SubMenu("Farm").SubMenu("LaneClear").AddItem(new MenuItem("UseWL", "W LaneClear")).SetValue(false);
            _config.SubMenu("Farm")
                .SubMenu("LaneClear")
                .AddItem(new MenuItem("minminionsw", "Minimum minions to use W").SetValue(new Slider(3, 1, 5)));
            _config.SubMenu("Farm")
                .SubMenu("LaneClear")
                .AddItem(new MenuItem("Lanemana", "Minimum Mana").SetValue(new Slider(70, 1, 100)));
            _config.SubMenu("Farm")
                .SubMenu("LaneClear")
                .AddItem(
                    new MenuItem("ActiveLane", "LaneClear!").SetValue(
                        new KeyBind("V".ToCharArray()[0], KeyBindType.Press)));
            //Jungle clear
            _config.SubMenu("Farm").AddSubMenu(new Menu("JungleClear", "JungleClear"));
            _config.SubMenu("Farm").SubMenu("JungleClear").AddItem(new MenuItem("UseQJ", "Q Jungle")).SetValue(true);
            _config.SubMenu("Farm").SubMenu("JungleClear").AddItem(new MenuItem("UseWJ", "W Jungle")).SetValue(true);
            _config.SubMenu("Farm")
                .SubMenu("JungleClear")
                .AddItem(new MenuItem("Junglemana", "Minimum Mana").SetValue(new Slider(35, 1, 100)));
            _config.SubMenu("Farm")
                .SubMenu("JungleClear")
                .AddItem(
                    new MenuItem("ActiveJungle", "Jungle key").SetValue(
                        new KeyBind("V".ToCharArray()[0], KeyBindType.Press)));


            //items
            //Offensive
            _config.AddSubMenu(new Menu("items", "items"));
            _config.SubMenu("items").AddSubMenu(new Menu("Offensive", "Offensive"));
            _config.SubMenu("items").SubMenu("Offensive").AddItem(new MenuItem("Youmuu", "Use Youmuu's")).SetValue(true);
            _config.SubMenu("items").SubMenu("Offensive").AddItem(new MenuItem("Bilge", "Use Bilge")).SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Offensive")
                .AddItem(new MenuItem("BilgeEnemyhp", "If Enemy Hp <").SetValue(new Slider(60, 1, 100)));
            _config.SubMenu("items")
                .SubMenu("Offensive")
                .AddItem(new MenuItem("Bilgemyhp", "Or your Hp < ").SetValue(new Slider(60, 1, 100)));
            _config.SubMenu("items").SubMenu("Offensive").AddItem(new MenuItem("Blade", "Use Blade")).SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Offensive")
                .AddItem(new MenuItem("BladeEnemyhp", "If Enemy Hp <").SetValue(new Slider(60, 1, 100)));
            _config.SubMenu("items")
                .SubMenu("Offensive")
                .AddItem(new MenuItem("Blademyhp", "Or Your  Hp <").SetValue(new Slider(60, 1, 100)));

            //Deffensive
            _config.SubMenu("items").AddSubMenu(new Menu("Deffensive", "Deffensive"));
            _config.SubMenu("items").SubMenu("Deffensive").AddSubMenu(new Menu("Cleanse", "Cleanse"));
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("useqss", "Use QSS/Mercurial Scimitar/Dervish Blade"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("blind", "Blind"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("charm", "Charm"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("fear", "Fear"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("flee", "Flee"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("snare", "Snare"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("taunt", "Taunt"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("suppression", "Suppression"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("stun", "Stun"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("polymorph", "Polymorph"))
                .SetValue(false);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("silence", "Silence"))
                .SetValue(false);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("zedultexecute", "Zed Ult"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Deffensive")
                .SubMenu("Cleanse")
                .AddItem(new MenuItem("Cleansemode", "Use Cleanse"))
                .SetValue(new StringList(new string[2] { "Always", "In Combo" }));

            //potions
            _config.SubMenu("items").AddSubMenu(new Menu("Potions", "Potions"));
            _config.SubMenu("items")
                .SubMenu("Potions")
                .AddItem(new MenuItem("usehppotions", "Use Healt potion/Refillable/Hunters/Corrupting/Biscuit"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Potions")
                .AddItem(new MenuItem("usepotionhp", "If Health % <").SetValue(new Slider(35, 1, 100)));
            _config.SubMenu("items")
                .SubMenu("Potions")
                .AddItem(new MenuItem("usemppotions", "Use Hunters/Corrupting/Biscuit"))
                .SetValue(true);
            _config.SubMenu("items")
                .SubMenu("Potions")
                .AddItem(new MenuItem("usepotionmp", "If Mana % <").SetValue(new Slider(35, 1, 100)));

            //Misc
            _config.AddSubMenu(new Menu("Misc", "Misc"));
            _config.SubMenu("Misc").AddItem(new MenuItem("UseQM", "Use Q KillSteal")).SetValue(true);
            _config.SubMenu("Misc").AddItem(new MenuItem("UseWM", "Use W KillSteal")).SetValue(true);
            _config.SubMenu("Misc").AddItem(new MenuItem("Gap_E", "GapClosers E")).SetValue(true);

            //Drawings
            _config.AddSubMenu(new Menu("Drawings", "Drawings"));
            _config.SubMenu("Drawings").AddItem(new MenuItem("DrawQ", "Draw Q")).SetValue(true);
            _config.SubMenu("Drawings").AddItem(new MenuItem("DrawW", "Draw W")).SetValue(false);
            _config.SubMenu("Drawings").AddItem(new MenuItem("DrawE", "Draw E")).SetValue(false);
            _config.SubMenu("Drawings").AddItem(new MenuItem("DrawR", "Draw R")).SetValue(false);
            _config.SubMenu("Drawings").AddItem(new MenuItem("Drawharass", "Draw Auto Harass").SetValue(true));

            _config.AddToMainMenu();
            Chat.Print("<font color='#881df2'>D-Lucian by Diabaths</font> Loaded.");
            Game.OnUpdate += Game_OnGameUpdate;
            Drawing.OnDraw += Drawing_OnDraw;
            AntiGapcloser.OnEnemyGapcloser += AntiGapcloser_OnEnemyGapcloser;
            Obj_AI_Base.OnProcessSpellCast += OnProcessSpellCast;
            Spellbook.OnCastSpell += OnCastSpell;
            Obj_AI_Base.OnPlayAnimation += Obj_AI_Base_OnPlayAnimation;
            Chat.Print(
                "<font color='#f2f21d'>Do you like it???  </font> <font color='#ff1900'>Drop 1 Upvote in Database </font>");
            Chat.Print(
                "<font color='#f2f21d'>Buy me cigars </font> <font color='#ff1900'>[email protected]</font> (10) S");
        }
Exemplo n.º 38
0
        public void LoadOKTW()
        {
            Q    = new Spell(SpellSlot.Q, 1175);
            Qcol = new Spell(SpellSlot.Q, 1175);
            W    = new Spell(SpellSlot.W, 1075);
            E    = new Spell(SpellSlot.E, 1075);
            R    = new Spell(SpellSlot.R, 3000);

            Qcol.SetSkillshot(0.25f, 70f, 1200f, true, SkillshotType.SkillshotLine);
            Q.SetSkillshot(0.25f, 70f, 1200f, false, SkillshotType.SkillshotLine);
            W.SetSkillshot(0.25f, 110f, 1200f, false, SkillshotType.SkillshotLine);
            E.SetSkillshot(0.3f, 250f, 1050f, false, SkillshotType.SkillshotCircle);
            R.SetSkillshot(1.25f, 150f, float.MaxValue, false, SkillshotType.SkillshotLine);
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("noti", "Show notification", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("qRange", "Q range", true).SetValue(false));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("wRange", "W range", true).SetValue(false));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("eRange", "E range", true).SetValue(false));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("rRange", "R range", true).SetValue(false));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("rRangeMini", "R range minimap", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("onlyRdy", "Draw when skill rdy", true).SetValue(true));

            Config.SubMenu(Player.ChampionName).SubMenu("Q Config").AddItem(new MenuItem("autoQ", "Auto Q", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Q Config").AddItem(new MenuItem("gapQ", "Auto Q Gap Closer", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Q Config").AddItem(new MenuItem("harrasQ", "Harass Q", true).SetValue(true));

            foreach (var enemy in ObjectManager.Get <Obj_AI_Hero>().Where(enemy => enemy.IsEnemy))
            {
                Config.SubMenu(Player.ChampionName).SubMenu("Q Config").SubMenu("Use on:").AddItem(new MenuItem("Qon" + enemy.ChampionName, enemy.ChampionName).SetValue(true));
            }

            Config.SubMenu(Player.ChampionName).SubMenu("E config").AddItem(new MenuItem("autoE", "Auto E", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("E config").AddItem(new MenuItem("harrasE", "Harras E", true).SetValue(false));
            Config.SubMenu(Player.ChampionName).SubMenu("E config").AddItem(new MenuItem("autoEcc", "Auto E only CC enemy", true).SetValue(false));
            Config.SubMenu(Player.ChampionName).SubMenu("E config").AddItem(new MenuItem("autoEslow", "Auto E slow logic detonate", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("E config").AddItem(new MenuItem("autoEdet", "Only detonate if target in E ", true).SetValue(false));

            Config.SubMenu(Player.ChampionName).SubMenu("W Shield Config").AddItem(new MenuItem("Wdmg", "W dmg % hp", true).SetValue(new Slider(10, 100, 0)));
            foreach (var ally in ObjectManager.Get <Obj_AI_Hero>().Where(enemy => enemy.Team == Player.Team))
            {
                Config.SubMenu(Player.ChampionName).SubMenu("W Shield Config").SubMenu("Shield ally").SubMenu(ally.ChampionName).AddItem(new MenuItem("damage" + ally.ChampionName, "Damage incoming", true).SetValue(true));
                Config.SubMenu(Player.ChampionName).SubMenu("W Shield Config").SubMenu("Shield ally").SubMenu(ally.ChampionName).AddItem(new MenuItem("HardCC" + ally.ChampionName, "Hard CC", true).SetValue(true));
                Config.SubMenu(Player.ChampionName).SubMenu("W Shield Config").SubMenu("Shield ally").SubMenu(ally.ChampionName).AddItem(new MenuItem("Poison" + ally.ChampionName, "Poison", true).SetValue(true));
            }

            Config.SubMenu(Player.ChampionName).SubMenu("R config").AddItem(new MenuItem("autoR", "Auto R", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").AddItem(new MenuItem("Rcc", "R fast KS combo", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").AddItem(new MenuItem("RaoeCount", "R x enemies in combo [0 == off]", true).SetValue(new Slider(3, 5, 0)));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").AddItem(new MenuItem("hitchanceR", "Hit Chance R", true).SetValue(new Slider(2, 3, 0)));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").AddItem(new MenuItem("useR", "Semi-manual cast R key", true).SetValue(new KeyBind("T".ToCharArray()[0], KeyBindType.Press))); //32 == space

            Config.SubMenu(Player.ChampionName).SubMenu("R config").SubMenu("R Jungle stealer").AddItem(new MenuItem("Rjungle", "R Jungle stealer", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").SubMenu("R Jungle stealer").AddItem(new MenuItem("Rdragon", "Dragon", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").SubMenu("R Jungle stealer").AddItem(new MenuItem("Rbaron", "Baron", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").SubMenu("R Jungle stealer").AddItem(new MenuItem("Rred", "Red", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").SubMenu("R Jungle stealer").AddItem(new MenuItem("Rblue", "Blue", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("R config").SubMenu("R Jungle stealer").AddItem(new MenuItem("Rally", "Ally stealer", true).SetValue(false));

            foreach (var enemy in ObjectManager.Get <Obj_AI_Hero>().Where(enemy => enemy.IsEnemy))
            {
                Config.SubMenu(Player.ChampionName).SubMenu("Harras").AddItem(new MenuItem("harras" + enemy.ChampionName, enemy.ChampionName).SetValue(true));
            }

            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("farmE", "Lane clear E", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("Mana", "LaneClear Mana", true).SetValue(new Slider(80, 100, 0)));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("LCminions", "LaneClear minimum minions", true).SetValue(new Slider(2, 10, 0)));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleQ", "Jungle clear Q", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleE", "Jungle clear E", true).SetValue(true));

            Game.OnUpdate                  += Game_OnGameUpdate;
            Drawing.OnDraw                 += Drawing_OnDraw;
            Drawing.OnEndScene             += Drawing_OnEndScene;
            Obj_AI_Base.OnProcessSpellCast += Obj_AI_Base_OnProcessSpellCast;
            AntiGapcloser.OnEnemyGapcloser += AntiGapcloser_OnEnemyGapcloser;
        }
Exemplo n.º 39
0
 //Lightning Bolt: Deal 3 damage. Overload: (1)
 private static void LightningBolt(TyState playerState, TyState opponentState, Controller player, Controller opponent, PlayerTask task, Spell spell)
 {
     if (task.HasTarget)
     {
         //reward if the spell does NOT overkill an enemy:
         if (task.Target is Minion)
         {
             SpellDamageReward(playerState, opponentState, player, opponent, task, spell, 3, 1.25f);
         }
     }
 }
Exemplo n.º 40
0
        //Lightning Storm: Deal 2-3 damage to all enemy minions. Overload: (2)
        private static void LightningStorm(TyState playerState, TyState opponentState, Controller player, Controller opponent, PlayerTask task, Spell spell)
        {
            //give punishment when having less than this enemies:
            const int NUM_ENEMY_TARGETS = 3;

            playerState.BiasValue += (opponentState.NumMinionsOnBoard - NUM_ENEMY_TARGETS) * 1.25f;
        }
Exemplo n.º 41
0
        public static void CalculateValues(TyState playerState, TyState opponentState, Controller player, Controller opponent, PlayerTask task, Spell spell)
        {
            if (_spellDictionary == null)
            {
                Init();
            }

            //give reward/punishment if spells cost less/more than usual:
            float diff = (float)spell.Card.Cost - (float)spell.Cost;

            playerState.BiasValue += diff * 1.25f;

            var key = spell.Card.Name;

            if (_spellDictionary.ContainsKey(key))
            {
                var action = _spellDictionary[key];
                action(playerState, opponentState, player, opponent, task, spell);
            }

            else if (TyConst.LOG_UNKNOWN_SECRETS)
            {
                TyDebug.LogInfo("Unknown spell: " + task.FullPrint());
            }
        }
Exemplo n.º 42
0
        public static void AddToMenu(Menu menu, List <Wrappers.Spell> spells)
        {
            try
            {
                _menu = menu.AddSubMenu(new Menu("Debug", menu.Name + ".debug"));

                if (spells.All(s => s.Slot == SpellSlot.Unknown))
                {
                    return;
                }

                foreach (var spell in spells.Where(s => s.Slot != SpellSlot.Unknown))
                {
                    var lSpell   = spell;
                    var range    = spell.Range;
                    var width    = spell.Width;
                    var delay    = spell.Delay;
                    var speed    = spell.Speed;
                    var duration = spell.ChargeDuration;
                    var minRange = spell.ChargedMinRange;
                    var maxRange = spell.ChargedMaxRange;

                    DefaultSpells[spell] = new Spell(spell.Slot, spell.Range)
                    {
                        Range           = range,
                        Width           = width,
                        Delay           = delay,
                        Speed           = speed,
                        ChargeDuration  = duration,
                        ChargedMinRange = minRange,
                        ChargedMaxRange = maxRange
                    };

                    var spellMenu =
                        _menu.AddSubMenu(
                            new Menu(spell.Slot.ToString(), _menu.Name + ObjectManager.Player.ChampionName + spell.Slot));

                    if (Math.Abs(range - float.MaxValue) > 1 && range > 0)
                    {
                        spellMenu.AddItem(
                            new MenuItem(spellMenu.Name + ".range", "Range").SetValue(
                                new Slider(
                                    (int)range, (int)(range * MinMultiplicator), (int)(range * MaxMultiplicator))))
                        .ValueChanged +=
                            delegate(object sender, OnValueChangeEventArgs args)
                        {
                            lSpell.Range = args.GetNewValue <Slider>().Value;
                        };
                        spell.Range = _menu.Item(spellMenu.Name + ".range").GetValue <Slider>().Value;
                    }

                    if (Math.Abs(width - float.MaxValue) > 1 && width > 0)
                    {
                        spellMenu.AddItem(
                            new MenuItem(spellMenu.Name + ".width", "Width").SetValue(
                                new Slider(
                                    (int)width, (int)(width * MinMultiplicator), (int)(width * MaxMultiplicator))))
                        .ValueChanged +=
                            delegate(object sender, OnValueChangeEventArgs args)
                        {
                            lSpell.Width = args.GetNewValue <Slider>().Value;
                        };
                        spell.Width = _menu.Item(spellMenu.Name + ".width").GetValue <Slider>().Value;
                    }

                    if (Math.Abs(speed - float.MaxValue) > 1 && speed > 0)
                    {
                        spellMenu.AddItem(
                            new MenuItem(spellMenu.Name + ".speed", "Speed").SetValue(
                                new Slider(
                                    (int)speed, (int)(speed * MinMultiplicator), (int)(speed * MaxMultiplicator))))
                        .ValueChanged +=
                            delegate(object sender, OnValueChangeEventArgs args)
                        {
                            lSpell.Speed = args.GetNewValue <Slider>().Value;
                        };
                        spell.Speed = _menu.Item(spellMenu.Name + ".speed").GetValue <Slider>().Value;
                    }

                    spellMenu.AddItem(
                        new MenuItem(spellMenu.Name + ".delay", "Delay").SetValue(
                            new Slider(
                                (int)(delay * 1000), 0, (int)((delay > 1 ? delay * MaxMultiplicator : 1) * 1000))))
                    .ValueChanged +=
                        delegate(object sender, OnValueChangeEventArgs args)
                    {
                        lSpell.Delay = args.GetNewValue <Slider>().Value / 1000f;
                    };
                    spell.Delay = _menu.Item(spellMenu.Name + ".delay").GetValue <Slider>().Value / 1000f;

                    if (spell.IsChargedSpell)
                    {
                        spellMenu.AddItem(
                            new MenuItem(spellMenu.Name + ".duration", "Duration").SetValue(
                                new Slider(
                                    duration, (int)(duration * MinMultiplicator), (int)(duration * MaxMultiplicator))))
                        .ValueChanged +=
                            delegate(object sender, OnValueChangeEventArgs args)
                        {
                            lSpell.ChargeDuration = args.GetNewValue <Slider>().Value;
                        };
                        spellMenu.AddItem(
                            new MenuItem(spellMenu.Name + ".min-range", "Min Range").SetValue(
                                new Slider(
                                    minRange, (int)(minRange * MinMultiplicator), (int)(minRange * MaxMultiplicator))))
                        .ValueChanged +=
                            delegate(object sender, OnValueChangeEventArgs args)
                        {
                            lSpell.ChargedMinRange = args.GetNewValue <Slider>().Value;
                        };
                        spellMenu.AddItem(
                            new MenuItem(spellMenu.Name + ".max-range", "Max Range").SetValue(
                                new Slider(
                                    maxRange, (int)(maxRange * MinMultiplicator), (int)(maxRange * MaxMultiplicator))))
                        .ValueChanged +=
                            delegate(object sender, OnValueChangeEventArgs args)
                        {
                            lSpell.ChargedMaxRange = args.GetNewValue <Slider>().Value;
                        };

                        spell.ChargeDuration  = _menu.Item(spellMenu.Name + ".duration").GetValue <Slider>().Value;
                        spell.ChargedMinRange = _menu.Item(spellMenu.Name + ".min-range").GetValue <Slider>().Value;
                        spell.ChargedMaxRange = _menu.Item(spellMenu.Name + ".max-range").GetValue <Slider>().Value;
                    }
                }
                _menu.AddItem(new MenuItem(_menu.Name + ".reset", "Reset").SetValue(false)).ValueChanged +=
                    delegate(object sender, OnValueChangeEventArgs args)
                {
                    try
                    {
                        if (args.GetNewValue <bool>())
                        {
                            Utility.DelayAction.Add(0, () => _menu.Item(_menu.Name + ".reset").SetValue(false));
                            foreach (var entry in DefaultSpells)
                            {
                                entry.Key.Range           = entry.Value.Range;
                                entry.Key.Width           = entry.Value.Width;
                                entry.Key.Delay           = entry.Value.Delay;
                                entry.Key.Speed           = entry.Value.Speed;
                                entry.Key.ChargeDuration  = entry.Value.ChargeDuration;
                                entry.Key.ChargedMinRange = entry.Value.ChargedMinRange;
                                entry.Key.ChargedMaxRange = entry.Value.ChargedMaxRange;

                                var name = _menu.Name + ObjectManager.Player.ChampionName + entry.Key.Slot;
                                if (Math.Abs(entry.Key.Range - float.MaxValue) > 1 && entry.Key.Range > 0)
                                {
                                    _menu.Item(name + ".range")
                                    .SetValue(
                                        new Slider(
                                            (int)entry.Key.Range, (int)(entry.Key.Range * MinMultiplicator),
                                            (int)(entry.Key.Range * MaxMultiplicator)));
                                }
                                if (Math.Abs(entry.Key.Speed - float.MaxValue) > 1 && entry.Key.Speed > 0)
                                {
                                    _menu.Item(name + ".speed")
                                    .SetValue(
                                        new Slider(
                                            (int)entry.Key.Speed, (int)(entry.Key.Speed * MinMultiplicator),
                                            (int)(entry.Key.Speed * MaxMultiplicator)));
                                }
                                if (Math.Abs(entry.Key.Width - float.MaxValue) > 1 && entry.Key.Width > 0)
                                {
                                    _menu.Item(name + ".width")
                                    .SetValue(
                                        new Slider(
                                            (int)entry.Key.Width, (int)(entry.Key.Width * MinMultiplicator),
                                            (int)(entry.Key.Width * MaxMultiplicator)));
                                }
                                _menu.Item(name + ".delay")
                                .SetValue(
                                    new Slider(
                                        (int)(entry.Key.Delay * 1000), 0,
                                        (int)
                                        ((entry.Key.Delay > 1 ? entry.Key.Delay * MaxMultiplicator : 1) *
                                         1000)));

                                if (entry.Key.IsChargedSpell)
                                {
                                    _menu.Item(name + ".duration")
                                    .SetValue(
                                        new Slider(
                                            entry.Key.ChargeDuration,
                                            (int)(entry.Key.ChargeDuration * MinMultiplicator),
                                            (int)(entry.Key.ChargeDuration * MaxMultiplicator)));
                                    _menu.Item(name + ".min-range")
                                    .SetValue(
                                        new Slider(
                                            entry.Key.ChargedMinRange,
                                            (int)(entry.Key.ChargedMinRange * MinMultiplicator),
                                            (int)(entry.Key.ChargedMinRange * MaxMultiplicator)));
                                    _menu.Item(name + ".max-range")
                                    .SetValue(
                                        new Slider(
                                            entry.Key.ChargedMaxRange,
                                            (int)(entry.Key.ChargedMaxRange * MinMultiplicator),
                                            (int)(entry.Key.ChargedMaxRange * MaxMultiplicator)));
                                }
                            }
                        }
                    }
                    catch (Exception ex)
                    {
                        Global.Logger.AddItem(new LogItem(ex));
                    }
                };
            }
            catch (Exception ex)
            {
                Global.Logger.AddItem(new LogItem(ex));
            }
        }
Exemplo n.º 43
0
        static void Game_OnGameLoad(EventArgs args)
        {
            _player = ObjectManager.Player;
            if (_player.BaseSkinName != ChampionName)
            {
                return;
            }

            _humanQ  = new Spell(SpellSlot.Q, 625f);
            _humanW  = new Spell(SpellSlot.W, 950f);
            _humanE  = new Spell(SpellSlot.E, 1075f);
            _spiderQ = new Spell(SpellSlot.Q, 475f);
            _spiderW = new Spell(SpellSlot.W, 0);
            _spiderE = new Spell(SpellSlot.E, 750f);
            _r       = new Spell(SpellSlot.R, 0);

            _humanW.SetSkillshot(0.25f, 100f, 1000, true, SkillshotType.SkillshotLine);
            _humanE.SetSkillshot(0.25f, 55f, 1300, true, SkillshotType.SkillshotLine);

            //DFG = new Items.Item(3128, 750f);

            _igniteSlot = _player.GetSpellSlot("SummonerDot");
            _smiteSlot  = _player.SummonerSpellbook.GetSpell(_player.GetSpellSlot("summonersmite"));


            _config = new Menu("D-Elise", "D-Elise", true);


            //TargetSelector
            var targetSelectorMenu = new Menu("Target Selector", "Target Selector");

            SimpleTs.AddToMenu(targetSelectorMenu);
            _config.AddSubMenu(targetSelectorMenu);

            //Orbwalker
            _config.AddSubMenu(new Menu("Orbwalking", "Orbwalking"));
            _orbwalker = new Orbwalking.Orbwalker(_config.SubMenu("Orbwalking"));

            //Combo
            _config.AddSubMenu(new Menu("Combo", "Combo"));
            _config.SubMenu("Combo").AddItem(new MenuItem("UseHumanQ", "Human Q")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("UseHumanW", "Human W")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("UseHumanE", "Human E")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("UseRCombo", "Auto use R")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("UseSpiderQ", "Spider Q")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("UseSpiderW", "Spider W")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("UseSpiderE", "Spider E")).SetValue(true);
            _config.SubMenu("Combo").AddItem(new MenuItem("ActiveCombo", "Combo!").SetValue(new KeyBind(32, KeyBindType.Press)));

            //Harass
            _config.AddSubMenu(new Menu("Harass", "Harass"));
            _config.SubMenu("Harass").AddItem(new MenuItem("UseQHarass", "Human Q")).SetValue(true);
            _config.SubMenu("Harass").AddItem(new MenuItem("UseWHarass", "Human W")).SetValue(true);
            _config.SubMenu("Harass").AddItem(new MenuItem("Harrasmana", "Minimum Mana").SetValue(new Slider(60, 1, 100)));
            _config.SubMenu("Harass").AddItem(new MenuItem("ActiveHarass", "Harass key").SetValue(new KeyBind("C".ToCharArray()[0], KeyBindType.Press)));

            //Farm
            _config.AddSubMenu(new Menu("Farm", "Farm"));
            _config.SubMenu("Farm").AddItem(new MenuItem("HumanQFarm", "Human Q")).SetValue(true);
            _config.SubMenu("Farm").AddItem(new MenuItem("HumanWFarm", "Human W")).SetValue(true);
            _config.SubMenu("Farm").AddItem(new MenuItem("SpiderQFarm", "Spider Q")).SetValue(false);
            _config.SubMenu("Farm").AddItem(new MenuItem("SpiderWFarm", "Spider W")).SetValue(true);
            _config.SubMenu("Farm").AddItem(new MenuItem("Farm_R", "Auto Switch(toggle)").SetValue(new KeyBind("G".ToCharArray()[0], KeyBindType.Toggle)));
            _config.SubMenu("Farm").AddItem(new MenuItem("ActiveFreeze", "Freeze Lane").SetValue(new KeyBind("X".ToCharArray()[0], KeyBindType.Press)));
            _config.SubMenu("Farm").AddItem(new MenuItem("ClearActive", "Clear Lane").SetValue(new KeyBind("V".ToCharArray()[0], KeyBindType.Press)));
            _config.SubMenu("Farm").AddItem(new MenuItem("Lanemana", "Minimum Mana").SetValue(new Slider(60, 1, 100)));

            //Farm
            _config.AddSubMenu(new Menu("Jungle", "Jungle"));
            _config.SubMenu("Jungle").AddItem(new MenuItem("HumanQFarmJ", "Human Q")).SetValue(true);
            _config.SubMenu("Jungle").AddItem(new MenuItem("HumanWFarmJ", "Human W")).SetValue(true);
            _config.SubMenu("Jungle").AddItem(new MenuItem("SpiderQFarmJ", "Spider Q")).SetValue(false);
            _config.SubMenu("Jungle").AddItem(new MenuItem("SpiderWFarmJ", "Spider W")).SetValue(true);
            _config.SubMenu("Jungle").AddItem(new MenuItem("ActiveJungle", "Jungle").SetValue(new KeyBind("V".ToCharArray()[0], KeyBindType.Press)));
            _config.SubMenu("Jungle").AddItem(new MenuItem("Junglemana", "Minimum Mana").SetValue(new Slider(60, 1, 100)));

            //misc
            _config.AddSubMenu(new Menu("Misc", "Misc"));
            _config.SubMenu("Misc").AddItem(new MenuItem("usePackets", "Use Packets")).SetValue(true);
            _config.SubMenu("Misc").AddItem(new MenuItem("Spidergapcloser", "SpiderE to GapCloser")).SetValue(true);
            _config.SubMenu("Misc").AddItem(new MenuItem("Humangapcloser", "HumanE to GapCloser")).SetValue(true);
            _config.SubMenu("Misc").AddItem(new MenuItem("UseEInt", "HumanE to Interrupt")).SetValue(true);
            _config.SubMenu("Misc").AddItem(new MenuItem("smite", "Auto Smite Minion").SetValue(true));
            _config.SubMenu("Misc").AddItem(new MenuItem("autoE", "HUmanE with VeryHigh Use").SetValue(new KeyBind("T".ToCharArray()[0], KeyBindType.Press)));
            _config.SubMenu("Misc")
            .AddItem(new MenuItem("Echange", "E Hit").SetValue(
                         new StringList(new[] { "Low", "Medium", "High", "Very High" })));



            //Kill Steal
            _config.AddSubMenu(new Menu("KillSteal", "Ks"));
            _config.SubMenu("Ks").AddItem(new MenuItem("ActiveKs", "Use KillSteal")).SetValue(true);
            _config.SubMenu("Ks").AddItem(new MenuItem("HumanQKs", "Human Q")).SetValue(true);
            _config.SubMenu("Ks").AddItem(new MenuItem("HumanWKs", "Human W")).SetValue(true);
            _config.SubMenu("Ks").AddItem(new MenuItem("SpiderQKs", "Spider Q")).SetValue(true);
            _config.SubMenu("Ks").AddItem(new MenuItem("UseIgnite", "Use Ignite")).SetValue(true);


            //Drawings
            _config.AddSubMenu(new Menu("Drawings", "Drawings"));
            _config.SubMenu("Drawings").AddItem(new MenuItem("DrawQ", "Human Q")).SetValue(true);
            _config.SubMenu("Drawings").AddItem(new MenuItem("DrawW", "Human W")).SetValue(true);
            _config.SubMenu("Drawings").AddItem(new MenuItem("DrawE", "Human E")).SetValue(true);
            _config.SubMenu("Drawings").AddItem(new MenuItem("SpiderDrawQ", "Spider Q")).SetValue(true);
            _config.SubMenu("Drawings").AddItem(new MenuItem("SpiderDrawE", "Spider E")).SetValue(true);
            _config.SubMenu("Drawings").AddItem(new MenuItem("CircleLag", "Lag Free Circles").SetValue(true));
            _config.SubMenu("Drawings").AddItem(new MenuItem("CircleQuality", "Circles Quality").SetValue(new Slider(100, 100, 10)));
            _config.SubMenu("Drawings").AddItem(new MenuItem("CircleThickness", "Circles Thickness").SetValue(new Slider(1, 10, 1)));

            _config.AddToMainMenu();
            AntiGapcloser.OnEnemyGapcloser    += AntiGapcloser_OnEnemyGapcloser;
            Interrupter.OnPossibleToInterrupt += Interrupter_OnPosibleToInterrupt;
            Obj_AI_Base.OnProcessSpellCast    += OnProcessSpellCast;
            Game.OnGameUpdate += Game_OnGameUpdate;
            Drawing.OnDraw    += Drawing_OnDraw;
            Game.PrintChat("<font color='#881df2'>D-Elise by Diabaths</font> Loaded.");
        }
Exemplo n.º 44
0
        public static void TryndamereOnLoadingComplete()
        {
            if (!_Player.CharacterName.Contains("Tryndamere"))
            {
                return;
            }
            Game.Print("Doctor's Tryndamere Loaded!", Color.Orange);
            Q = new Spell(SpellSlot.Q);
            W = new Spell(SpellSlot.W, 800);
            E = new Spell(SpellSlot.E, 660);
            W.SetSkillshot(250, 700, 92, false, false, SkillshotType.Line);
            R      = new Spell(SpellSlot.R, 500);
            Ignite = new Spell(ObjectManager.Player.GetSpellSlot("summonerdot"), 600);
            thm    = new Font(Drawing.Direct3DDevice, new FontDescription {
                FaceName = "Tahoma", Height = 15, Weight = FontWeight.Bold, OutputPrecision = FontPrecision.Default, Quality = FontQuality.ClearType
            });
            thn = new Font(Drawing.Direct3DDevice, new FontDescription {
                FaceName = "Tahoma", Height = 22, Weight = FontWeight.Bold, OutputPrecision = FontPrecision.Default, Quality = FontQuality.ClearType
            });
            Tiamat = new Item(ItemId.Tiamat_Melee_Only, 400);
            Hydra  = new Item(ItemId.Ravenous_Hydra_Melee_Only, 400);
            Botrk  = new Item(ItemId.Blade_of_the_Ruined_King, 400);
            Bil    = new Item(3144, 475f);
            var MenuTryndamare = new Menu("Tryndamare", "Tryndamare", true);

            ComboMenu = new Menu("Combo Settings", "Combo");
            ComboMenu.Add(new MenuSeparator("Combo Settings", "Combo Settings"));
            ComboMenu.Add(new MenuBool("ComboW", "Use [W] Combo"));
            ComboMenu.Add(new MenuBool("ComboW2", "Only Use [W] If [E] Is CoolDown", false));
            ComboMenu.Add(new MenuBool("ComboE", "Use [E] Combo"));
            ComboMenu.Add(new MenuSlider("DisE", "Use [E] If Enemy Distance >", 300, 0, 600));
            ComboMenu.Add(new MenuKeyBind("CTurret", "Don't Use [E] UnderTurret", System.Windows.Forms.Keys.T, KeyBindType.Toggle));
            ComboMenu.Add(new MenuSeparator("Items Settings", "Items Settings"));
            ComboMenu.Add(new MenuBool("hydra", "Use [Hydra] Reset AA"));
            ComboMenu.Add(new MenuBool("BOTRK", "Use [Botrk]"));
            ComboMenu.Add(new MenuSlider("ihp", "My HP Use BOTRK", 50));
            ComboMenu.Add(new MenuSlider("ihpp", "Enemy HP Use BOTRK", 50));
            MenuTryndamare.Add(ComboMenu);
            Ulti = new Menu("Q/R Settings", "Ulti");
            Ulti.Add(new MenuSeparator("Use [R] Low Hp", "Use [R] Low Hp"));
            Ulti.Add(new MenuBool("ultiR", "Use [R] No Die"));
            Ulti.Add(new MenuSlider("MauR", "My HP Use [R] <=", 15));
            Ulti.Add(new MenuSeparator("Use [Q] Low Hp", "Use [Q] Low Hp"));
            Ulti.Add(new MenuBool("Q", "Use [Q]"));
            Ulti.Add(new MenuBool("Q2", "Only Use [Q] If [R] Is CoolDown"));
            Ulti.Add(new MenuSlider("QHp", "My HP Use [Q] <=", 30));
            Ulti.Add(new MenuSlider("Ps", "Min Fury Use [Q]", 5));
            MenuTryndamare.Add(Ulti);
            HarassMenu = new Menu("Harass Settings", "Harass");
            HarassMenu.Add(new MenuSeparator("Harass Settings", "Harass Settings"));
            HarassMenu.Add(new MenuBool("HarassW", "Use [W] Harass"));
            HarassMenu.Add(new MenuBool("HarassW2", "Only Use [W] If [E] Is CoolDown"));
            HarassMenu.Add(new MenuBool("HarassE", "Use [E] Harass"));
            HarassMenu.Add(new MenuSlider("DistanceE", "Use [E] If Enemy Distance >", 300, 0, 600));
            HarassMenu.Add(new MenuBool("HTurret", "Don't Use [E] UnderTurret"));
            MenuTryndamare.Add(HarassMenu);
            LaneClearMenu = new Menu("LaneClear Settings", "LaneClear");
            LaneClearMenu.Add(new MenuSeparator("Lane Clear Settings", "Lane Clear Settings"));
            LaneClearMenu.Add(new MenuBool("E", "Use [E] LaneClear", false));
            LaneClearMenu.Add(new MenuSlider("mine", "Min Hit Minions Use [E]", 2, 1, 6));
            MenuTryndamare.Add(LaneClearMenu);
            JungleClearMenu = new Menu("JungleClear Settings", "JungleClear");
            JungleClearMenu.Add(new MenuSeparator("JungleClear Settings", "JungleClear Settings"));
            JungleClearMenu.Add(new MenuBool("EJungle", "Use [E] JungleClear"));
            MenuTryndamare.Add(JungleClearMenu);
            KillStealMenu = new Menu("KillSteal Settings", "KillSteal");
            KillStealMenu.Add(new MenuSeparator("KillSteal Settings", "KillSteal Settings"));
            KillStealMenu.Add(new MenuBool("KsE", "Use [E] KillSteal", false));
            KillStealMenu.Add(new MenuBool("ign", "Use [Ignite] KillSteal"));
            MenuTryndamare.Add(KillStealMenu);
            Misc = new Menu("Misc Settings", "Misc");
            Misc.Add(new MenuSeparator("Skin Settings", "Skin Settings"));
            Misc.Add(new MenuBool("checkSkin", "Use Skin Changer", false));
            Misc.Add(new MenuSlider("skin.Id", "Skin Mode", 0, 0, 8));
            Misc.Add(new MenuSeparator("Drawing Settings", "Drawing Settings"));
            Misc.Add(new MenuBool("DrawE", "E Range"));
            Misc.Add(new MenuBool("DrawW", "W Range"));
            Misc.Add(new MenuBool("Damage", "Damage Indicator"));
            Misc.Add(new MenuBool("DrawTR", "Draw Text Under Turret"));
            Misc.Add(new MenuBool("DrawTime", "Draw Time [R]"));
            ObjectManager.Player.SetSkin(Misc["skin.Id"].GetValue <MenuSlider>().Value);
            Misc["skin.Id"].GetValue <MenuSlider>().DisplayName = ObjectManager.Player.SkinName;
            MenuTryndamare.Add(Misc);
            MenuTryndamare.Attach();
            Drawing.OnDraw     += Drawing_OnDraw;
            Game.OnUpdate      += Game_OnUpdate;
            Orbwalker.OnAction += ResetAttack;
            Drawing.OnEndScene += Damage;
        }
Exemplo n.º 45
0
            protected override RunStatus Run(object context)
            {
                const string dpsSpell = "Power Word: Shield";

                if (!Self.IsHealthPercentAbove(Settings.RenewHealth) && !Self.IsBuffOnMe("Renew") && Spell.CanCast("Renew"))
                {
                    Spell.Cast("Renew", Me);
                    Utils.LagSleep();
                    while (Spell.IsGCD)
                    {
                        System.Threading.Thread.Sleep(250);
                    }
                }


                bool result = Spell.Cast(dpsSpell);

                Utils.LagSleep();

                return(result ? RunStatus.Success : RunStatus.Failure);
            }
Exemplo n.º 46
0
        //Hex: Transform a minion into a 0/1 Frog with Taunt.
        private static void Hex(TyState playerState, TyState opponentState, Controller player, Controller opponent, PlayerTask task, Spell spell)
        {
            var myMana = player.GetAvailableMana();

            playerState.BiasValue += TyStateUtility.LateReward(myMana, 3, 1.25f);
        }
Exemplo n.º 47
0
            protected override RunStatus Run(object context)
            {
                const string dpsSpell = "Flash Heal";

                // Cast PWS first if its needed
                // 6788 - Weakened Soul
                if (!Self.IsHealthPercentAbove(Settings.PowerWordShieldHealth) && !Self.IsBuffOnMe(6788, Self.AuraCheck.AllAuras) && Spell.CanCast("Power Word: Shield"))
                {
                    Spell.Cast("Power Word: Shield", Me);
                    Utils.LagSleep();
                    while (Spell.IsGCD)
                    {
                        System.Threading.Thread.Sleep(250);
                    }
                }

                // Inner Focus on low mana
                //if (!Self.IsPowerPercentAbove(Settings.InnerFocusMana) && Spell.CanCast("Inner Focus") && !Self.IsBuffOnMe("Inner Focus"))
                if (Spell.CanCast("Inner Focus") && !Self.IsBuffOnMe("Inner Focus"))
                {
                    Spell.Cast("Inner Focus", Me);
                    Utils.LagSleep();
                    while (Spell.IsGCD)
                    {
                        System.Threading.Thread.Sleep(250);
                    }
                }


                bool result = Spell.Cast(dpsSpell, Me);

                Utils.LagSleep();

                Utils.WaitWhileCasting(Utils.CastingBreak.HealthIsAbove, Settings.FlashHealHealth, Me);
                Timers.Reset("HealingSpells");

                return(result ? RunStatus.Success : RunStatus.Failure);
            }
Exemplo n.º 48
0
        //Maelstrom Portal: Deal 1 damage to all enemy minions. Summon a random 1-Cost minion.
        private static void MaelstromPortal(TyState playerState, TyState opponentState, Controller player, Controller opponent, PlayerTask task, Spell spell)
        {
            const int NUM_TARGET_MINIONS = 3;

            //negative if below NUM_TARGET_MINIONS, neutral at NUM_TARGET_MINIONS, then positive:
            int diff = opponentState.NumMinionsOnBoard - NUM_TARGET_MINIONS;

            playerState.BiasValue += diff * 1.25f;
        }
Exemplo n.º 49
0
        private static void OnLoad(EventArgs args)
        {
            if (player.ChampionName != ChampName)
            {
                return;
            }

            Notifications.AddNotification("JustKatarina Loaded | Give feedback on forum", 8000);
            Notifications.AddNotification("Don't forget upvote in AssemblyDB", 12000);

            //Ability Information - Range - Variables.
            Q = new Spell(SpellSlot.Q, 675f);
            W = new Spell(SpellSlot.W, 375f);
            E = new Spell(SpellSlot.E, 700f);
            R = new Spell(SpellSlot.R, 550f);

            Config = new Menu(Menun, Menun, true);
            Config.AddSubMenu(new Menu("Orbwalking", "Orbwalking"));

            var targetSelectorMenu = new Menu("Target Selector", "Target Selector");

            TargetSelector.AddToMenu(targetSelectorMenu);
            Config.AddSubMenu(targetSelectorMenu);

            Orbwalker = new Orbwalking.Orbwalker(Config.SubMenu("Orbwalking"));

            //Combo
            Config.AddSubMenu(new Menu("Combo", "Combo"));
            Config.SubMenu("Combo").AddItem(new MenuItem("UseQ", "Use Q").SetValue(true));
            Config.SubMenu("Combo").AddItem(new MenuItem("UseW", "Use W").SetValue(true));
            Config.SubMenu("Combo").AddItem(new MenuItem("UseE", "Use E").SetValue(true));
            Config.SubMenu("Combo").AddItem(new MenuItem("UseR", "Use R").SetValue(true));

            //Harass
            Config.AddSubMenu(new Menu("Harass", "Harass"));
            Config.SubMenu("Harass").AddItem(new MenuItem("harassmode", "Harass Mode").SetValue(
                                                 new StringList(new[] { "Q-E-W", "E-Q-W" }, 1)));
            Config.SubMenu("Harass").AddItem(new MenuItem("hQ", "Use Q").SetValue(true));
            Config.SubMenu("Harass").AddItem(new MenuItem("hW", "Use W").SetValue(true));
            Config.SubMenu("Harass").AddItem(new MenuItem("hE", "Use E").SetValue(true));
            Config.SubMenu("Harass")
            .AddItem(
                new MenuItem("AutoHarass", "Auto Harass", true).SetValue(new KeyBind("J".ToCharArray()[0],
                                                                                     KeyBindType.Toggle)));
            Config.SubMenu("Harass").AddItem(new MenuItem("aQ", "Use Q for Auto Harass").SetValue(true));
            Config.SubMenu("Harass").AddItem(new MenuItem("aW", "Use W for Auto Harass").SetValue(true));

            //Farm
            Config.AddSubMenu(new Menu("Farm", "Farm"));
            Config.SubMenu("Farm")
            .AddItem(
                new MenuItem("AutoFarm", "Auto Farm", true).SetValue(new KeyBind("X".ToCharArray()[0],
                                                                                 KeyBindType.Toggle)));
            Config.SubMenu("Farm").AddItem(new MenuItem("fq", "Use Q for Auto Farm").SetValue(true));
            Config.SubMenu("Farm").AddItem(new MenuItem("fw", "Use W for Auto Farm").SetValue(true));

            //Item
            Config.AddSubMenu(new Menu("Item", "Item"));
            Config.SubMenu("Item").AddItem(new MenuItem("useGhostblade", "Use Youmuu's Ghostblade").SetValue(true));
            Config.SubMenu("Item").AddItem(new MenuItem("UseBOTRK", "Use Blade of the Ruined King").SetValue(true));
            Config.SubMenu("Item").AddItem(new MenuItem("eL", "  Enemy HP Percentage").SetValue(new Slider(80, 0, 100)));
            Config.SubMenu("Item").AddItem(new MenuItem("oL", "  Own HP Percentage").SetValue(new Slider(65, 0, 100)));
            Config.SubMenu("Item").AddItem(new MenuItem("UseBilge", "Use Bilgewater Cutlass").SetValue(true));
            Config.SubMenu("Item")
            .AddItem(new MenuItem("HLe", "  Enemy HP Percentage").SetValue(new Slider(80, 0, 100)));
            Config.SubMenu("Item").AddItem(new MenuItem("UseIgnite", "Use Ignite").SetValue(true));

            //Laneclear
            Config.AddSubMenu(new Menu("Clear", "Clear"));
            Config.SubMenu("Clear").AddItem(new MenuItem("lQ", "Use Q").SetValue(true));
            Config.SubMenu("Clear").AddItem(new MenuItem("lW", "Use W").SetValue(true));
            Config.SubMenu("Clear").AddItem(new MenuItem("lE", "Use E").SetValue(true));

            //Draw
            Config.AddSubMenu(new Menu("Draw", "Draw"));
            Config.SubMenu("Draw").AddItem(new MenuItem("Draw_Disabled", "Disable All Spell Drawings").SetValue(false));
            Config.SubMenu("Draw").AddItem(new MenuItem("Qdraw", "Draw Q Range").SetValue(true));
            Config.SubMenu("Draw").AddItem(new MenuItem("Wdraw", "Draw W Range").SetValue(true));
            Config.SubMenu("Draw").AddItem(new MenuItem("Edraw", "Draw E Range").SetValue(true));
            Config.SubMenu("Draw").AddItem(new MenuItem("Rdraw", "Draw R Range").SetValue(true));

            //WardJump
            Config.AddSubMenu(new Menu("Wardjump", "Wardjump"));
            Config.SubMenu("Wardjump").AddItem(new MenuItem("Wardjump", "Ward Jump").SetValue(new KeyBind("Z".ToArray()[0], KeyBindType.Press)));
            Config.SubMenu("Wardjump").AddItem(new MenuItem("newWard", "Place new ward every time").SetValue(false));
            Config.SubMenu("Wardjump").AddItem(new MenuItem("jumpWard", "Jump to Wards").SetValue(true));
            Config.SubMenu("Wardjump").AddItem(new MenuItem("jumpAlly", "Jump to Ally champions").SetValue(true));
            Config.SubMenu("Wardjump").AddItem(new MenuItem("jumpMinion", "Jump to Ally minions").SetValue(true));

            //Legitirino
            Config.AddSubMenu(new Menu("I'm LCS Player", "Legit"));
            Config.SubMenu("Legit").AddItem(new MenuItem("trylegit", "Try to be legit").SetValue(false));
            Config.SubMenu("Legit")
            .AddItem(new MenuItem("LegitCastDelayQ", "Cast Q Delay").SetValue(new Slider(2000, 0, 5000)));
            Config.SubMenu("Legit").
            AddItem(new MenuItem("LegitCastDelayE", "Cast E Delay").SetValue(new Slider(2000, 0, 5000)));

            //Misc
            Config.AddSubMenu(new Menu("Misc", "Misc"));
            Config.SubMenu("Misc").AddItem(new MenuItem("ksQ", "Killsteal with Q").SetValue(true));
            Config.SubMenu("Misc").AddItem(new MenuItem("ksW", "Killsteal with W").SetValue(false));
            Config.SubMenu("Misc").AddItem(new MenuItem("ksE", "Killsteal with E").SetValue(true));
            Config.SubMenu("Misc").AddItem(new MenuItem("rcancel", "Cancel R for KS").SetValue(false));
            Config.SubMenu("Misc").AddItem(new MenuItem("autokill", "Enable E hop for Killsteal (to minion, ally, target)").SetValue(true));
            var dmg      = new MenuItem("combodamage", "Damage Indicator").SetValue(true);
            var drawFill = new MenuItem("color", "Fill colour", true).SetValue(new Circle(true, Color.Purple));

            Config.SubMenu("Draw").AddItem(drawFill);
            Config.SubMenu("Draw").AddItem(dmg);

            DrawDamage.DamageToUnit = GetComboDamage;
            DrawDamage.Enabled      = dmg.GetValue <bool>();
            DrawDamage.Fill         = drawFill.GetValue <Circle>().Active;
            DrawDamage.FillColor    = drawFill.GetValue <Circle>().Color;

            dmg.ValueChanged += delegate(object sender, OnValueChangeEventArgs eventArgs)
            {
                DrawDamage.Enabled = eventArgs.GetNewValue <bool>();
            };

            drawFill.ValueChanged += delegate(object sender, OnValueChangeEventArgs eventArgs)
            {
                DrawDamage.Fill      = eventArgs.GetNewValue <Circle>().Active;
                DrawDamage.FillColor = eventArgs.GetNewValue <Circle>().Color;
            };

            Config.AddToMainMenu();
            Drawing.OnDraw                 += OnDraw;
            GameObject.OnCreate            += OnCreateObject;
            Obj_AI_Base.OnProcessSpellCast += OnProcessSpellCast;
            Game.OnUpdate += Game_OnGameUpdate;
            Obj_AI_Base.OnPlayAnimation += PlayAnimation;
        }
Exemplo n.º 50
0
    //OnGameLoad
    public static void Game_onGameLoad(EventArgs args)
    {
        Game.PrintChat("yetAnotherDiana by FlapperDoodle, version: " + versionNumber);
        if (ObjectManager.Player.ChampionName != "Diana")
        {
            Game.PrintChat("Please use Diana~");
            return;
        }

        //Spell Initialization
        _q = new Spell(SpellSlot.Q, 900);
        _q.SetSkillshot(0.35f, 180f, 1800f, false, SkillshotType.SkillshotCircle);
        _w = new Spell(SpellSlot.W, 240); //-10 range
        _e = new Spell(SpellSlot.E, 450);
        _r = new Spell(SpellSlot.R, 825);

        Ignite = Player.GetSpellSlot("SummonerDot");
        Smite  = Player.GetSpellSlot("SummonerSmite");

        //Main Menu
        Config = new Menu("yA-Diana", "yA-Diana", true);

        //Orbwalker
        Config.AddSubMenu(new Menu("Orbwalking", "Orbwalking"));
        _orbwalker = new Orbwalking.Orbwalker(Config.SubMenu("Orbwalking"));

        //Target Selector
        var targetSelector = new Menu("Target Selector", "Target Selector");

        TargetSelector.AddToMenu(targetSelector);
        Config.AddSubMenu(targetSelector);

        //Combo
        Config.AddSubMenu(new Menu("Combo", "Combo"));
        Config.SubMenu("Combo").AddItem(new MenuItem("Combo-Key", "Combo Key").SetValue(new KeyBind(32, KeyBindType.Press))); //Spacebar
        Config.SubMenu("Combo").AddItem(new MenuItem("Combo-Use-W", "Use W").SetValue(true));
        Config.SubMenu("Combo").AddItem(new MenuItem("Combo-Use-E", "Use E").SetValue(true));
        Config.SubMenu("Combo").AddItem(new MenuItem("Combo-Double-R", "Use R Twice").SetValue(true));
        Config.SubMenu("Combo").AddItem(new MenuItem("Combo-Jump-To-Target", "Jump To Target").SetValue(new StringList(new[] {
            "Killable",
            "On",
            "Off"
        })));

        //Killsteal
        Config.AddSubMenu(new Menu("Killsteal", "Killsteal"));
        Config.SubMenu("Killsteal").AddItem(new MenuItem("Killsteal-Enabled", "Enabled").SetValue(true));
        Config.SubMenu("Killsteal").AddItem(new MenuItem("Killsteal-Use-Q", "Use Q").SetValue(true));
        Config.SubMenu("Killsteal").AddItem(new MenuItem("Killsteal-Use-R", "Use R").SetValue(true));
        Config.SubMenu("Killsteal").AddItem(new MenuItem("Killsteal-Use-Ignite", "Use Ignite").SetValue(true));

        //Harass
        Config.AddSubMenu(new Menu("Harass", "Harass"));
        Config.SubMenu("Harass").AddItem(new MenuItem("Harass-Key", "Harass Key").SetValue(new KeyBind(67, KeyBindType.Press))); //C
        Config.SubMenu("Harass").AddItem(new MenuItem("Harass-Use-Q", "Use Q").SetValue(true));
        Config.SubMenu("Harass").AddItem(new MenuItem("Harass-Use-W", "Use W").SetValue(true));
        Config.SubMenu("Harass").AddItem(new MenuItem("Harass-MoveTo", "Move To Mouse").SetValue(true));

        //Farm
        Config.AddSubMenu(new Menu("Farm", "Farm"));
        Config.SubMenu("Farm").AddItem(new MenuItem("Farm-Key", "Farm Key").SetValue(new KeyBind(86, KeyBindType.Press))); //V
        Config.SubMenu("Farm").AddItem(new MenuItem("Use-Q-Farm", "Use Q").SetValue(true));
        Config.SubMenu("Farm").AddItem(new MenuItem("Minimum-Q-Farm", "Q - Minimum Hit").SetValue(new Slider(3, 2, 6)));
        Config.SubMenu("Farm").AddItem(new MenuItem("Use-W-Farm", "Use W").SetValue(true));
        Config.SubMenu("Farm").AddItem(new MenuItem("Minimum-W-Farm", "W - Minimum Hit").SetValue(new Slider(3, 2, 6)));
        Config.SubMenu("Farm").AddItem(new MenuItem("Farm-Mana", "Mana Limit").SetValue(new Slider(20)));

        //Jungle Farm
        Config.AddSubMenu(new Menu("Jungle Farm", "Jungle Farm"));
        Config.SubMenu("Jungle Farm").AddItem(new MenuItem("Jungle-Farm-Key", "Jungle-Farm-Key").SetValue(new KeyBind(86, KeyBindType.Press))); //V
        Config.SubMenu("Jungle Farm").AddItem(new MenuItem("Use-Q-Jungle", "Use Q").SetValue(true));
        Config.SubMenu("Jungle Farm").AddItem(new MenuItem("Use-W-Jungle", "Use W").SetValue(true));
        Config.SubMenu("Jungle Farm").AddItem(new MenuItem("Use-R-Jungle", "Use R").SetValue(new StringList(new[] {
            "With Q",
            "On",
            "Off"
        })));
        Config.SubMenu("Jungle Farm").AddItem(new MenuItem("Jungle-Mana", "Mana Limit").SetValue(new Slider(20)));

        //Items
        Config.AddSubMenu(new Menu("Items", "Items"));
        Config.SubMenu("Items").AddItem(new MenuItem("Items-Enabled", "Enabled").SetValue(true));
        //'Offensive
        Config.SubMenu("Items").AddSubMenu(new Menu("Offense", "Offense"));
        Config.SubMenu("Items").SubMenu("Offense").AddItem(new MenuItem("BilgeCut", "Bilgewater Cutlass").SetValue(true));
        Config.SubMenu("Items").SubMenu("Offense").AddItem(new MenuItem("BotRK", "Bot Ruined King").SetValue(true));
        Config.SubMenu("Items").SubMenu("Offense").AddItem(new MenuItem("DFG", "Deathfire Grasp").SetValue(true));
        Config.SubMenu("Items").SubMenu("Offense").AddItem(new MenuItem("RavHydra", "Ravenous Hydra").SetValue(true));
        Config.SubMenu("Items").SubMenu("Offense").AddItem(new MenuItem("RanOmen", "Randuin's Omen").SetValue(true));
        Config.SubMenu("Items").SubMenu("Offense").AddItem(new MenuItem("Tiamat", "Tiamat").SetValue(true));

        //'Defensive
        Config.SubMenu("Items").AddSubMenu(new Menu("Defense", "Defense"));
        //>LoTIS
        Config.SubMenu("Items").SubMenu("Defense").AddSubMenu(new Menu("LoT Iron Solari", "LoTIS-Menu"));
        Config.SubMenu("Items").SubMenu("Defense").SubMenu("LoTIS-Menu").AddItem(new MenuItem("LoTIS", "Enabled").SetValue(true));
        Config.SubMenu("Items").SubMenu("Defense").SubMenu("LoTIS-Menu").AddItem(new MenuItem("LoTIS-HP-%", "HP %").SetValue(new Slider(40)));
        //>Zhonya's
        Config.SubMenu("Items").SubMenu("Defense").AddSubMenu(new Menu("Zhonya's Hourglass", "Zhonya-Menu"));
        Config.SubMenu("Items").SubMenu("Defense").SubMenu("Zhonya-Menu").AddItem(new MenuItem("Zhonya", "Enabled").SetValue(true));
        Config.SubMenu("Items").SubMenu("Defense").SubMenu("Zhonya-Menu").AddItem(new MenuItem("Zhonya-HP-%", "HP %").SetValue(new Slider(15)));

        //Misc
        Config.AddSubMenu(new Menu("Misc", "Misc"));
        Config.SubMenu("Misc").AddItem(new MenuItem("Auto Level", "Auto Level").SetValue(true));
        Config.SubMenu("Misc").AddItem(new MenuItem("Packet Casting", "Packet Casting").SetValue(true));
        Config.SubMenu("Misc").AddItem(new MenuItem("Quick Start", "Quick Start").SetValue(new StringList(new[] {
            "Off",
            "CF,HP,2*MP",
            "CF,3*HP",
            "Jungle: HM,4*HP"
        })));

        //Drawing
        Config.AddSubMenu(new Menu("Drawing", "Drawing"));
        Config.SubMenu("Drawing").AddItem(new MenuItem("Draw", "Draw").SetValue(true));
        Config.SubMenu("Drawing").AddItem(new MenuItem("Draw R", "Draw R").SetValue(new Circle(true, System.Drawing.Color.DeepPink)));
        //>Enemy Status
        foreach (var enemy in ObjectManager.Get <Obj_AI_Hero>().Where(enemy => enemy.IsEnemy))
        {
            //Add the enemy to our dictionary, so we can update the colors
            enemyColor.Add(enemy.ChampionName, System.Drawing.Color.Green);
            //Assign a menu to each enemy
            Config.SubMenu("Drawing").AddSubMenu(new Menu(enemy.ChampionName, enemy.ChampionName));
            Config.SubMenu("Drawing").SubMenu(enemy.ChampionName).AddItem(new MenuItem(enemy.ChampionName + "E", "Enabled").SetValue(true));
            Config.SubMenu("Drawing").SubMenu(enemy.ChampionName).AddItem(new MenuItem(enemy.ChampionName + "KC", "Killable Circle").SetValue(true));
            Config.SubMenu("Drawing").SubMenu(enemy.ChampionName).AddItem(new MenuItem(enemy.ChampionName + "HP", "HP").SetValue(true));
            Config.SubMenu("Drawing").SubMenu(enemy.ChampionName).AddItem(new MenuItem(enemy.ChampionName + "MP", "MP").SetValue(true));
            Config.SubMenu("Drawing").SubMenu(enemy.ChampionName).AddItem(new MenuItem(enemy.ChampionName + "R", "Range").SetValue(new StringList(new[] {
                "Basic",
                "Q",
                "W",
                "E",
                "R"
            })));
            Config.SubMenu("Drawing").SubMenu(enemy.ChampionName).AddItem(new MenuItem(enemy.ChampionName + "RC", "Range Color").SetValue(new Circle(true, System.Drawing.Color.Gray)));
        }

        //Interrupt
        Config.AddSubMenu(new Menu("Interrupt", "Interrupt"));
        Config.SubMenu("Interrupt").AddItem(new MenuItem("Interrupt-Enabled", "Enabled").SetValue(new StringList(new[] {
            "Off in Combo",
            "On",
            "Off"
        }, 1)));
        Config.SubMenu("Interrupt").AddItem(new MenuItem("Interrupt-Use-E", "Use E").SetValue(true));
        Config.SubMenu("Interrupt").AddItem(new MenuItem("Interrupt-Use-R", "Use R").SetValue(new StringList(new[] {
            "Danger",
            "On",
            "Off"
        }, 2)));

        // Map Specific
        if (Utility.Map.GetMap()._MapType == Utility.Map.MapType.SummonersRift || Utility.Map.GetMap()._MapType == Utility.Map.MapType.HowlingAbyss)
        {
            Dfg = new Items.Item(3128, 750);
            //>Jungle Jump
            Config.SubMenu("Jungle Farm").AddSubMenu(new Menu("Jungle Jump", "Jungle Jump"));
            Config.SubMenu("Jungle Farm").SubMenu("Jungle Jump").AddItem(new MenuItem("Jungle-Jump-Key", "Jungle Jump").SetValue(new KeyBind(71, KeyBindType.Press))); //G
            Config.SubMenu("Jungle Farm").SubMenu("Jungle Jump").AddItem(new MenuItem("Jungle-Draw-Spots", "Draw Spots").SetValue(new Circle(true, System.Drawing.Color.Blue)));
            Config.SubMenu("Jungle Farm").SubMenu("Jungle Jump").AddItem(new MenuItem("Jungle-MoveTo", "Move To Mouse").SetValue(true));
        }
        else
        {
            Dfg = new Items.Item(3188, 750);
        }

        //Gap Closer
        Config.AddSubMenu(new Menu("Gap Closer", "Gap Closer"));
        Config.SubMenu("Gap Closer").AddItem(new MenuItem("GapCloser-Use-W", "Use W").SetValue(true));

        Config.AddToMainMenu();

        //Handles
        Game.OnGameUpdate           += Game_OnGameUpdate;
        Drawing.OnDraw              += Drawing_OnDraw;
        CustomEvents.Unit.OnLevelUp += Unit_OnLevelUp;
        //Farm
        Orbwalking.BeforeAttack += Orbwalking_BeforeAttack;
        //Double-Check
        Game.OnGameProcessPacket       += GameOnOnGameProcessPacket;
        Obj_AI_Base.OnProcessSpellCast += Obj_AI_Base_OnProcessSpellCast;
        //Interrupt
        Interrupter.OnPossibleToInterrupt += InterrupterOnPossibleToInterrupt;
        //Gap Closer
        AntiGapcloser.OnEnemyGapcloser += AntiGapcloserOnOnEnemyGapcloser;

        //FirstStart
        QuickStart();
    }
Exemplo n.º 51
0
        public static void OnDamage(NPCProto victim, DamageTypes damageMode, Vec3f hitLoc, Vec3f flyDir, Vob aggressor, int weaponMode, Spell spell, Item weapon, float fallDownDistanceY)
        {
            if (victim.getUserObjects("IMMORTAL") != null && (bool)victim.getUserObjects("IMMORTAL"))           //Victim is immortal!
            {
                return;
            }
            NPCProto attacker = null;

            if (aggressor is NPCProto)
            {
                attacker = (NPCProto)aggressor;
            }


            if (attacker != null && attacker.getUserObjects("FRIENDS") != null && ((List <NPCProto>)attacker.getUserObjects("FRIENDS")).Contains(victim))          //Victim is a friend!
            {
                return;
            }



            int damage = 0;

            Console.WriteLine("OnDamage: " + damageMode + " | " + weaponMode + " | " + spell + " | " + weapon + " | " + attacker);

            if (damageMode == DamageTypes.DAM_FALL)
            {
                damage = (int)(fallDownDistanceY - 500) / 100 * 20;
            }

            if (attacker != null)
            {
                if (weapon == null && weaponMode == 1)                 //1 is fist!, 2 => 1h
                {
                    damage = attacker.Strength - victim.getProtection(damageMode);
                }
                else if (weapon != null)
                {
                    damage = attacker.Strength + weapon.TotalDamage - victim.getProtection(weapon.DamageType);
                }
            }

            damage = Math.Max(damage, 5);

            bool toUnconscious = false;
            bool canKill       = true;

            if (attacker != null && victim.HP - damage <= 1)
            {
                if (damageMode == DamageTypes.DAM_BLUNT)
                {
                    canKill = false;
                }

                if (damageMode == DamageTypes.DAM_BLUNT || damageMode == DamageTypes.DAM_EDGE)
                {
                    toUnconscious = true;
                }
            }

            if (!victim.IsHuman() || !(attacker != null && attacker.IsHuman()))
            {
                toUnconscious = false;
                canKill       = true;
            }

            if (toUnconscious && !victim.isUnconscious)
            {
                damage = victim.HP - 1;
                victim.dropUnconscious(0.0f);

                if (Damages != null)
                {
                    Damages(victim, attacker, damage, true, false);
                }
            }
            else if (!canKill && victim.HP - damage <= 1)
            {
                victim.HP = 1;

                if (Damages != null)
                {
                    Damages(victim, attacker, damage, false, false);
                }
            }
            else
            {
                victim.HP -= damage;

                if (Damages != null && victim.HP <= 0)
                {
                    Damages(victim, attacker, damage, false, true);
                }
                else if (Damages != null)
                {
                    Damages(victim, attacker, damage, true, false);
                }
            }
        }
Exemplo n.º 52
0
 //aiguillde
 public XelorsPunchHandler(FightActor caster, Spell spell, Cell targetedCell, bool critical) : base(caster, spell, targetedCell, critical)
 {
 }
Exemplo n.º 53
0
        private static void Game_OnGameLoad()
        {
            if (Player.ChampionName != "Garen")
            {
                return;
            }

            Q = new Spell(SpellSlot.Q);
            W = new Spell(SpellSlot.W);
            E = new Spell(SpellSlot.E, 325f);
            R = new Spell(SpellSlot.R, 400f);

            Menu = new Menu(Player.ChampionName, Player.ChampionName, true);
            Menu orbwalkerMenu = Menu.AddSubMenu(new Menu("Orbwalker", "Orbwalker"));

            Orbwalker = new Orbwalking.Orbwalker(orbwalkerMenu);

            Menu spellMenu = Menu.AddSubMenu(new Menu("Combo", "Combo"));

            spellMenu.AddItem(new MenuItem("comQ", "Use Q").SetValue(true));
            spellMenu.AddItem(new MenuItem("comW", "Use W").SetValue(true));
            spellMenu.AddItem(new MenuItem("comE", "Use E").SetValue(true));
            spellMenu.AddItem(new MenuItem("comR", "Check Misc Menu for R Options").SetValue(false));

            var harass = new Menu("Harass", "Harass");

            Menu.AddSubMenu(harass);
            harass.AddItem(new MenuItem("harassQ", "Use Q to harass").SetValue(true));
            harass.AddItem(new MenuItem("harassE", "Use E to harass").SetValue(true));


            Menu.AddSubMenu(new Menu("Drawings", "Drawings"));
            Menu.SubMenu("Drawings").AddItem(new MenuItem("Draw_Disabled", "Disable all Drawings").SetValue(false));
            Menu.SubMenu("Drawings").AddItem(new MenuItem("Qdraw", "Draw Q Range").SetValue(true));
            Menu.SubMenu("Drawings").AddItem(new MenuItem("Wdraw", "Draw W Range").SetValue(true));
            Menu.SubMenu("Drawings").AddItem(new MenuItem("Edraw", "Draw E Range").SetValue(true));
            Menu.SubMenu("Drawings").AddItem(new MenuItem("Rdraw", "Draw R Range").SetValue(true));

            Menu.AddSubMenu(new Menu("laneclear", "laneclear"));
            Menu.SubMenu("laneclear").AddItem(new MenuItem("lQ", "use Q to Laneclear").SetValue(true));
            Menu.SubMenu("laneclear").AddItem(new MenuItem("lE", "use E to Laneclear").SetValue(true));
            Menu.SubMenu("laneclear").AddItem(new MenuItem("tQ", "use Q to Autoattack Tower").SetValue(true));

            Menu.AddSubMenu(new Menu("Jungleclear", "Jungleclear"));
            Menu.SubMenu("Jungleclear").AddItem(new MenuItem("jQ", "use Q to Jungleclear").SetValue(true));
            Menu.SubMenu("Jungleclear").AddItem(new MenuItem("jE", "use E to Jungleclear").SetValue(true));

            Menu.AddSubMenu(new Menu("Misc", "Misc"));
            Menu.SubMenu("Misc").AddItem(new MenuItem("rKS", "use R to KS").SetValue(true));
            Menu.SubMenu("Misc").AddItem(new MenuItem("QGap", "use Q to gapclose").SetValue(true));
            Menu.SubMenu("Misc").AddItem(new MenuItem("QInt", "use Q to Interrupt").SetValue(true));
            Menu.SubMenu("Misc").AddItem(new MenuItem("EHyd", "use Hydra for E Swag").SetValue(true));
            Menu.SubMenu("Misc").AddItem(new MenuItem("Randuins", "use Randuins to Slow").SetValue(true));

            Menu.AddItem(new MenuItem("Credits", "Assembly created by trooperhdx"));
            ;

            Tiamat   = new Items.Item(3077, 185);
            botrk    = new Items.Item(3153, 450);
            Randuins = new Items.Item(3143, 500);
            Hydra    = new Items.Item(3074, 185);

            Menu.AddToMainMenu();
            OnSpellCast();
            Drawing.OnDraw += OnDraw;
            Interrupter2.OnInterruptableTarget += Interrupter2_OnInterruptableTarget;
            AntiGapcloser.OnEnemyGapcloser     += AntiGapcloser_OnEnemyGapcloser;
            Orbwalking.BeforeAttack            += BeforeAA;
            Orbwalking.AfterAttack             += AfterAA;
            Orbwalking.OnAttack += OnAa;
            Game.OnUpdate       += OnUpdate;

            Chat.Print(
                "<font color='#00CC83'>trooperhdx:</font> <font color='#B6250B'>" + Player.ChampionName
                + " Loaded<font color='#00B4D2'> Dont forget to Upvote this Assembly on the Assembly Database! </font>");
        }
Exemplo n.º 54
0
        public void LoadOKTW()
        {
            #region SET SKILLS
            Q       = new Spell(SpellSlot.Q, 1030);
            Qext    = new Spell(SpellSlot.Q, 1650);
            QextCol = new Spell(SpellSlot.Q, 1650);
            Q2      = new Spell(SpellSlot.Q, 600);
            W       = new Spell(SpellSlot.W);
            W2      = new Spell(SpellSlot.W, 350);
            E       = new Spell(SpellSlot.E, 650);
            E2      = new Spell(SpellSlot.E, 240);
            R       = new Spell(SpellSlot.R);

            Q.SetSkillshot(0.25f, 70, 1450, true, SkillshotType.SkillshotLine);
            Qext.SetSkillshot(0.30f, 100, 2000, false, SkillshotType.SkillshotLine);
            QextCol.SetSkillshot(0.30f, 100, 1600, true, SkillshotType.SkillshotLine);
            Q2.SetTargetted(0.25f, float.MaxValue);
            E.SetSkillshot(0.1f, 120, float.MaxValue, false, SkillshotType.SkillshotCircle);
            E2.SetTargetted(0.25f, float.MaxValue);
            #endregion

            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("showcd", "Show cooldown", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("noti", "Show notification & line", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("onlyRdy", "Draw only ready spells", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Draw").AddItem(new MenuItem("qRange", "Q range", true).SetValue(false));

            Config.SubMenu(Player.ChampionName).SubMenu("Q Config").AddItem(new MenuItem("autoQ", "Auto Q range", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Q Config").AddItem(new MenuItem("autoQm", "Auto Q melee", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Q Config").AddItem(new MenuItem("QEforce", "force E + Q", true).SetValue(false));
            Config.SubMenu(Player.ChampionName).SubMenu("Q Config").AddItem(new MenuItem("QEsplash", "Q + E splash minion damage", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Q Config").AddItem(new MenuItem("QEsplashAdjust", "Q + E splash minion radius", true).SetValue(new Slider(150, 250, 50)));

            Config.SubMenu(Player.ChampionName).SubMenu("W Config").AddItem(new MenuItem("autoW", "Auto W range", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("W Config").AddItem(new MenuItem("autoWm", "Auto W melee", true).SetValue(true));

            Config.SubMenu(Player.ChampionName).SubMenu("E Config").AddItem(new MenuItem("autoE", "Auto E range (Q + E)", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("E Config").AddItem(new MenuItem("autoEm", "Auto E melee", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("E Config").AddItem(new MenuItem("autoEks", "E melee ks only", true).SetValue(false));

            Config.SubMenu(Player.ChampionName).SubMenu("E Config").AddItem(new MenuItem("gapE", "Gapcloser R + E", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("E Config").AddItem(new MenuItem("intE", "Interrupt spells R + Q + E", true).SetValue(true));

            Config.SubMenu(Player.ChampionName).SubMenu("R Config").AddItem(new MenuItem("autoR", "Auto R range", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("R Config").AddItem(new MenuItem("autoRm", "Auto R melee", true).SetValue(true));

            foreach (var enemy in ObjectManager.Get <Obj_AI_Hero>().Where(enemy => enemy.Team != Player.Team))
            {
                Config.SubMenu(Player.ChampionName).SubMenu("Harass").AddItem(new MenuItem("haras" + enemy.ChampionName, enemy.ChampionName).SetValue(true));
            }

            Config.SubMenu(Player.ChampionName).SubMenu("Harass").AddItem(new MenuItem("harassMana", "Harass Mana", true).SetValue(new Slider(80, 100, 0)));

            Config.SubMenu(Player.ChampionName).AddItem(new MenuItem("flee", "FLEE MODE", true).SetValue(new KeyBind("T".ToCharArray()[0], KeyBindType.Press))); //32 == space

            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("farmQ", "Lane clear Q + E range", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("farmW", "Lane clear W range && mele", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("Mana", "LaneClear Mana", true).SetValue(new Slider(80, 100, 0)));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("LCminions", "LaneClear minimum minions", true).SetValue(new Slider(2, 10, 0)));

            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleQ", "Jungle clear Q", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleW", "Jungle clear W", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleE", "Jungle clear E", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleR", "Jungle clear R", true).SetValue(true));

            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleQm", "Jungle clear Q melee", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleWm", "Jungle clear W melee", true).SetValue(true));
            Config.SubMenu(Player.ChampionName).SubMenu("Farm").AddItem(new MenuItem("jungleEm", "Jungle clear E melee", true).SetValue(true));

            Drawing.OnDraw                     += Drawing_OnDraw;
            Game.OnUpdate                      += OnUpdate;
            Orbwalking.BeforeAttack            += BeforeAttack;
            Obj_AI_Base.OnProcessSpellCast     += Obj_AI_Base_OnProcessSpellCast;
            Spellbook.OnCastSpell              += Spellbook_OnCastSpell;
            Interrupter2.OnInterruptableTarget += Interrupter2_OnInterruptableTarget;
            AntiGapcloser.OnEnemyGapcloser     += AntiGapcloser_OnEnemyGapcloser;
        }
Exemplo n.º 55
0
        public override TimeSpan OnSwing(Mobile attacker, Mobile defender)
        {
            WeaponAbility a = WeaponAbility.GetCurrentAbility(attacker);

            // Make sure we've been standing still for .25/.5/1 second depending on Era
            if (Core.TickCount - attacker.LastMoveTime >= (Core.SE ? 250 : Core.AOS ? 500 : 1000) || (Core.AOS && WeaponAbility.GetCurrentAbility(attacker) is MovingShot))
            {
                bool canSwing = true;

                if (Core.AOS)
                {
                    canSwing = (!attacker.Paralyzed && !attacker.Frozen);

                    if (canSwing)
                    {
                        Spell sp = attacker.Spell as Spell;

                        canSwing = (sp == null || !sp.IsCasting || !sp.BlocksMovement);
                    }
                }

                #region Dueling
                if (attacker is PlayerMobile)
                {
                    PlayerMobile pm = (PlayerMobile)attacker;

                    if (pm.DuelContext != null && !pm.DuelContext.CheckItemEquip(attacker, this))
                    {
                        canSwing = false;
                    }
                }
                #endregion

                if (canSwing && attacker.HarmfulCheck(defender))
                {
                    attacker.DisruptiveAction();
                    attacker.Send(new Swing(0, attacker, defender));

                    if (OnFired(attacker, defender))
                    {
                        if (CheckHit(attacker, defender))
                        {
                            OnHit(attacker, defender);
                        }
                        else
                        {
                            OnMiss(attacker, defender);
                        }
                    }
                }

                attacker.RevealingAction();

                return(GetDelay(attacker));
            }
            else
            {
                attacker.RevealingAction();

                return(TimeSpan.FromSeconds(0.25));
            }
        }
Exemplo n.º 56
0
        private void UpdateWiimoteChanged(WiimoteChangedEventArgs args)
        {
            WiimoteState ws = args.WiimoteState;

            clbButtons.SetItemChecked(0, ws.ButtonState.A);
            clbButtons.SetItemChecked(1, ws.ButtonState.B);
            clbButtons.SetItemChecked(2, ws.ButtonState.Minus);
            clbButtons.SetItemChecked(3, ws.ButtonState.Home);
            clbButtons.SetItemChecked(4, ws.ButtonState.Plus);
            clbButtons.SetItemChecked(5, ws.ButtonState.One);
            clbButtons.SetItemChecked(6, ws.ButtonState.Two);
            clbButtons.SetItemChecked(7, ws.ButtonState.Up);
            clbButtons.SetItemChecked(8, ws.ButtonState.Down);
            clbButtons.SetItemChecked(9, ws.ButtonState.Left);
            clbButtons.SetItemChecked(10, ws.ButtonState.Right);

            lblAccel.Text = ws.AccelState.Values.ToString();

            /*
             *          chkLED1.Checked = ws.LEDState.LED1;
             *          chkLED2.Checked = ws.LEDState.LED2;
             *          chkLED3.Checked = ws.LEDState.LED3;
             *          chkLED4.Checked = ws.LEDState.LED4;
             */

            switch (ws.ExtensionType)
            {
            case ExtensionType.Nunchuk:
                /*
                 *                  lblChuk.Text = ws.NunchukState.AccelState.Values.ToString();
                 *                  lblChukJoy.Text = ws.NunchukState.Joystick.ToString();
                 *                  chkC.Checked = ws.NunchukState.C;
                 *                  chkZ.Checked = ws.NunchukState.Z;
                 */
                break;

            case ExtensionType.ClassicController:
                /*
                 *                  clbCCButtons.SetItemChecked(0, ws.ClassicControllerState.ButtonState.A);
                 *                  clbCCButtons.SetItemChecked(1, ws.ClassicControllerState.ButtonState.B);
                 *                  clbCCButtons.SetItemChecked(2, ws.ClassicControllerState.ButtonState.X);
                 *                  clbCCButtons.SetItemChecked(3, ws.ClassicControllerState.ButtonState.Y);
                 *                  clbCCButtons.SetItemChecked(4, ws.ClassicControllerState.ButtonState.Minus);
                 *                  clbCCButtons.SetItemChecked(5, ws.ClassicControllerState.ButtonState.Home);
                 *                  clbCCButtons.SetItemChecked(6, ws.ClassicControllerState.ButtonState.Plus);
                 *                  clbCCButtons.SetItemChecked(7, ws.ClassicControllerState.ButtonState.Up);
                 *                  clbCCButtons.SetItemChecked(8, ws.ClassicControllerState.ButtonState.Down);
                 *                  clbCCButtons.SetItemChecked(9, ws.ClassicControllerState.ButtonState.Left);
                 *                  clbCCButtons.SetItemChecked(10, ws.ClassicControllerState.ButtonState.Right);
                 *                  clbCCButtons.SetItemChecked(11, ws.ClassicControllerState.ButtonState.ZL);
                 *                  clbCCButtons.SetItemChecked(12, ws.ClassicControllerState.ButtonState.ZR);
                 *                  clbCCButtons.SetItemChecked(13, ws.ClassicControllerState.ButtonState.TriggerL);
                 *                  clbCCButtons.SetItemChecked(14, ws.ClassicControllerState.ButtonState.TriggerR);
                 *
                 *                  lblCCJoy1.Text = ws.ClassicControllerState.JoystickL.ToString();
                 *                  lblCCJoy2.Text = ws.ClassicControllerState.JoystickR.ToString();
                 *
                 *                  lblTriggerL.Text = ws.ClassicControllerState.TriggerL.ToString();
                 *                  lblTriggerR.Text = ws.ClassicControllerState.TriggerR.ToString();
                 */
                break;

            case ExtensionType.Guitar:
                /*
                 *              clbGuitarButtons.SetItemChecked(0, ws.GuitarState.FretButtonState.Green);
                 *              clbGuitarButtons.SetItemChecked(1, ws.GuitarState.FretButtonState.Red);
                 *              clbGuitarButtons.SetItemChecked(2, ws.GuitarState.FretButtonState.Yellow);
                 *              clbGuitarButtons.SetItemChecked(3, ws.GuitarState.FretButtonState.Blue);
                 *              clbGuitarButtons.SetItemChecked(4, ws.GuitarState.FretButtonState.Orange);
                 *              clbGuitarButtons.SetItemChecked(5, ws.GuitarState.ButtonState.Minus);
                 *              clbGuitarButtons.SetItemChecked(6, ws.GuitarState.ButtonState.Plus);
                 *              clbGuitarButtons.SetItemChecked(7, ws.GuitarState.ButtonState.StrumUp);
                 *              clbGuitarButtons.SetItemChecked(8, ws.GuitarState.ButtonState.StrumDown);
                 *
                 *                  clbTouchbar.SetItemChecked(0, ws.GuitarState.TouchbarState.Green);
                 *                  clbTouchbar.SetItemChecked(1, ws.GuitarState.TouchbarState.Red);
                 *                  clbTouchbar.SetItemChecked(2, ws.GuitarState.TouchbarState.Yellow);
                 *                  clbTouchbar.SetItemChecked(3, ws.GuitarState.TouchbarState.Blue);
                 *                  clbTouchbar.SetItemChecked(4, ws.GuitarState.TouchbarState.Orange);
                 *
                 *                  lblGuitarJoy.Text = ws.GuitarState.Joystick.ToString();
                 *                  lblGuitarWhammy.Text = ws.GuitarState.WhammyBar.ToString();
                 *                  lblGuitarType.Text = ws.GuitarState.GuitarType.ToString();
                 */
                break;

            case ExtensionType.Drums:
                /*
                 *                  clbDrums.SetItemChecked(0, ws.DrumsState.Red);
                 *                  clbDrums.SetItemChecked(1, ws.DrumsState.Blue);
                 *                  clbDrums.SetItemChecked(2, ws.DrumsState.Green);
                 *                  clbDrums.SetItemChecked(3, ws.DrumsState.Yellow);
                 *                  clbDrums.SetItemChecked(4, ws.DrumsState.Orange);
                 *                  clbDrums.SetItemChecked(5, ws.DrumsState.Pedal);
                 *                  clbDrums.SetItemChecked(6, ws.DrumsState.Minus);
                 *                  clbDrums.SetItemChecked(7, ws.DrumsState.Plus);
                 *
                 *                  lbDrumVelocity.Items.Clear();
                 *                  lbDrumVelocity.Items.Add(ws.DrumsState.RedVelocity);
                 *                  lbDrumVelocity.Items.Add(ws.DrumsState.BlueVelocity);
                 *                  lbDrumVelocity.Items.Add(ws.DrumsState.GreenVelocity);
                 *                  lbDrumVelocity.Items.Add(ws.DrumsState.YellowVelocity);
                 *                  lbDrumVelocity.Items.Add(ws.DrumsState.OrangeVelocity);
                 *                  lbDrumVelocity.Items.Add(ws.DrumsState.PedalVelocity);
                 *
                 *                  lblDrumJoy.Text = ws.DrumsState.Joystick.ToString();
                 */
                break;

            case ExtensionType.BalanceBoard:
                /*
                 *                  if(chkLbs.Checked)
                 *                  {
                 *                          lblBBTL.Text = ws.BalanceBoardState.SensorValuesLb.TopLeft.ToString();
                 *                          lblBBTR.Text = ws.BalanceBoardState.SensorValuesLb.TopRight.ToString();
                 *                          lblBBBL.Text = ws.BalanceBoardState.SensorValuesLb.BottomLeft.ToString();
                 *                          lblBBBR.Text = ws.BalanceBoardState.SensorValuesLb.BottomRight.ToString();
                 *                          lblBBTotal.Text = ws.BalanceBoardState.WeightLb.ToString();
                 *                  }
                 *                  else
                 *                  {
                 *                          lblBBTL.Text = ws.BalanceBoardState.SensorValuesKg.TopLeft.ToString();
                 *                          lblBBTR.Text = ws.BalanceBoardState.SensorValuesKg.TopRight.ToString();
                 *                          lblBBBL.Text = ws.BalanceBoardState.SensorValuesKg.BottomLeft.ToString();
                 *                          lblBBBR.Text = ws.BalanceBoardState.SensorValuesKg.BottomRight.ToString();
                 *                          lblBBTotal.Text = ws.BalanceBoardState.WeightKg.ToString();
                 *                  }
                 *                  lblCOG.Text = ws.BalanceBoardState.CenterOfGravity.ToString();
                 */
                break;
            }

            irGraphics.Clear(Color.Black);
            strokesGraphics.Clear(Color.Black);

            UpdateIR(ws.IRState.IRSensors[0], lblIR1, lblIR1Raw, chkFound1, Color.Red);
            UpdateIR(ws.IRState.IRSensors[1], lblIR2, lblIR2Raw, chkFound2, Color.Blue);
            UpdateIR(ws.IRState.IRSensors[2], lblIR3, lblIR3Raw, chkFound3, Color.Yellow);
            UpdateIR(ws.IRState.IRSensors[3], lblIR4, lblIR4Raw, chkFound4, Color.Orange);

            if (ws.IRState.IRSensors[0].Found && ws.IRState.IRSensors[1].Found)
            {
                irGraphics.DrawEllipse(new Pen(Color.Green), (int)(ws.IRState.RawMidpoint.X / 4), (int)(ws.IRState.RawMidpoint.Y / 4), 2, 2);
            }


            if (ws.IRState.IRSensors[0].Found)
            {
                // Check for spell action
                trigger = wandTracker.addPosition(ws.IRState.IRSensors[0].RawPosition, DateTime.Now);
            }
            else if (ws.IRState.IRSensors[1].Found)
            {
                // Check for spell action
                trigger = wandTracker.addPosition(ws.IRState.IRSensors[1].RawPosition, DateTime.Now);
            }

            if (trigger != null) // && trigger.casting())
            {
                if (trigger.getConfidence() > maxConfidence)
                {
                    maxConfidence = trigger.getConfidence();
                }
                if (trigger.getConfidence() < minConfidence)
                {
                    minConfidence = trigger.getConfidence();
                }
                lblSpellName.Text         = trigger.GetType().Name + " - " + DateTime.Now.Subtract(wandTracker.startSpell).Seconds + " seconds";
                lblMaxConfidence.Text     = maxConfidence.ToString();
                lblMinConfidence.Text     = minConfidence.ToString();
                lblCurrentConfidence.Text = trigger.getConfidence().ToString();
            }
            else
            {
                lblSpellName.Text = "No spell";
            }

            Position previous = null;

            foreach (Position p in wandTracker.positions)
            {
                if (previous == null)
                {
                    previous = p;
                    continue;
                }
                System.Drawing.Point pointA = new System.Drawing.Point();
                System.Drawing.Point pointB = new System.Drawing.Point();
                pointA.X = (PositionStatistics.MAX_X - previous.point.X) / 4;
                pointA.Y = (PositionStatistics.MAX_Y - previous.point.Y) / 4;
                pointB.X = (PositionStatistics.MAX_X - p.point.X) / 4;
                pointB.Y = (PositionStatistics.MAX_Y - p.point.Y) / 4;
                strokesGraphics.DrawLine(new Pen(Color.Yellow), pointA, pointB);

                previous = p;
            }

            if (wandTracker.strokes != null)
            {
                foreach (Stroke stroke in wandTracker.strokes)
                {
                    /*
                     * switch (stroke.direction)
                     * {
                     *  case StrokeDirection.Bumbled:
                     *      strokesGraphics.DrawEllipse(
                     *          new Pen(Color.Purple),
                     *          (stroke.start.SystemPoint().X + stroke.end.SystemPoint().X) / 2,
                     *          (stroke.start.SystemPoint().Y + stroke.end.SystemPoint().Y) / 2,
                     *          10, 5);
                     *      strokesGraphics.DrawLine(
                     *          new Pen(Color.Red),
                     *          stroke.start.SystemPoint(),
                     *          stroke.end.SystemPoint());
                     *      break;
                     *  default:
                     *      strokesGraphics.DrawLine(
                     *          new Pen(Color.Green),
                     *          stroke.start.SystemPoint(),
                     *          stroke.end.SystemPoint());
                     *      break;
                     * }
                     */
                    /*
                     * strokesGraphics.DrawString(
                     *  stroke.direction.ToString(),
                     *  new Font(FontFamily.GenericMonospace, 12.0f, FontStyle.Bold),
                     *  new SolidBrush(Color.Orange),
                     *  (stroke.start.SystemPoint().X + stroke.end.SystemPoint().X) / 2,
                     *  (stroke.start.SystemPoint().Y + stroke.end.SystemPoint().Y) / 2);
                     */
                }
            }

            pbIR.Image      = irBitmap;
            pbStrokes.Image = strokesBitmap;

            pbBattery.Value    = (ws.Battery > 0xc8 ? 0xc8 : (int)ws.Battery);
            lblBattery.Text    = ws.Battery.ToString();
            lblDevicePath.Text = "Device Path: " + mWiimote.HIDDevicePath;
        }
Exemplo n.º 57
0
        static void Game_OnGameLoad(EventArgs args)
        {
            if (_player.ChampionName != ChampName)
            {
                return;
            }
            IgniteSlot = _player.GetSpellSlot("SummonerDot");
            smiteSlot  = _player.GetSpellSlot("SummonerSmite");
            flashSlot  = _player.GetSpellSlot("summonerflash");

            Q = new Spell(SpellSlot.Q, 1100);
            W = new Spell(SpellSlot.W, 700);
            E = new Spell(SpellSlot.E, 430);
            R = new Spell(SpellSlot.R, 375);
            Q.SetSkillshot(Q.Instance.SData.SpellCastTime, Q.Instance.SData.LineWidth, Q.Instance.SData.MissileSpeed, true, SkillshotType.SkillshotLine);
            //Base menu
            Menu = new Menu("L#涓枃绀惧尯-鐩插儳", ChampName, true);
            //Orbwalker and menu
            Menu.AddSubMenu(new Menu("|璧扮爫|", "Orbwalker"));
            LXOrbwalker.AddToMenu(Menu.SubMenu("Orbwalker"));
            //Target selector and menu
            var ts = new Menu("|鐩爣閫夋嫨|", "Target Selector");

            SimpleTs.AddToMenu(ts);
            Menu.AddSubMenu(ts);
            //Combo menu
            Menu.AddSubMenu(new Menu("|杩炴嫑|", "Combo"));
            Menu.SubMenu("Combo").AddItem(new MenuItem("useQ", "|浣跨敤| Q").SetValue(true));
            Menu.SubMenu("Combo").AddItem(new MenuItem("useQ2", "|浣跨敤| 浜屾Q").SetValue(true));
            Menu.SubMenu("Combo").AddItem(new MenuItem("useW", "|杩炴嫑浣跨敤椤虹溂|").SetValue(true));
            Menu.SubMenu("Combo").AddItem(new MenuItem("dsjk", "椤虹溂濡傛灉: "));
            Menu.SubMenu("Combo").AddItem(new MenuItem("wMode", "> AA 鑼冨洿 || > Q 鑼冨洿").SetValue(true));
            Menu.SubMenu("Combo").AddItem(new MenuItem("useE", "|浣跨敤| E").SetValue(true));
            Menu.SubMenu("Combo").AddItem(new MenuItem("useR", "|浣跨敤| R").SetValue(false));
            Menu.SubMenu("Combo").AddItem(new MenuItem("ksR", "|鑳藉嚮鏉€浣跨敤|R").SetValue(false));
            Menu.SubMenu("Combo").AddItem(new MenuItem("starCombo", "|杩炴嫑|").SetValue(new KeyBind("T".ToCharArray()[0], KeyBindType.Press)));
            Menu.SubMenu("Combo").AddItem(new MenuItem("random2ejwej", "W->Q->R->Q2"));

            var harassMenu = new Menu("|楠氭壈|", "Harass");

            harassMenu.AddItem(new MenuItem("q1H", "|浣跨敤| Q").SetValue(true));
            harassMenu.AddItem(new MenuItem("q2H", "|浣跨敤| 浜屾Q").SetValue(true));
            harassMenu.AddItem(new MenuItem("wH", "椤虹溂/鏁屼汉闂幇(绂佺敤)").SetValue(false));
            harassMenu.AddItem(new MenuItem("eH", "|浣跨敤| E").SetValue(true));
            Menu.AddSubMenu(harassMenu);

            //Jung/Wave Clear
            var waveclearMenu = new Menu("|娓呯嚎/娓呴噹|", "wjClear");

            waveclearMenu.AddItem(new MenuItem("useQClear", "|浣跨敤| Q").SetValue(true));
            waveclearMenu.AddItem(new MenuItem("useWClear", "|浣跨敤| W").SetValue(true));
            waveclearMenu.AddItem(new MenuItem("useEClear", "|浣跨敤| E").SetValue(true));
            Menu.AddSubMenu(waveclearMenu);

            //InsecMenu
            var insecMenu = new Menu("|澶ф嫑璁剧疆|锛堥噹鍖虹柉鐙楋級", "Insec");

            insecMenu.AddItem(new MenuItem("InsecEnabled", "|鍥炴棆韪").SetValue(new KeyBind("Y".ToCharArray()[0], KeyBindType.Press)));
            insecMenu.AddItem(new MenuItem("rnshsasdhjk", "|澶ф嫑 妯″紡:|"));
            insecMenu.AddItem(new MenuItem("insecMode", "宸﹂敭鍗曞嚮[寮€鍚痌 TS[鍏抽棴]").SetValue(true));
            insecMenu.AddItem(new MenuItem("insecOrbwalk", "璺熼殢榧犳爣").SetValue(true));
            insecMenu.AddItem(new MenuItem("flashInsec", "澶ф嫑浣跨敤闂幇").SetValue(false));
            insecMenu.AddItem(new MenuItem("waitForQBuff", "绛夊緟Q鍥炲").SetValue(false));
            insecMenu.AddItem(new MenuItem("22222222222222", "(鏇村揩鏇村鐨勪激瀹硘)"));
            insecMenu.AddItem(new MenuItem("insec2champs", "|澶ф嫑鍚戠洘鍙媩").SetValue(true));
            insecMenu.AddItem(new MenuItem("bonusRangeA", "|鐩熷弸鐨勫閲戣寖鍥磡").SetValue(new Slider(0, 0, 1000)));
            insecMenu.AddItem(new MenuItem("insec2tower", "|澶ф嫑鍚戝|").SetValue(true));
            insecMenu.AddItem(new MenuItem("bonusRangeT", "濉旂粰浜堣寖鍥磡e").SetValue(new Slider(0, 0, 1000)));
            insecMenu.AddItem(new MenuItem("insec2orig", "|澶ф嫑鍚戝師濮嬩綅缃畖").SetValue(true));
            insecMenu.AddItem(new MenuItem("22222222222", "--"));
            insecMenu.AddItem(new MenuItem("instaFlashInsec1", "|鎵嬪姩R|"));
            insecMenu.AddItem(new MenuItem("instaFlashInsec2", "|闂幇鍥炴棆韪㈠ぇ鎷涗綅缃畖"));
            insecMenu.AddItem(new MenuItem("instaFlashInsec", "|绁為緳闂獆").SetValue(new KeyBind("P".ToCharArray()[0], KeyBindType.Toggle)));
            Menu.AddSubMenu(insecMenu);

            var autoSmiteSettings = new Menu("| 鎯╂垝璁剧疆|", "Auto Smite Settings");

            autoSmiteSettings.AddItem(new MenuItem("smiteEnabled", "|浣跨敤鎯╂垝|").SetValue(new KeyBind("M".ToCharArray()[0], KeyBindType.Toggle)));
            autoSmiteSettings.AddItem(new MenuItem("qqSmite", "Q->鎯╂垝->Q").SetValue(true));
            autoSmiteSettings.AddItem(new MenuItem("normSmite", "|姝e父鎯╂垝|").SetValue(true));
            autoSmiteSettings.AddItem(new MenuItem("drawSmite", "|鎯╂垝鑼冨洿|").SetValue(true));
            Menu.AddSubMenu(autoSmiteSettings);

            //SaveMe Menu
            var SaveMeMenu = new Menu("|鎯╂垝淇濆瓨璁剧疆|", "Smite Save Settings");

            SaveMeMenu.AddItem(new MenuItem("smiteSave", "|涓诲姩淇濆瓨鎯╂垝璁剧疆|").SetValue(true));
            SaveMeMenu.AddItem(new MenuItem("hpPercentSM", "|WW鎯╁嚮鐨剕x%").SetValue(new Slider(10, 1)));
            SaveMeMenu.AddItem(new MenuItem("param1", "鍑绘潃闄勮繎 濡傛灉琛€閲忋劎=x%"));                // TBC
            SaveMeMenu.AddItem(new MenuItem("dBuffs", "Buffs").SetValue(true));              // TBC
            SaveMeMenu.AddItem(new MenuItem("hpBuffs", "HP %").SetValue(new Slider(30, 1))); // TBC
            SaveMeMenu.AddItem(new MenuItem("dEpics", "|鍙茶瘲|").SetValue(true));              // TBC
            SaveMeMenu.AddItem(new MenuItem("hpEpics", "HP %").SetValue(new Slider(10, 1))); // TBC
            Menu.AddSubMenu(SaveMeMenu);
            //Wardjump menu
            var wardjumpMenu = new Menu("|椤虹溂璁剧疆|", "Wardjump");

            wardjumpMenu.AddItem(
                new MenuItem("wjump", "|椤虹溂閿綅|").SetValue(new KeyBind("G".ToCharArray()[0], KeyBindType.Press)));
            wardjumpMenu.AddItem(new MenuItem("maxRange", "|鎬绘槸椤虹溂鏈€澶ц寖鍥磡").SetValue(false));
            wardjumpMenu.AddItem(new MenuItem("castInRange", "|鍙『鐪煎湪榧犳爣浣嶇疆|").SetValue(false));
            wardjumpMenu.AddItem(new MenuItem("m2m", "|浣跨敤榧犳爣绉诲姩|").SetValue(true));
            wardjumpMenu.AddItem(new MenuItem("j2m", "|璺冲悜鏈€寮辩殑浜簗").SetValue(true));
            wardjumpMenu.AddItem(new MenuItem("j2c", "|璺冲悜鏈€寮虹殑浜簗").SetValue(true));
            Menu.AddSubMenu(wardjumpMenu);

            var drawMenu = new Menu("|鑼冨洿璁剧疆|", "Drawing");

            drawMenu.AddItem(new MenuItem("DrawEnabled", "|杩炴嫑鑼冨洿|").SetValue(false));
            drawMenu.AddItem(new MenuItem("WJDraw", "|椤虹溂鑼冨洿|").SetValue(true));
            drawMenu.AddItem(new MenuItem("drawQ", "|Q 鑼冨洿|").SetValue(true));
            drawMenu.AddItem(new MenuItem("drawW", "|W 鑼冨洿|").SetValue(true));
            drawMenu.AddItem(new MenuItem("drawE", "|E 鑼冨洿|").SetValue(true));
            drawMenu.AddItem(new MenuItem("drawR", "|R 鑼冨洿|").SetValue(true));
            Menu.AddSubMenu(drawMenu);

            //Exploits
            var miscMenu = new Menu("鏉傞」璁剧疆", "Misc");

            miscMenu.AddItem(new MenuItem("NFE", "浣跨敤灏佸寘").SetValue(true));
            miscMenu.AddItem(new MenuItem("QHC", "Q |鍛戒腑鐜噟").SetValue(new StringList(new [] { "浣巪", "姝e父", "楂榺" }, 1)));
            miscMenu.AddItem(new MenuItem("IGNks", "浣跨敤鐐圭噧").SetValue(true));
            miscMenu.AddItem(new MenuItem("qSmite", "鎯╂垝 Q!").SetValue(true));
            Menu.AddSubMenu(miscMenu);
            //Make the menu visible
            Menu.AddToMainMenu();
            Menu.AddSubMenu(new Menu("L#涓枃绀惧尯", "AD"));
            Menu.SubMenu("AD").AddItem(new MenuItem("wangzhan", "www.loll35.com"));
            Menu.SubMenu("AD").AddItem(new MenuItem("qunhao", "姹夊寲缇わ細397983217"));
            Drawing.OnDraw    += Drawing_OnDraw;    // Add onDraw
            Game.OnGameUpdate += Game_OnGameUpdate; // adds OnGameUpdate (Same as onTick in bol)
            Obj_AI_Base.OnProcessSpellCast += Obj_AI_Base_OnProcessSpellCast;

            PrintMessage("鍔犺浇鎴愬姛 www.loll35.com 娆㈣繋璁块棶");
        }
Exemplo n.º 58
0
        internal static Vector3 GetPredPosition(this Spell spell, Obj_AI_Base unit, bool useRange = false)
        {
            var pos = Movement.GetPrediction(unit, spell.Delay, 1, spell.Speed).UnitPosition;

            return(useRange && spell.From.Distance(pos) >= spell.Range ? unit.ServerPosition : pos);
        }
Exemplo n.º 59
0
        //Gain 1 Mana Crystal this turn only.
        private static void TheCoin(TyState playerState, TyState opponentState, Controller player, Controller opponent, PlayerTask task, Spell spell)
        {
            var curMana = player.GetAvailableMana();
            var newMana = curMana + 1;

            bool enablesNewCards = false;

            for (int i = 0; i < player.HandZone.Count; i++)
            {
                IPlayable card = player.HandZone[i];

                //if the card can only be played after using the coin, then it is not bad:
                if (card.Cost > curMana && card.Cost <= newMana)
                {
                    enablesNewCards = true;
                    break;
                }
            }

            //if the coin does not enable to play new cards, give punishment.
            if (!enablesNewCards)
            {
                playerState.BiasValue -= 100.0f;
            }
        }
Exemplo n.º 60
0
 // constructor
 public StormEnergyTempest(GameLiving caster, Spell spell, SpellLine line) : base(caster, spell, line)
 {
 }