Exemplo n.º 1
0
 public void PruneSides(WhatSide whatSide)
 {
     Characters = Characters.Where(x =>
                                   whatSide.HasFlag(WhatSide.Friendly) && Talespire.Target.IsAlly(x.ID) ||
                                   whatSide.HasFlag(WhatSide.Enemy) && Talespire.Target.IsEnemy(x.ID) ||
                                   whatSide.HasFlag(WhatSide.Neutral) && Talespire.Target.IsNeutral(x.ID)
                                   ).ToList();
 }
Exemplo n.º 2
0
        public static int GetTargetCount(WhatSide targetStatus)
        {
            int count = 0;

            foreach (InGameCreature inGameCreature in Creatures)
            {
                if (inGameCreature.IsTargeted)
                {
                    if (targetStatus.HasFlag(WhatSide.Friendly) && inGameCreature.IsAlly)
                    {
                        count++;
                    }
                    else if (targetStatus.HasFlag(WhatSide.Enemy) && inGameCreature.IsEnemy)
                    {
                        count++;
                    }
                    else if (targetStatus.HasFlag(WhatSide.All))
                    {
                        count++;
                    }
                }
            }
            return(count);
        }