private IEnumerator UseIncapOption3()
        {
            // "Until the start of your next turn, this card counts as a target with 1 HP that is indestructible and immune to damage."
            MakeTargetStatusEffect animate = new MakeTargetStatusEffect(1, true);

            animate.CardsToMakeTargets.IsSpecificCard = base.Card;
            animate.UntilStartOfNextTurn(base.TurnTaker);
            IEnumerator animateCoroutine = AddStatusEffect(animate);

            if (base.UseUnityCoroutines)
            {
                yield return(base.GameController.StartCoroutine(animateCoroutine));
            }
            else
            {
                base.GameController.ExhaustCoroutine(animateCoroutine);
            }
            ImmuneToDamageStatusEffect immunity = new ImmuneToDamageStatusEffect();

            immunity.TargetCriteria.IsSpecificCard = base.Card;
            immunity.UntilStartOfNextTurn(base.TurnTaker);
            IEnumerator immuneCoroutine = AddStatusEffect(immunity);

            if (base.UseUnityCoroutines)
            {
                yield return(base.GameController.StartCoroutine(immuneCoroutine));
            }
            else
            {
                base.GameController.ExhaustCoroutine(immuneCoroutine);
            }
            yield break;
        }
        public override IEnumerator UsePower(int index = 0)
        {
            List <int> numerals = new List <int>()
            {
                this.GetPowerNumeral(0, 3),              // Max HP
                this.GetPowerNumeral(1, 1),              // Number of Targets
                this.GetPowerNumeral(2, 1)               // Damage.
            };

            // You may play an ongoing.
            IEnumerator coroutine;

            coroutine = this.SelectAndPlayCardsFromHand(this.DecisionMaker, 1, false, 0, new LinqCardCriteria((Card c) => c.IsOngoing, "ongoing", true));
            if (this.UseUnityCoroutines)
            {
                yield return(this.GameController.StartCoroutine(coroutine));
            }
            else
            {
                this.GameController.ExhaustCoroutine(coroutine);
            }

            // Make distortions HP targets. (Note that this does not apply to pre-existing targets - this is a quirk of how the engine currently applies those effects.)
            MakeTargetStatusEffect makeTargetStatusEffect = new MakeTargetStatusEffect(numerals[0], false);

            makeTargetStatusEffect.CardsToMakeTargets.HasAnyOfTheseKeywords = new List <string>()
            {
                "distortion"
            };
            makeTargetStatusEffect.UntilStartOfNextTurn(this.TurnTaker);
            coroutine = this.AddStatusEffect(makeTargetStatusEffect, true);
            if (this.UseUnityCoroutines)
            {
                yield return(this.GameController.StartCoroutine(coroutine));
            }
            else
            {
                this.GameController.ExhaustCoroutine(coroutine);
            }

            SelectCardsDecision selectCardsDecision = new SelectCardsDecision(base.GameController, this.DecisionMaker, (Card c) => c.IsInPlay && c.IsDistortion, SelectionType.CardToDealDamage, null, false, null, true, true, false, new Func <int>(this.NumDistortionsToDamage), null, null, null, base.GetCardSource(null));

            coroutine = base.GameController.SelectCardsAndDoAction(selectCardsDecision, (SelectCardDecision sc) => this.DistortionDamageResponse(sc, numerals[1], numerals[2]), null, null, base.GetCardSource(null), null, false, null);
            if (this.UseUnityCoroutines)
            {
                yield return(this.GameController.StartCoroutine(coroutine));
            }
            else
            {
                this.GameController.ExhaustCoroutine(coroutine);
            }

            this.actedDistortions.Clear();
        }
        public override IEnumerator UsePower(int index = 0)
        {
            //Deal 1 Target 1 Sonic and 1 Melee Damage.
            int powerNumeral             = GetPowerNumeral(0, 1);
            int powerNumeral2            = GetPowerNumeral(1, 1);
            int powerNumeral3            = GetPowerNumeral(2, 1);
            List <DealDamageAction> list = new List <DealDamageAction>();

            list.Add(new DealDamageAction(GetCardSource(), new DamageSource(base.GameController, CharacterCard), null, powerNumeral2, DamageType.Sonic));
            list.Add(new DealDamageAction(GetCardSource(), new DamageSource(base.GameController, CharacterCard), null, powerNumeral3, DamageType.Melee));
            IEnumerator coroutine = SelectTargetsAndDealMultipleInstancesOfDamage(list, null, null, powerNumeral, powerNumeral);

            if (base.UseUnityCoroutines)
            {
                yield return(base.GameController.StartCoroutine(coroutine));
            }
            else
            {
                base.GameController.ExhaustCoroutine(coroutine);
            }

            //Until the start of your next turn treat this card as a 1 HP Hero Target.
            MakeTargetStatusEffect makeTargetStatusEffect = new MakeTargetStatusEffect(1);

            makeTargetStatusEffect.CardsToMakeTargets.IsSpecificCard = Card;
            makeTargetStatusEffect.UntilStartOfNextTurn(base.TurnTaker);
            IEnumerator coroutine2 = AddStatusEffect(makeTargetStatusEffect);

            if (base.UseUnityCoroutines)
            {
                yield return(base.GameController.StartCoroutine(coroutine2));
            }
            else
            {
                base.GameController.ExhaustCoroutine(coroutine2);
            }
            yield break;
        }
        public override IEnumerator UseIncapacitatedAbility(int index)
        {
            switch (index)
            {
            case 0:
            {
                //Up to 3 Hero Targets may gain 1 HP.
                IEnumerator coroutine = base.GameController.SelectAndGainHP(base.HeroTurnTakerController, 1, optional: false, (Card c) => c.IsHero, 3, 0, cardSource: GetCardSource());
                if (base.UseUnityCoroutines)
                {
                    yield return(base.GameController.StartCoroutine(coroutine));
                }
                else
                {
                    base.GameController.ExhaustCoroutine(coroutine);
                }
                break;
            }

            case 1:
            {
                // Each Player may shuffle a card from their trash into their deck.
                List <SelectCardDecision> storedResults = new List <SelectCardDecision>();
                IEnumerator coroutine = EachPlayerMovesCards(0, 1, SelectionType.MoveCardOnDeck, new LinqCardCriteria((Card c) => true), (HeroTurnTaker htt) => htt.Trash, (HeroTurnTaker htt) => new List <MoveCardDestination>
                    {
                        new MoveCardDestination(htt.Deck)
                    }, requiredNumberOfHeroes: 0, storedResults: storedResults);
                if (base.UseUnityCoroutines)
                {
                    yield return(base.GameController.StartCoroutine(coroutine));
                }
                else
                {
                    base.GameController.ExhaustCoroutine(coroutine);
                }
                if (DidSelectCards(storedResults))
                {
                    foreach (SelectCardDecision cardDecision in storedResults)
                    {
                        Location deck = cardDecision.SelectedCard.Owner.Deck;
                        coroutine = ShuffleDeck(DecisionMaker, deck);
                        if (base.UseUnityCoroutines)
                        {
                            yield return(base.GameController.StartCoroutine(coroutine));
                        }
                        else
                        {
                            base.GameController.ExhaustCoroutine(coroutine);
                        }
                    }
                }
                break;
            }

            case 2:
            {
                //Treat this card as a 1 HP, Indestructible Hero Target until the start of your next turn.
                MakeTargetStatusEffect makeTargetStatusEffect = new MakeTargetStatusEffect(1, isIndestructible: true);
                makeTargetStatusEffect.CardsToMakeTargets.IsSpecificCard = base.Card;
                makeTargetStatusEffect.UntilStartOfNextTurn(base.TurnTaker);
                IEnumerator coroutine3 = AddStatusEffect(makeTargetStatusEffect);
                if (base.UseUnityCoroutines)
                {
                    yield return(base.GameController.StartCoroutine(coroutine3));
                }
                else
                {
                    base.GameController.ExhaustCoroutine(coroutine3);
                }
                break;
            }
            }
            yield break;
        }