Browse Source

Mike Updates 1.9.9 part 3

mbunch_kascope 1 year ago
parent
commit
15ed64bf23

+ 2 - 2
Assets/CardBaseEntity/BT22/Black/Digimon/BT22_067.asset

@@ -1,3 +1,3 @@
 version https://git-lfs.github.com/spec/v1
-oid sha256:3ba4dba3c40f124709abdf2446bd149e8b7f81b5051fb965bc48ba5078852822
-size 1621
+oid sha256:23310a34ef44bc3204019b2b0852101365fe1040f0e7dcb8187be3d32a9f8a46
+size 1714

+ 2 - 2
Assets/CardBaseEntity/BT22/Green/Digimon/BT22_052_P1.asset

@@ -1,3 +1,3 @@
 version https://git-lfs.github.com/spec/v1
-oid sha256:59b7a4ce1d8590c920a7e0559380a33b2c7fb3d8ad26566403ce999a848227f9
-size 1552
+oid sha256:bc868c78038e62a8624ddba51ee3db5035d420df1d6a53c9bfed5a38669170b6
+size 1559

+ 2 - 0
Assets/CardEffect/BT10/White/BT10_086.cs

@@ -341,6 +341,7 @@ namespace DCGO.CardEffects.BT10
                                 cardEffect: activateClass);
 
                             selectCardEffect.SetIsSecurity();
+                            selectCardEffect.SetUseFaceDown();
                             selectCardEffect.SetUpCustomMessage_ShowCard("Trash card");
 
                             yield return ContinuousController.instance.StartCoroutine(selectCardEffect.Activate());
@@ -524,6 +525,7 @@ namespace DCGO.CardEffects.BT10
                                 cardEffect: activateClass);
 
                             selectCardEffect.SetIsSecurity();
+                            selectCardEffect.SetUseFaceDown();
                             selectCardEffect.SetUpCustomMessage_ShowCard("Trash card");
 
                             yield return ContinuousController.instance.StartCoroutine(selectCardEffect.Activate());

+ 0 - 1
Assets/CardEffect/BT20/Yellow/BT20_029.cs

@@ -199,7 +199,6 @@ namespace DCGO.CardEffects.BT20
                 bool CanUseCondition(Hashtable hashtable)
                 {
                     return CardEffectCommons.IsExistOnBattleAreaDigimon(card) &&
-                           CardEffectCommons.IsOwnerTurn(card) &&
                            CardEffectCommons.CanTriggerWhenDeleteOpponentDigimonByBattle(hashtable: hashtable,
                                winnerCondition: WinnerCondition, loserCondition: LoserCondition, isOnlyWinnerSurvive: false);
                 }

+ 0 - 1
Assets/CardEffect/BT20/Yellow/BT20_032.cs

@@ -175,7 +175,6 @@ namespace DCGO.CardEffects.BT20
                 bool CanUseCondition(Hashtable hashtable)
                 {
                     return CardEffectCommons.IsExistOnBattleAreaDigimon(card) &&
-                           CardEffectCommons.IsOwnerTurn(card) &&
                            CardEffectCommons.CanTriggerWhenDeleteOpponentDigimonByBattle(hashtable: hashtable,
                                winnerCondition: WinnerCondition, loserCondition: LoserCondition, isOnlyWinnerSurvive: false);
                 }

+ 0 - 1
Assets/CardEffect/BT22/Purple/BT22_068.cs

@@ -150,7 +150,6 @@ namespace DCGO.CardEffects.BT22
                 bool CanUseCondition(Hashtable hashtable)
                 {
                     return CardEffectCommons.IsExistOnBattleAreaDigimon(card) &&
-                           CardEffectCommons.IsOwnerTurn(card) &&
                            CardEffectCommons.CanTriggerWhenDeleteOpponentDigimonByBattle(hashtable: hashtable,
                                winnerCondition: WinnerCondition, loserCondition: LoserCondition, isOnlyWinnerSurvive: false);
                 }

+ 2 - 2
Assets/CardEffect/BT22/Purple/BT22_070.cs

@@ -35,7 +35,8 @@ namespace DCGO.CardEffects.BT22
 
                 bool CanUseCondition(Hashtable hashtable)
                 {
-                    return CardEffectCommons.IsExistOnBattleAreaDigimon(card) && CardEffectCommons.CanTriggerOnPlay(hashtable, card);
+                    return CardEffectCommons.IsExistOnBattleAreaDigimon(card) && 
+                           CardEffectCommons.CanTriggerWhenDigivolving(hashtable, card);
                 }
 
                 bool PermanentCondition(Permanent permanent)
@@ -151,7 +152,6 @@ namespace DCGO.CardEffects.BT22
                 bool CanUseCondition(Hashtable hashtable)
                 {
                     return CardEffectCommons.IsExistOnBattleAreaDigimon(card) &&
-                           CardEffectCommons.IsOwnerTurn(card) &&
                            CardEffectCommons.CanTriggerWhenDeleteOpponentDigimonByBattle(hashtable: hashtable,
                                winnerCondition: WinnerCondition, loserCondition: LoserCondition, isOnlyWinnerSurvive: false);
                 }

+ 14 - 0
Assets/CardEffect/BT22/Purple/BT22_075.cs

@@ -11,6 +11,20 @@ namespace DCGO.CardEffects.BT22
         {
             List<ICardEffect> cardEffects = new List<ICardEffect>();
 
+            #region Alternative Digivolution Condition
+
+            if (timing == EffectTiming.None)
+            {
+                bool PermanentCondition(Permanent targetPermanent)
+                {
+                    return targetPermanent.TopCard.EqualsTraits("Sup.");
+                }
+
+                cardEffects.Add(CardEffectFactory.AddSelfDigivolutionRequirementStaticEffect(permanentCondition: PermanentCondition, digivolutionCost: 4, ignoreDigivolutionRequirement: false, card: card, condition: null));
+            }
+
+            #endregion
+
             #region App Fusion (Roamon, Effecmon)
 
             if (timing == EffectTiming.None)

+ 1 - 2
Assets/CardEffect/BT22/White/BT22_007.cs

@@ -251,8 +251,7 @@ namespace DCGO.CardEffects.BT22
                 bool CanUseCondition(Hashtable hashtable)
                 {
                     return CardEffectCommons.CanTriggerWhenPermanentRemoveField(hashtable, IsEaterDigimon)
-                        && !CardEffectCommons.IsByEffect(hashtable, cardEffect => CardEffectCommons.IsOwnerEffect(cardEffect, card));
-                }
+                        && !CardEffectCommons.IsByEffect(hashtable, cardEffect => CardEffectCommons.IsOwnerEffect(cardEffect, card));                }
 
                 bool CanActivateCondition(Hashtable hashtable)
                 {

+ 2 - 2
Assets/CardEffect/BT22/White/BT22_082.cs

@@ -76,7 +76,7 @@ namespace DCGO.CardEffects.BT22
 
                 IEnumerator ActivateCoroutine(Hashtable hashtable)
                 {
-                    if (CardEffectCommons.HasMatchConditionOwnersPermanent(card, CanSelectOpponentsDigimonCondition))
+                    if (CardEffectCommons.HasMatchConditionPermanent(CanSelectOpponentsDigimonCondition))
                     {
                         SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
 
@@ -230,7 +230,7 @@ namespace DCGO.CardEffects.BT22
 
                 IEnumerator ActivateCoroutine(Hashtable hashtable)
                 {
-                    if (CardEffectCommons.HasMatchConditionOwnersPermanent(card, CanSelectOpponentsDigimonCondition))
+                    if (CardEffectCommons.HasMatchConditionPermanent(CanSelectOpponentsDigimonCondition))
                     {
                         SelectPermanentEffect selectPermanentEffect = GManager.instance.GetComponent<SelectPermanentEffect>();
 

+ 19 - 4
Assets/CardEffect/BT22/White/BT22_093.cs

@@ -1,3 +1,4 @@
+using DCGO.CardEntities;
 using System.Collections;
 using System.Collections.Generic;
 
@@ -85,6 +86,12 @@ namespace DCGO.CardEffects.BT22
 
                 bool CanActivateCondition(Hashtable hashtable)
                 {
+                    if(DigivolvingDigimon != null)
+                    {
+                        if (!DigivolvingCondition(DigivolvingDigimon))
+                            return false;
+
+                    }
                     return CardEffectCommons.IsExistOnField(card)
                         && CardEffectCommons.IsOwnerTurn(card)
                         && CardEffectCommons.CanActivateSuspendCostEffect(card);
@@ -92,10 +99,18 @@ namespace DCGO.CardEffects.BT22
 
                 bool DigivolvingCondition(Permanent permanent)
                 {
-                    DigivolvingDigimon = permanent;
-
-                    return permanent.TopCard.HasCSTraits
-                        && permanent.DigivolutionCards.Filter(x => x.HasLevel && x.Level == permanent.Level).Count >= 1;
+                    if (CardEffectCommons.IsOwnerPermanent(permanent, card))
+                    {
+                        if (permanent.TopCard.HasCSTraits)
+                        {
+                            if(permanent.DigivolutionCards.Filter(x => x.HasLevel && x.Level == permanent.Level).Count >= 1)
+                            {
+                                DigivolvingDigimon = permanent;
+                                return true;
+                            }
+                        }
+                    }
+                    return false;
                 }
 
                 bool CanSelectCardCondition(CardSource cardSource)

+ 7 - 38
Assets/CardEffect/BT22/Yellow/BT22_037.cs

@@ -115,7 +115,8 @@ namespace DCGO.CardEffects.BT22
                 bool CanActivateCondition(Hashtable hashtable)
                 {
                     return CardEffectCommons.IsExistOnBattleAreaDigimon(card)
-                        && CardEffectCommons.HasMatchConditionOwnersHand(card, CardCondition);
+                        && CardEffectCommons.HasMatchConditionOwnersHand(card, CardCondition) &&
+                           card.Owner.SecurityCards.Any();
                 }
 
                 bool CardCondition(CardSource cardSource)
@@ -127,47 +128,17 @@ namespace DCGO.CardEffects.BT22
 
                 IEnumerator ActivateCoroutine(Hashtable hashtable)
                 {
-                    bool isTrashingSecurity = false;
+                    #region Make Selection for Trashing Security
 
-                    if (card.Owner.SecurityCards.Any())
-                    {
-                        #region Make Selection for Trashing Security
-
-                        List<SelectionElement<bool>> selectionElements = new List<SelectionElement<bool>>()
-                        {
-                            new SelectionElement<bool>(message: $"Yes", value : true, spriteIndex: 0),
-                            new SelectionElement<bool>(message: $"No", value : false, spriteIndex: 1),
-                        };
-
-                        string selectPlayerMessage = "Trash top security to digivolve?";
-                        string notSelectPlayerMessage = "The opponent is choosing to trash top secuirty.";
-
-                        GManager.instance.userSelectionManager.SetBoolSelection(selectionElements: selectionElements, selectPlayer: card.Owner, selectPlayerMessage: selectPlayerMessage, notSelectPlayerMessage: notSelectPlayerMessage);
-                        yield return ContinuousController.instance.StartCoroutine(GManager.instance.userSelectionManager.WaitForEndSelect());
-                        isTrashingSecurity = GManager.instance.userSelectionManager.SelectedBoolValue;
-
-                        #endregion
-                    }
-
-                    if (isTrashingSecurity)
-                    {
-                        #region Trash Top Security And Check
-
-                        CardSource topSec = card.Owner.SecurityCards.FirstOrDefault();
-
-                        yield return ContinuousController.instance.StartCoroutine(new IDestroySecurity(
-                        player: card.Owner.Enemy,
+                    yield return ContinuousController.instance.StartCoroutine(new IDestroySecurity(
+                        player: card.Owner,
                         destroySecurityCount: 1,
                         cardEffect: activateClass,
                         fromTop: true).DestroySecurity());
 
-                        List<CardSource> DiscardedCards = CardEffectCommons.GetDiscardedCardsFromHashtable(hashtable);
-
-                        #endregion
+                    #endregion
 
-                        if (DiscardedCards.Contains(topSec))
-                        {
-                            yield return ContinuousController.instance.StartCoroutine(
+                    yield return ContinuousController.instance.StartCoroutine(
                                 CardEffectCommons.DigivolveIntoHandOrTrashCard(
                                     targetPermanent: card.PermanentOfThisCard(),
                                     cardCondition: CardCondition,
@@ -178,8 +149,6 @@ namespace DCGO.CardEffects.BT22
                                     isHand: true,
                                     activateClass: activateClass,
                                     successProcess: null));
-                        }
-                    }
                 }
             }
 

+ 1 - 3
Assets/CardEffect/BT22/Yellow/BT22_041.cs

@@ -253,12 +253,10 @@ namespace DCGO.CardEffects.BT22
 
                 IEnumerator ActivateCoroutine(Hashtable hashtable)
                 {
-                    CardSource cardSource = card.Owner.SecurityCards[0];
-
                     yield return ContinuousController.instance.StartCoroutine(
                         new IDestroySecurity(card.Owner, 1, activateClass, true).DestroySecurity());
 
-                    if (CardEffectCommons.GetDiscardedCardsFromHashtable(hashtable).Contains(cardSource)) yield return ContinuousController.instance.StartCoroutine(
+                    yield return ContinuousController.instance.StartCoroutine(
                         new IUnsuspendPermanents(new List<Permanent>() { card.PermanentOfThisCard() }, activateClass).Unsuspend());
                 }
             }

+ 3 - 0
Assets/CardEffect/BT8/White/BT8_084.cs

@@ -308,6 +308,9 @@ public class BT8_084 : CEntity_Effect
                         {
                             foreach (CardSource cardSource1 in card.PermanentOfThisCard().DigivolutionCards)
                             {
+                                if (cardSource1.IsFlipped)
+                                    continue;
+
                                 foreach (CardColor cardColor in cardSource1.CardColors)
                                 {
                                     if (!CardColors.Contains(cardColor))

+ 2 - 0
Assets/CardEffect/EX2/White/EX2_072.cs

@@ -98,6 +98,8 @@ namespace DCGO.CardEffects.EX2
 
                         SelectCardEffect selectCardEffect = GManager.instance.GetComponent<SelectCardEffect>();
 
+                        selectCardEffect.SetUseFaceDown();
+
                         if (maxCount >= 1)
                         {
                             selectCardEffect.SetUp(

+ 2 - 2
Assets/CardEffect/EX9/Purple/EX9_065.cs

@@ -129,7 +129,7 @@ namespace DCGO.CardEffects.EX9
 
                 bool CanSelectCardCondition(CardSource cardSource)
                 {
-                    if (cardSource.Level <= 4 && cardSource.EqualsTraits("DM"))
+                    if (cardSource.HasLevel && cardSource.Level <= 4 && cardSource.EqualsTraits("DM"))
                     {
                         if (CardEffectCommons.CanPlayAsNewPermanent(cardSource: cardSource, payCost: false, cardEffect: activateClass))
                         {
@@ -208,7 +208,7 @@ namespace DCGO.CardEffects.EX9
 
                 bool CanSelectCardCondition(CardSource cardSource)
                 {
-                    if (cardSource.Level <= 4 && cardSource.EqualsTraits("DM"))
+                    if (cardSource.HasLevel && cardSource.Level <= 4 && cardSource.EqualsTraits("DM"))
                     {
                         if (CardEffectCommons.CanPlayAsNewPermanent(cardSource: cardSource, payCost: false, cardEffect: activateClass))
                         {

+ 3 - 1
Assets/CardEffect/EX9/White/EX9_074.cs

@@ -491,7 +491,9 @@ namespace DCGO.CardEffects.EX9
 
                         if (permanentToDelete.Count > 0)
                         {
-                            yield return ContinuousController.instance.StartCoroutine(new DestroyPermanentsClass(permanentToDelete, hashtable).Destroy());
+                            Hashtable _hashtable = new Hashtable();
+                            hashtable.Add("CardEffect", activateClass);
+                            yield return ContinuousController.instance.StartCoroutine(new DestroyPermanentsClass(permanentToDelete, _hashtable).Destroy());
                         }
                     }
                 }

+ 1 - 0
Assets/CardEffect/LM/Yellow/LM_020.cs

@@ -134,6 +134,7 @@ namespace DCGO.CardEffects.LM
                                 cardEffect: activateClass);
 
                             selectCardEffect.SetIsSecurity();
+                            selectCardEffect.SetUseFaceDown();
                             selectCardEffect.SetUpCustomMessage_ShowCard("Return card to top of deck");
 
                             yield return ContinuousController.instance.StartCoroutine(selectCardEffect.Activate());

+ 3 - 2
Assets/CardEffect/P/Purple/P_192.cs

@@ -112,12 +112,13 @@ namespace DCGO.CardEffects.P
 
                 bool CanUseCondition(Hashtable hashtable)
                 {
-                    return CardEffectCommons.CanTriggerWhenDigivolving(hashtable, card);
+                    return CardEffectCommons.IsExistOnBattleAreaDigimon(card) &&
+                           CardEffectCommons.CanTriggerWhenDigivolving(hashtable, card);
                 }
 
                 bool CanActivateCondition(Hashtable hashtable)
                 {
-                    return CardEffectCommons.IsExistOnField(card);
+                    return CardEffectCommons.IsExistOnBattleAreaDigimon(card);
                 }
 
                 bool CanSelectPermanentCondition(Permanent permanent)

+ 1 - 1
Assets/CardEffect/ST9/Blue/ST9_06.cs

@@ -14,7 +14,7 @@ public class ST9_06 : CEntity_Effect
         if (timing == EffectTiming.OnEnterFieldAnyone)
         {
             ActivateClass activateClass = new ActivateClass();
-            activateClass.SetUpICardEffect("Play Digimons from digivolution carads", CanUseCondition, card);
+            activateClass.SetUpICardEffect("Play Digimon from digivolution cards", CanUseCondition, card);
             activateClass.SetUpActivateClass(CanActivateCondition, ActivateCoroutine, -1, true, EffectDiscription());
             cardEffects.Add(activateClass);
 

+ 0 - 1
Assets/Scripts/AutoProcessing.cs

@@ -159,7 +159,6 @@ public class AutoProcessing : MonoBehaviourPunCallbacks
         {
             if (permanent.TopCard != null)
             {
-                Debug.Log($"RULE CHECK: {permanent.DP}");
                 if (permanent.DP < 0)
                 {
                     if (permanent.IsPlaceToTrashDueToNotHavingDP)