public override void ProcessResults(ChosenOptions results)
        {
            var permanents = Target.Player().Battlefield.Where(Selectors[(EffectOption) results.Options[1]]);

              foreach (var permanent in permanents)
              {
            Actions[(EffectOption) results.Options[0]](permanent);
              }
        }
        public override void ProcessResults(ChosenOptions results)
        {
            var color = ChoiceToColorMap.Single(x => x.Choice.Equals(results.Options[0])).Color;

              var cardsToDiscard = Target.Player().Hand.Where(
            x => x.HasColor(color)).ToList();

              foreach (var card in cardsToDiscard)
              {
            Target.Player().DiscardCard(card);
              }
        }
        public override void ProcessResults(ChosenOptions results)
        {
            var color = ChoiceToColorMap.Single(x => x.Choice.Equals(results.Options[0])).Color;

              var modifier = new AddProtectionFromColors(color) {UntilEot = true};

              var parameters = new ModifierParameters
            {
              SourceEffect = this,
              SourceCard = Source.OwningCard
            };

              Target.Card().AddModifier(modifier, parameters);
        }
        public override void ProcessResults(ChosenOptions results)
        {
            var lifeToPay = (int) results.Options[0];

              Controller.Life -= lifeToPay;

              var p = new ModifierParameters
            {
              SourceEffect = this,
              SourceCard = Source.OwningCard,
              X = X
            };

              var addCounters = new AddCounters(() => new SimpleCounter(_counterType), lifeToPay);
              Source.OwningCard.AddModifier(addCounters, p);
        }
        public override void ProcessResults(ChosenOptions results)
        {
            var ability = (Static) Enum.Parse(
            typeof (Static),
            (string) results.Options[0]);

              var modifier = new DisableAbility(ability) {UntilEot = true};

              var mp = new ModifierParameters
            {
              SourceEffect = this,
              SourceCard = Source.OwningCard
            };

              Target.Card().AddModifier(modifier, mp);
        }
        public override void ProcessResults(ChosenOptions results)
        {
            var chosenType = (string)results.Options[0];

              var cp = new ContinuousEffectParameters
            {
              Modifier = () => new AddPowerAndToughness(-1, -1),
              CardFilter = (card, effect) => card.Is().Creature && card.Is(chosenType)
            };

              var modifier = new AddContiniousEffect(
            new ContinuousEffect(cp));

              var mp = new ModifierParameters
            {
              SourceCard = Source.OwningCard,
              SourceEffect = this
            };

              Source.OwningCard.AddModifier(modifier, mp);
        }
        public override void ProcessResults(ChosenOptions results)
        {
            var chosenType = (string) results.Options[0];

              var costModifier = new SpellCostModifier(_amount,
            (card, self) => card.Is().Creature && card.Is(chosenType));

              var addCostModifier = new AddCostModifier(costModifier);

              addCostModifier.AddLifetime(new PermanentLeavesBattlefieldLifetime(
            self => self.Modifier.SourceCard
            ));

              var mp = new ModifierParameters
            {
              SourceCard = Source.OwningCard,
              SourceEffect = this
            };

              Game.AddModifier(addCostModifier, mp);
        }
 public MachineHandler()
 {
     Result = new ChosenOptions();
 }