示例#1
0
        public override void PayPartial(PayCostParameters p)
        {
            var count = _hasX ? p.X : _count;

            var mp = new ModifierParameters {
                SourceCard = Card
            };

            Card.AddModifier(new AddCounters(
                                 () => new SimpleCounter(_counterType), count), mp);
        }
示例#2
0
        public override void PayPartial(PayCostParameters p)
        {
            var target = p.Targets.Cost.FirstOrDefault();

            if (target != null)
            {
                target.Card().Sacrifice();
                return;
            }

            Card.Sacrifice();
        }
示例#3
0
        public override void Pay(PayCostParameters p)
        {
            // if there is a child pay mana cost
            // additional cost will be payed as
            // part of it.
            // if not we must pay it.
            if (!HasPayMana())
            {
                PayAdditionalCost();
            }

            foreach (var cost in _costs)
            {
                cost.PayPartial(p);
            }
        }
示例#4
0
 public virtual void Pay(PayCostParameters p)
 {
     PayAdditionalCost();
     PayPartial(p);
 }
示例#5
0
 public abstract void PayPartial(PayCostParameters p);
示例#6
0
        public override void PayPartial(PayCostParameters p)
        {
            var card = p.Targets.Cost.FirstOrDefault().Card();

            card.Discard();
        }
示例#7
0
 public override void PayPartial(PayCostParameters p)
 {
     Card.Exile();
 }
示例#8
0
 public override void PayPartial(PayCostParameters p)
 {
     Card.Controller.Life -= _getAmount(Card) * p.Repeat;
 }
示例#9
0
 public override void PayPartial(PayCostParameters p)
 {
     throw new NotSupportedException("Aggregate cost cannot be child of another one.");
 }