当前位置: 首页>>代码示例>>C#>>正文


C# Spell.GetCircularFarmLocation方法代码示例

本文整理汇总了C#中LeagueSharp.Common.Spell.GetCircularFarmLocation方法的典型用法代码示例。如果您正苦于以下问题:C# Spell.GetCircularFarmLocation方法的具体用法?C# Spell.GetCircularFarmLocation怎么用?C# Spell.GetCircularFarmLocation使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在LeagueSharp.Common.Spell的用法示例。


在下文中一共展示了Spell.GetCircularFarmLocation方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: CastBasicFarm

        public static void CastBasicFarm(Spell spell)
        {
            if (!spell.IsReady())
                return;
            var minion = MinionManager.GetMinions(ObjectManager.Player.ServerPosition, spell.Range, MinionTypes.All, MinionTeam.NotAlly);

            if (minion.Count == 0)
                return;

            if (spell.Type == SkillshotType.SkillshotCircle)
            {
                spell.UpdateSourcePosition();

                var predPosition = spell.GetCircularFarmLocation(minion);

                if (predPosition.MinionsHit >= 2)
                {
                    spell.Cast(predPosition.Position);
                }
            }
            else if (spell.Type == SkillshotType.SkillshotLine || spell.Type == SkillshotType.SkillshotCone)
            {
                spell.UpdateSourcePosition();

                var predPosition = spell.GetLineFarmLocation(minion);

                if (predPosition.MinionsHit >= 2)
                    spell.Cast(predPosition.Position);
            }
        }
开发者ID:myo,项目名称:LSharp,代码行数:30,代码来源:SpellCastManager.cs

示例2: ConeFarm

 private static void ConeFarm(Spell spell, List<Obj_AI_Base> minions, int min, float overrideWidth = -1f)
 {
     var spellWidth = overrideWidth > 0 ? overrideWidth : spell.Width;
     var pred = spell.GetCircularFarmLocation(minions, spellWidth);
     if (pred.MinionsHit >= min)
     {
         spell.Cast(pred.Position);
     }
 }
开发者ID:bigback,项目名称:LeagueSharp-Dev,代码行数:9,代码来源:Casting.cs

示例3: Farm

        public static void Farm(Spell spell, int minHit = 2, float overrideWidth = -1f)
        {
            if (!spell.IsReady())
            {
                return;
            }
            var minions =
                MinionManager.GetMinions(
                    ObjectManager.Player.ServerPosition, spell.Range, MinionTypes.All, MinionTeam.NotAlly,
                    MinionOrderTypes.MaxHealth).ToList();

            if (minions.Count == 0)
            {
                return;
            }

            if (spell.Type == SkillshotType.SkillshotCircle)
            {
                spell.UpdateSourcePosition();

                var prediction = spell.GetCircularFarmLocation(minions, overrideWidth);
                if (prediction.MinionsHit >= minHit)
                {
                    spell.Cast(prediction.Position);
                }
            }
            else if (spell.Type == SkillshotType.SkillshotLine)
            {
                spell.UpdateSourcePosition();

                var prediction = spell.GetLineFarmLocation(minions, overrideWidth);
                if (prediction.MinionsHit >= minHit)
                {
                    spell.Cast(prediction.Position);
                }
            }
        }
开发者ID:lukasi273,项目名称:SFX-5.12-update,代码行数:37,代码来源:Casting.cs

示例4: GetCircularFarmLocation

            public static Vector2 GetCircularFarmLocation(Spell spell, MobTypes mobTypes = MobTypes.All,
                int minMobCount = 1)
            {
                var cVector = new Vector2();
                var rangedMinionsE = LeagueSharp.Common.MinionManager.GetMinions(ObjectManager.Player.ServerPosition,
                    spell.Range);

                var minionsE = spell.GetCircularFarmLocation(rangedMinionsE, spell.Range);
                if (minionsE.MinionsHit > minMobCount && spell.IsInRange(minionsE.Position))
                {
                    cVector = minionsE.Position;
                }

                return cVector;
            }
开发者ID:yashine59fr,项目名称:PortAIO,代码行数:15,代码来源:Utils.cs

示例5: CastBasicFarm

        protected void CastBasicFarm(Spell spell)
        {
            if(!spell.IsReady())
				return;
            var minion = MinionManager.GetMinions(Player.ServerPosition, spell.Range, MinionTypes.All, MinionTeam.NotAlly);

            if (minion.Count == 0)
                return;

            if (spell.Type == SkillshotType.SkillshotCircle)
            {
                spell.UpdateSourcePosition();

                var predPosition = spell.GetCircularFarmLocation(minion);

                if (predPosition.MinionsHit >= 2)
                {
                    spell.Cast(predPosition.Position, Player.ChampionName == "Kartus" || packets());
                }
            }
            else if (spell.Type == SkillshotType.SkillshotLine)
            {
                spell.UpdateSourcePosition();

                var predPosition = spell.GetLineFarmLocation(minion);

                if(predPosition.MinionsHit >= 2)
                    spell.Cast(predPosition.Position, packets());
            }
        }
开发者ID:leenam0910,项目名称:LSharp,代码行数:30,代码来源:Champion.cs


注:本文中的LeagueSharp.Common.Spell.GetCircularFarmLocation方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。