private IEnumerator DestroyRadiationBackResponse(DestroyCardAction action) { Card source = action.GetCardDestroyer(); TurnTaker responsibleTurnTaker = source?.Owner; //Whenever a radiation card is destroyed by a hero card, {Gray} deals that hero {H - 1} energy damage. IEnumerator coroutine; //if its not a hero destroying it do no damage if (responsibleTurnTaker != null && responsibleTurnTaker.IsHero && !responsibleTurnTaker.IsIncapacitatedOrOutOfGame) { List <Card> results = new List <Card>(); coroutine = base.FindCharacterCardToTakeDamage(responsibleTurnTaker, results, Card, Game.H - 1, DamageType.Energy); if (base.UseUnityCoroutines) { yield return(base.GameController.StartCoroutine(coroutine)); } else { base.GameController.ExhaustCoroutine(coroutine); } coroutine = base.DealDamage(base.Card, results.First(), Game.H - 1, DamageType.Energy); if (base.UseUnityCoroutines) { yield return(base.GameController.StartCoroutine(coroutine)); } else { base.GameController.ExhaustCoroutine(coroutine); } } //Whenever a copy of Radioactive Cascade is destroyed, {Gray} deals the hero with the highest HP {H - 1} energy damage. if (action.CardToDestroy.Card.Identifier == "RadioactiveCascade") { coroutine = base.DealDamageToHighestHP(base.Card, 1, (Card c) => c.IsHero, (Card c) => new int?(Game.H - 1), DamageType.Energy); if (base.UseUnityCoroutines) { yield return(base.GameController.StartCoroutine(coroutine)); } else { base.GameController.ExhaustCoroutine(coroutine); } } yield break; }
private bool LineEmUpTriggerCondition(DestroyCardAction destroyCard) { return(destroyCard.WasCardDestroyed && base.GameController.IsCardVisibleToCardSource(destroyCard.CardToDestroy.Card, base.GetCardSource()) && destroyCard.GetCardDestroyer()?.Owner == this.TurnTaker); }