Exemplo n.º 1
0
 protected override void Act(IActionHost host)
 {
     if (host.Count(Zone.Hand) > 0)
     {
         host.Discard(Zone.Hand);
     }
     else
     {
         host.CompleteDuration();
     }
 }
Exemplo n.º 2
0
 protected override void Act(IActionHost host)
 {
     if (host.Examine(Zone.RecentPlays).Any(card => card.Name == "Outpost") || host.PreviousPlayer == host.Player)
     {
         host.CompleteDuration();
     }
     else
     {
         host.InsertExtraTurn(host.Player, host.Player);
     }
 }
Exemplo n.º 3
0
        protected override async Task ActAsync(IActionHost host)
        {
            host.DrawCards(1);
            host.AddActions(1);

            var setAside = await host.SelectCard("Choose a card to set aside.");

            if (setAside != null)
            {
                host.Attach(setAside, Zone.Hand);
            }
            else
            {
                host.CompleteDuration();
            }
        }
Exemplo n.º 4
0
        public Task ExecuteReactionAsync(IActionHost host, Zone reactFrom, Trigger triggerType, string triggerParameter)
        {
            if (reactFrom == Zone.InPlay)
            {
                if (triggerType == Trigger.BeginTurn && triggerParameter == host.Player)
                {
                    OnBeginTurn(host);
                    host.CompleteDuration();
                }
                else if (triggerType == Trigger.Attack)
                {
                    OnAttack(host, triggerParameter);
                }
                else if (triggerType == Trigger.PlayCard)
                {
                    var card = AllCards.ByName(triggerParameter);
                    OnPlayCard(host, card);
                }
            }

            return(Task.CompletedTask);
        }