|
@@ -68,10 +68,10 @@ namespace DCGO.CardEffects.BT22
|
|
|
|
|
|
|
|
IEnumerator ActivateCoroutine(Hashtable hashtable)
|
|
IEnumerator ActivateCoroutine(Hashtable hashtable)
|
|
|
{
|
|
{
|
|
|
- if (CardEffectCommons.HasMatchConditionOwnersPermanent(card, IsYourOpponentDigimon))
|
|
|
|
|
|
|
+ if (CardEffectCommons.HasMatchConditionPermanent(IsYourOpponentDigimon))
|
|
|
{
|
|
{
|
|
|
Permanent selectedPermament = null;
|
|
Permanent selectedPermament = null;
|
|
|
- int maxCount = Math.Min(1, CardEffectCommons.MatchConditionOwnersPermanentCount(card, IsYourOpponentDigimon));
|
|
|
|
|
|
|
+
|
|
|
SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
|
|
SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
|
|
|
|
|
|
|
|
selectPermanentEffect.SetUp(
|
|
selectPermanentEffect.SetUp(
|
|
@@ -79,7 +79,7 @@ namespace DCGO.CardEffects.BT22
|
|
|
canTargetCondition: IsYourOpponentDigimon,
|
|
canTargetCondition: IsYourOpponentDigimon,
|
|
|
canTargetCondition_ByPreSelecetedList: null,
|
|
canTargetCondition_ByPreSelecetedList: null,
|
|
|
canEndSelectCondition: null,
|
|
canEndSelectCondition: null,
|
|
|
- maxCount: maxCount,
|
|
|
|
|
|
|
+ maxCount: 1,
|
|
|
canNoSelect: false,
|
|
canNoSelect: false,
|
|
|
canEndNotMax: false,
|
|
canEndNotMax: false,
|
|
|
selectPermanentCoroutine: SelectPermanentCoroutine,
|
|
selectPermanentCoroutine: SelectPermanentCoroutine,
|
|
@@ -100,40 +100,43 @@ namespace DCGO.CardEffects.BT22
|
|
|
yield return ContinuousController.instance.StartCoroutine(CardEffectCommons.ChangeDigimonDP(selectedPermament, -3000, EffectDuration.UntilEachTurnEnd, activateClass));
|
|
yield return ContinuousController.instance.StartCoroutine(CardEffectCommons.ChangeDigimonDP(selectedPermament, -3000, EffectDuration.UntilEachTurnEnd, activateClass));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- int levelMatchCount = card.PermanentOfThisCard().DigivolutionCards.Sum(entity =>
|
|
|
|
|
|
|
+ if (CardEffectCommons.HasMatchConditionPermanent(IsYourOpponentDigimon))
|
|
|
|
|
+ {
|
|
|
|
|
+ int levelMatchCount = card.PermanentOfThisCard().DigivolutionCards.Sum(entity =>
|
|
|
new[] { entity.IsLevel2, entity.IsLevel3, entity.IsLevel4, entity.IsLevel5, entity.IsLevel6, }
|
|
new[] { entity.IsLevel2, entity.IsLevel3, entity.IsLevel4, entity.IsLevel5, entity.IsLevel6, }
|
|
|
.Count(level => level)
|
|
.Count(level => level)
|
|
|
);
|
|
);
|
|
|
|
|
|
|
|
- if (levelMatchCount >= 2 && CardEffectCommons.HasMatchConditionOwnersPermanent(card, IsYourOpponentDigimon))
|
|
|
|
|
- {
|
|
|
|
|
- Permanent selectedPermament = null;
|
|
|
|
|
- int maxCount = Math.Min(1, CardEffectCommons.MatchConditionOpponentsPermanentCount(card, IsYourOpponentDigimon));
|
|
|
|
|
- SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
|
|
|
|
|
-
|
|
|
|
|
- selectPermanentEffect.SetUp(
|
|
|
|
|
- selectPlayer: card.Owner,
|
|
|
|
|
- canTargetCondition: IsYourOpponentDigimon,
|
|
|
|
|
- canTargetCondition_ByPreSelecetedList: null,
|
|
|
|
|
- canEndSelectCondition: null,
|
|
|
|
|
- maxCount: maxCount,
|
|
|
|
|
- canNoSelect: false,
|
|
|
|
|
- canEndNotMax: false,
|
|
|
|
|
- selectPermanentCoroutine: SelectPermanentCoroutine,
|
|
|
|
|
- afterSelectPermanentCoroutine: null,
|
|
|
|
|
- mode: SelectPermanentEffect.Mode.Custom,
|
|
|
|
|
- cardEffect: activateClass);
|
|
|
|
|
-
|
|
|
|
|
- IEnumerator SelectPermanentCoroutine(Permanent permanent)
|
|
|
|
|
|
|
+ if (levelMatchCount >= 2)
|
|
|
{
|
|
{
|
|
|
- selectedPermament = permanent;
|
|
|
|
|
- yield return null;
|
|
|
|
|
|
|
+ Permanent selectedPermament = null;
|
|
|
|
|
+ int maxCount = Math.Min(1, CardEffectCommons.MatchConditionOpponentsPermanentCount(card, IsYourOpponentDigimon));
|
|
|
|
|
+ SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
|
|
|
|
|
+
|
|
|
|
|
+ selectPermanentEffect.SetUp(
|
|
|
|
|
+ selectPlayer: card.Owner,
|
|
|
|
|
+ canTargetCondition: IsYourOpponentDigimon,
|
|
|
|
|
+ canTargetCondition_ByPreSelecetedList: null,
|
|
|
|
|
+ canEndSelectCondition: null,
|
|
|
|
|
+ maxCount: maxCount,
|
|
|
|
|
+ canNoSelect: false,
|
|
|
|
|
+ canEndNotMax: false,
|
|
|
|
|
+ selectPermanentCoroutine: SelectPermanentCoroutine,
|
|
|
|
|
+ afterSelectPermanentCoroutine: null,
|
|
|
|
|
+ mode: SelectPermanentEffect.Mode.Custom,
|
|
|
|
|
+ cardEffect: activateClass);
|
|
|
|
|
+
|
|
|
|
|
+ IEnumerator SelectPermanentCoroutine(Permanent permanent)
|
|
|
|
|
+ {
|
|
|
|
|
+ selectedPermament = permanent;
|
|
|
|
|
+ yield return null;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ selectPermanentEffect.SetUpCustomMessage("Select 1 Digimon to de-digivolve.", "The opponent is selecting 1 Digimon to de-digivolve.");
|
|
|
|
|
+ yield return ContinuousController.instance.StartCoroutine(selectPermanentEffect.Activate());
|
|
|
|
|
+
|
|
|
|
|
+ if (selectedPermament != null) yield return ContinuousController.instance.StartCoroutine(new IDegeneration(selectedPermament, 1, activateClass).Degeneration());
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
- selectPermanentEffect.SetUpCustomMessage("Select 1 Digimon to de-digivolve.", "The opponent is selecting 1 Digimon to de-digivolve.");
|
|
|
|
|
- yield return ContinuousController.instance.StartCoroutine(selectPermanentEffect.Activate());
|
|
|
|
|
-
|
|
|
|
|
- if (selectedPermament != null) yield return ContinuousController.instance.StartCoroutine(new IDegeneration(selectedPermament, 1, activateClass).Degeneration());
|
|
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -161,10 +164,10 @@ namespace DCGO.CardEffects.BT22
|
|
|
|
|
|
|
|
IEnumerator ActivateCoroutine(Hashtable hashtable)
|
|
IEnumerator ActivateCoroutine(Hashtable hashtable)
|
|
|
{
|
|
{
|
|
|
- if (CardEffectCommons.HasMatchConditionOwnersPermanent(card, IsYourOpponentDigimon))
|
|
|
|
|
|
|
+ if (CardEffectCommons.HasMatchConditionPermanent(IsYourOpponentDigimon))
|
|
|
{
|
|
{
|
|
|
Permanent selectedPermament = null;
|
|
Permanent selectedPermament = null;
|
|
|
- int maxCount = Math.Min(1, CardEffectCommons.MatchConditionOwnersPermanentCount(card, IsYourOpponentDigimon));
|
|
|
|
|
|
|
+
|
|
|
SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
|
|
SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
|
|
|
|
|
|
|
|
selectPermanentEffect.SetUp(
|
|
selectPermanentEffect.SetUp(
|
|
@@ -172,7 +175,7 @@ namespace DCGO.CardEffects.BT22
|
|
|
canTargetCondition: IsYourOpponentDigimon,
|
|
canTargetCondition: IsYourOpponentDigimon,
|
|
|
canTargetCondition_ByPreSelecetedList: null,
|
|
canTargetCondition_ByPreSelecetedList: null,
|
|
|
canEndSelectCondition: null,
|
|
canEndSelectCondition: null,
|
|
|
- maxCount: maxCount,
|
|
|
|
|
|
|
+ maxCount: 1,
|
|
|
canNoSelect: false,
|
|
canNoSelect: false,
|
|
|
canEndNotMax: false,
|
|
canEndNotMax: false,
|
|
|
selectPermanentCoroutine: SelectPermanentCoroutine,
|
|
selectPermanentCoroutine: SelectPermanentCoroutine,
|
|
@@ -193,40 +196,43 @@ namespace DCGO.CardEffects.BT22
|
|
|
yield return ContinuousController.instance.StartCoroutine(CardEffectCommons.ChangeDigimonDP(selectedPermament, -3000, EffectDuration.UntilEachTurnEnd, activateClass));
|
|
yield return ContinuousController.instance.StartCoroutine(CardEffectCommons.ChangeDigimonDP(selectedPermament, -3000, EffectDuration.UntilEachTurnEnd, activateClass));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- int levelMatchCount = card.PermanentOfThisCard().DigivolutionCards.Sum(entity =>
|
|
|
|
|
|
|
+ if (CardEffectCommons.HasMatchConditionPermanent(IsYourOpponentDigimon))
|
|
|
|
|
+ {
|
|
|
|
|
+ int levelMatchCount = card.PermanentOfThisCard().DigivolutionCards.Sum(entity =>
|
|
|
new[] { entity.IsLevel2, entity.IsLevel3, entity.IsLevel4, entity.IsLevel5, entity.IsLevel6, }
|
|
new[] { entity.IsLevel2, entity.IsLevel3, entity.IsLevel4, entity.IsLevel5, entity.IsLevel6, }
|
|
|
.Count(level => level)
|
|
.Count(level => level)
|
|
|
);
|
|
);
|
|
|
|
|
|
|
|
- if (levelMatchCount >= 2 && CardEffectCommons.HasMatchConditionOwnersPermanent(card, IsYourOpponentDigimon))
|
|
|
|
|
- {
|
|
|
|
|
- Permanent selectedPermament = null;
|
|
|
|
|
- int maxCount = Math.Min(1, CardEffectCommons.MatchConditionOpponentsPermanentCount(card, IsYourOpponentDigimon));
|
|
|
|
|
- SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
|
|
|
|
|
-
|
|
|
|
|
- selectPermanentEffect.SetUp(
|
|
|
|
|
- selectPlayer: card.Owner,
|
|
|
|
|
- canTargetCondition: IsYourOpponentDigimon,
|
|
|
|
|
- canTargetCondition_ByPreSelecetedList: null,
|
|
|
|
|
- canEndSelectCondition: null,
|
|
|
|
|
- maxCount: maxCount,
|
|
|
|
|
- canNoSelect: false,
|
|
|
|
|
- canEndNotMax: false,
|
|
|
|
|
- selectPermanentCoroutine: SelectPermanentCoroutine,
|
|
|
|
|
- afterSelectPermanentCoroutine: null,
|
|
|
|
|
- mode: SelectPermanentEffect.Mode.Custom,
|
|
|
|
|
- cardEffect: activateClass);
|
|
|
|
|
-
|
|
|
|
|
- IEnumerator SelectPermanentCoroutine(Permanent permanent)
|
|
|
|
|
|
|
+ if (levelMatchCount >= 2)
|
|
|
{
|
|
{
|
|
|
- selectedPermament = permanent;
|
|
|
|
|
- yield return null;
|
|
|
|
|
|
|
+ Permanent selectedPermament = null;
|
|
|
|
|
+ int maxCount = Math.Min(1, CardEffectCommons.MatchConditionOpponentsPermanentCount(card, IsYourOpponentDigimon));
|
|
|
|
|
+ SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
|
|
|
|
|
+
|
|
|
|
|
+ selectPermanentEffect.SetUp(
|
|
|
|
|
+ selectPlayer: card.Owner,
|
|
|
|
|
+ canTargetCondition: IsYourOpponentDigimon,
|
|
|
|
|
+ canTargetCondition_ByPreSelecetedList: null,
|
|
|
|
|
+ canEndSelectCondition: null,
|
|
|
|
|
+ maxCount: maxCount,
|
|
|
|
|
+ canNoSelect: false,
|
|
|
|
|
+ canEndNotMax: false,
|
|
|
|
|
+ selectPermanentCoroutine: SelectPermanentCoroutine,
|
|
|
|
|
+ afterSelectPermanentCoroutine: null,
|
|
|
|
|
+ mode: SelectPermanentEffect.Mode.Custom,
|
|
|
|
|
+ cardEffect: activateClass);
|
|
|
|
|
+
|
|
|
|
|
+ IEnumerator SelectPermanentCoroutine(Permanent permanent)
|
|
|
|
|
+ {
|
|
|
|
|
+ selectedPermament = permanent;
|
|
|
|
|
+ yield return null;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ selectPermanentEffect.SetUpCustomMessage("Select 1 Digimon to de-digivolve.", "The opponent is selecting 1 Digimon to de-digivolve.");
|
|
|
|
|
+ yield return ContinuousController.instance.StartCoroutine(selectPermanentEffect.Activate());
|
|
|
|
|
+
|
|
|
|
|
+ if (selectedPermament != null) yield return ContinuousController.instance.StartCoroutine(new IDegeneration(selectedPermament, 1, activateClass).Degeneration());
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
- selectPermanentEffect.SetUpCustomMessage("Select 1 Digimon to de-digivolve.", "The opponent is selecting 1 Digimon to de-digivolve.");
|
|
|
|
|
- yield return ContinuousController.instance.StartCoroutine(selectPermanentEffect.Activate());
|
|
|
|
|
-
|
|
|
|
|
- if (selectedPermament != null) yield return ContinuousController.instance.StartCoroutine(new IDegeneration(selectedPermament, 1, activateClass).Degeneration());
|
|
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|