Prechádzať zdrojové kódy

Fix Taut checkign wrong effect for effect immunity

hooperk 4 mesiacov pred
rodič
commit
7fd8f1e9fe

+ 4 - 2
Assets/Scripts/CardEffect/BT21/Purple/BT21_077.cs

@@ -138,7 +138,8 @@ namespace DCGO.CardEffects.BT21
                                         activateClass: activateClass));
 
                                     yield return ContinuousController.instance.StartCoroutine(CardEffectCommons.StartOfMainAttack(
-                                        targetPermanent: selectedPermanent));
+                                        targetPermanent: selectedPermanent,
+                                        cardEffect: activateClass));
                                 }
                             }
                         }
@@ -242,7 +243,8 @@ namespace DCGO.CardEffects.BT21
                                         activateClass: activateClass));
 
                                     yield return ContinuousController.instance.StartCoroutine(CardEffectCommons.StartOfMainAttack(
-                                        targetPermanent: selectedPermanent));
+                                        targetPermanent: selectedPermanent,
+                                        cardEffect: activateClass));
                                 }
                             }
                         }

+ 2 - 1
Assets/Scripts/CardEffect/EX10/Red/EX10_008.cs

@@ -84,7 +84,8 @@ namespace DCGO.CardEffects.EX10
                             activateClass: activateClass));
 
                         yield return ContinuousController.instance.StartCoroutine(CardEffectCommons.StartOfMainAttack(
-                            targetPermanent: selectedPermanment));
+                            targetPermanent: selectedPermanment,
+                            cardEffect: activateClass));
                     }
                 }
             }

+ 2 - 2
Assets/Scripts/Script/CardEffectCommons/GiveEffect/GiveEffectToPermanent/StartOfMainAttack.cs

@@ -2,7 +2,7 @@ using System.Collections;
 
 public partial class CardEffectCommons
 {
-    public static IEnumerator StartOfMainAttack(Permanent targetPermanent)
+    public static IEnumerator StartOfMainAttack(Permanent targetPermanent, ICardEffect cardEffect)
     {
         ActivateClass activateClass = new ActivateClass();
         activateClass.SetUpICardEffect("Attack with this Digimon", CanUseCondition, targetPermanent.TopCard);
@@ -35,7 +35,7 @@ public partial class CardEffectCommons
         {
             if (IsPermanentExistsOnBattleArea(targetPermanent))
             {
-                if (!targetPermanent.TopCard.CanNotBeAffected(activateClass))
+                if (!targetPermanent.TopCard.CanNotBeAffected(cardEffect))
                 {
                     if (targetPermanent.CanAttack(activateClass))
                     {