Ejemplo n.º 1
0
        protected override async Task ActAsync(IActionHost host)
        {
            var doubledCard = await host.SelectCard("Choose an Action card.", Zone.Hand, cards => cards.OfType <IActionCard>());

            if (doubledCard != null)
            {
                await host.PlayCard(doubledCard, Zone.Hand);

                await host.PlayCard(doubledCard, Zone.InPlay);
            }
        }
Ejemplo n.º 2
0
        protected override async Task ActAsync(IActionHost host)
        {
            host.AddCoins(2);

            var discarded = host.Examine(Zone.DeckTop(1)).SingleOrDefault();

            if (discarded != null && discarded.Types.Contains(CardType.Action))
            {
                host.Discard(discarded, Zone.Deck);
                if (await host.YesNo("Vassal", $"<card prefix='Play ' suffix='?'>{discarded.Name}</card>"))
                {
                    await host.PlayCard(discarded.Name, Zone.Discard);
                }
            }
        }
Ejemplo n.º 3
0
        protected override async Task ActAsync(IActionHost host)
        {
            var actions  = 0;
            var revealed = host.RevealUntil(card =>
            {
                if (card.Types.Contains(CardType.Action) && card.Name != "Golem")
                {
                    actions++;
                }
                return(actions == 2);
            });

            var revealedActions   = revealed.OfType <IActionCard>().Where(card => card.Name != "Golem").ToArray();
            var revealedInactions = revealed.Without(revealedActions).ToArray();

            host.Discard(revealedInactions, Zone.Revealed);

            // XXX reorder if 2
            foreach (var revealedAction in revealedActions)
            {
                await host.PlayCard(revealedAction, Zone.Revealed);
            }
        }
Ejemplo n.º 4
0
 public static Task PlayCard(this IActionHost host, IActionCard card)
 {
     return(host.PlayCard(card.Name, Zone.Hand));
 }
Ejemplo n.º 5
0
 public static Task PlayCard(this IActionHost host, IActionCard card, Zone from)
 {
     return(host.PlayCard(card.Name, from));
 }
Ejemplo n.º 6
0
 public static Task PlayCard(this IActionHost host, string card)
 {
     return(host.PlayCard(card, Zone.Hand));
 }