Procházet zdrojové kódy

Merge pull request #963 from DCGO2/x89rt2-patch-9

Update P_182.cs
hooperk před 4 měsíci
rodič
revize
cbc1e28c99
1 změnil soubory, kde provedl 7 přidání a 12 odebrání
  1. 7 12
      Assets/Scripts/CardEffect/P/Red/P_182.cs

+ 7 - 12
Assets/Scripts/CardEffect/P/Red/P_182.cs

@@ -148,17 +148,6 @@ namespace DCGO.CardEffects.P
 
             if (timing != EffectTiming.None)
             {
-                if (CardEffectCommons.IsExistOnBattleAreaDigimon(card))
-                {
-                    Permanent thisPermanent = card.PermanentOfThisCard();
-
-                    
-                    if(Condition())
-                        thisPermanent.AddBoost(new Permanent.DPBoost("P_182", count(), Condition));
-                    else
-                        thisPermanent.RemoveBoost("P_182");
-                }
-
                 int count()
                 {
                     if (CardEffectCommons.IsExistOnBattleAreaDigimon(card))
@@ -183,6 +172,12 @@ namespace DCGO.CardEffects.P
                     return CardEffectCommons.IsExistOnBattleAreaDigimon(card) &&
                            card.PermanentOfThisCard().TopCard == card;
                 }
+
+                cardEffects.Add(CardEffectFactory.ChangeSelfDPStaticEffect<Func<int>>(
+                   changeValue: count,
+                   isInheritedEffect: false,
+                   card: card,
+                   condition: Condition));          
             }
 
             #endregion
@@ -190,4 +185,4 @@ namespace DCGO.CardEffects.P
             return cardEffects;
         }
     }
-}
+}