It is currently 28 Apr 2024, 06:02
   
Text Size

Overload at 95%

Moderator: CCGHQ Admins

Re: Overload at 95%

Postby NeoAnderson » 29 Aug 2014, 13:39

gorem2k wrote:i'm not really into modifying cards that works but causes the approximated 'overload' to fail. i'd rather work on finding another way to implement overload if it's still possible. the only way I see is put target outside of spell ability. because that together with another "granted depending on something" spell_ability makes it very complicated to keep track of at this point, we're pretty close to creating a 'overload spell casting manager invisible token'
Honestly it could be more simple, but the main problem was the function EffectSource():GetRef(), iwas hoping it could return a unique value for each istance of a card but it seems to return the same value for each instance of the same card. If anyone knows an alternative function who returns a unique id for each instance it could make the things more easy to handle!!!
braquio wrote:I think i found a solution:
Cyclonic Rift NEO&LBN V3.2 | Open
Code: Select all
<?xml version='1.0' encoding='UTF-8'?>
<CARD_V2 ExportVersion="1">
          <FILENAME text="NEO_LBN_CYCLONIC_RIFT_992270798" />
          <CARDNAME text="CYCLONIC_RIFT" />
          <TITLE>
            <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Cyclonic Rift]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Faille cyclonique]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Grieta ciclónica]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Rift des Sturmtiefs]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Squarcio Ciclonico]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[サイクロンの裂け目]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[회오리 균열]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Циклонический Разлом]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Fenda Ciclônica]]></LOCALISED_TEXT>
          </TITLE>
          <MULTIVERSEID value="992270798" />
          <ARTID value="992270798" />
          <ARTIST name="Chris Rahn" />
          <CASTING_COST cost="{1}{U}" />
          <FLAVOURTEXT>
            <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[The Izzet specialize in unnatural disaster.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les Izzet sont spécialisés dans les catastrophes artificielles.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Los ízzet se especializan en desastres no naturales.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Die Izzet sind auf unnatürliche Katastrophen spezialisiert.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Gli Izzet sono specializzati in catastrofi innaturali.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[イゼット団は不自然災害を専門としている。]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[이젯 길드의 특기는 부자연스러운 재해다.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Иззеты являются мастерами неприродных катастроф.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[A especialidade dos Izzet são os desastres não naturais.]]></LOCALISED_TEXT>
          </FLAVOURTEXT>
          <TYPE metaname="Instant" />
          <EXPANSION value="RTR" />
          <RARITY metaname="R" />
       
           <STATIC_ABILITY active_zone="ZONE_HAND">
                <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Return target nonland permanent you don’t control to its owner’s hand.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Renvoyez un permanent non-terrain ciblé que vous ne contrôlez pas dans la main de son propriétaire.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Regresa el permanente objetivo que no sea tierra que no controles a la mano de su propietario.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Bringe eine bleibende Karte deiner Wahl, die kein Land ist und die du nicht kontrollierst, auf die Hand ihres Besitzers zurück.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Fai tornare un permanente non terra bersaglio che non controlli in mano al suo proprietario.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[あなたがコントロールしていない土地でないパーマネント1つを対象とし、それをオーナーの手札に戻す。]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[당신이 조종하지 않는 지속물 중 대지가 아닌 지속물 한 개를 목표로 정한다. 그 지속물을 소유자의 손으로 되돌린다.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Верните целевой не являющийся землей перманент, который не находится под вашим контролем, в руку его владельца.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Devolva a permanente alvo que não seja um terreno e que você não controle para a mão de seu dono.]]></LOCALISED_TEXT>
              <CONTINUOUS_ACTION layer="0">
                   local refplayer = EffectSource():GetPlayer()
                   local Chest_Id = EffectSource():GetRef()
                   local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                   local oDC = RSN_ObjectDC()
                   if chest ~= nil then
                     local nState = chest:Get_Int(1524)
                     local nStateB =  oDC:Int_Get(1524)
                     if (nState == 1) or (nStateB == 1) then
                        EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                     else
                        EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                     end
                   else
                      chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                      chest:Set_Int(1524, 0)
                   end
               </CONTINUOUS_ACTION>
          </STATIC_ABILITY>

   <STATIC_ABILITY active_zone="ZONE_STACK">
                <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Return target nonland permanent you don’t control to its owner’s hand.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Renvoyez un permanent non-terrain ciblé que vous ne contrôlez pas dans la main de son propriétaire.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Regresa el permanente objetivo que no sea tierra que no controles a la mano de su propietario.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Bringe eine bleibende Karte deiner Wahl, die kein Land ist und die du nicht kontrollierst, auf die Hand ihres Besitzers zurück.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Fai tornare un permanente non terra bersaglio che non controlli in mano al suo proprietario.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[あなたがコントロールしていない土地でないパーマネント1つを対象とし、それをオーナーの手札に戻す。]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[당신이 조종하지 않는 지속물 중 대지가 아닌 지속물 한 개를 목표로 정한다. 그 지속물을 소유자의 손으로 되돌린다.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Верните целевой не являющийся землей перманент, который не находится под вашим контролем, в руку его владельца.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Devolva a permanente alvo que não seja um terreno e que você não controle para a mão de seu dono.]]></LOCALISED_TEXT>
              <CONTINUOUS_ACTION layer="0">
                   local refplayer = EffectSource():GetPlayer()
                   local Chest_Id = EffectSource():GetRef()
                   local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                   local oDC = RSN_ObjectDC()
                   if chest ~= nil then
                     local nState = chest:Get_Int(1524)
                     local nStateB =  oDC:Int_Get(1524)
                     if (nState == 1) or (nStateB == 1) then
                        EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                     else
                        EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                     end
                   else
                      chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                      chest:Set_Int(1524, 0)
                   end
               </CONTINUOUS_ACTION>
          </STATIC_ABILITY>

   <STATIC_ABILITY active_zone="ZONE_EXILE">
                <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Return target nonland permanent you don’t control to its owner’s hand.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Renvoyez un permanent non-terrain ciblé que vous ne contrôlez pas dans la main de son propriétaire.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Regresa el permanente objetivo que no sea tierra que no controles a la mano de su propietario.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Bringe eine bleibende Karte deiner Wahl, die kein Land ist und die du nicht kontrollierst, auf die Hand ihres Besitzers zurück.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Fai tornare un permanente non terra bersaglio che non controlli in mano al suo proprietario.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[あなたがコントロールしていない土地でないパーマネント1つを対象とし、それをオーナーの手札に戻す。]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[당신이 조종하지 않는 지속물 중 대지가 아닌 지속물 한 개를 목표로 정한다. 그 지속물을 소유자의 손으로 되돌린다.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Верните целевой не являющийся землей перманент, который не находится под вашим контролем, в руку его владельца.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Devolva a permanente alvo que não seja um terreno e que você não controle para a mão de seu dono.]]></LOCALISED_TEXT>
              <CONTINUOUS_ACTION layer="0">
                   local refplayer = EffectSource():GetPlayer()
                   local Chest_Id = EffectSource():GetRef()
                   local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                   local oDC = RSN_ObjectDC()
                   if chest ~= nil then
                     local nState = chest:Get_Int(1524)
                     local nStateB =  oDC:Int_Get(1524)
                     if (nState == 1) or (nStateB == 1) then
                        EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                     else
                        EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                     end
                   else
                      chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                      chest:Set_Int(1524, 0)
                   end
               </CONTINUOUS_ACTION>
          </STATIC_ABILITY>

          <STATIC_ABILITY active_zone="ZONE_HAND">
       <CONTINUOUS_ACTION layer="1">
          local refplayer = EffectSource():GetPlayer()
     local Chest_Id = EffectSource():GetRef()
     local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
          if chest ~= nil then
             local oDC = RSN_ObjectDC()
             local valor = oDC:Int_Get(1524)
             oDC:Int_Set(1524, 1)
             if EffectController():CanCastSpellUsingResourceCost( EffectSource(), 3 ) then
                chest:Set_Int(1525,1)   
             else
                chest:Set_Int(1525,0)
             end
              oDC:Int_Set(1524, valor)   
          else
             chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
             chest:Set_Int(1525,0)
          end
       </CONTINUOUS_ACTION>
          </STATIC_ABILITY>

         <ACTIVATED_ABILITY forced_skip="1" qualifier="Alternate"  active_zone="ZONE_HAND">
                <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Overload {6}{U} |(You may cast this spell for its overload cost. If you do, change its text by replacing all instances of "target" with "each.")|]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Surcharge {6}{U} |(Vous pouvez lancer ce sort pour son coût de surcharge. Si vous faites ainsi, modifiez son texte en remplaçant toutes les occurrences de « ciblé(e) » par « chaque ».)|]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Sobrecarga {6}{U} | (Puedes lanzar este hechizo por su coste de sobrecarga. Si lo haces, cambia su texto reemplazando "el permanente objetivo" por "cada permanente".)]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Überlast {6}{U} |(Du kannst diesen Zauber für seine Überlast-Kosten wirken. Falls du dies tust, verändere seinen Text, indem du im Text alle Vorkommen von „deiner Wahl" durch „jeder" ersetzt.)|]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Sovraccarico {6}{U} |(Puoi lanciare questa magia per il suo costo di sovraccarico. Se lo fai, cambiane il testo sostituendo "un permanente non terra bersaglio" con "ogni permanente non terra".)|]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[超過 {6}{U} |(あなたはこの呪文をその超過コストで唱えてもよい。そうした場合、あなたがコントロールしていない土地でない各パーマネントをそれぞれオーナーの手札に戻す。)|]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[과부하 {6}{U} |(당신은 과부하 비용을 지불하여 이 주문을 발동할 수 있다. 그럴 경우, 이 주문은 "당신이 조종하지 않는 지속물 중 대지가 아닌 각 지속물을 소유자의 손으로 되돌린다"로 내용이 변한다.)|]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Перегрузка {6}{U} |(Вы можете разыграть это заклинание за его стоимость Перегрузки. Если вы это делаете, измените в его тексте все слова «целевой» на «каждый».)|]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Sobrecarga {6}{U} |(Você pode conjurar esta mágica pagando seu custo de sobrecarga. Se fizer isso, altere seu texto substituindo todas as ocorrências de "a permanente alvo" por "cada permanente".)|]]></LOCALISED_TEXT>
                 <COST type="Generic">
                <PREREQUISITE>
                    local refplayer = EffectSource():GetPlayer()
                    local Chest_Id = EffectSource():GetRef()
                    local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                    if chest ~= nil then
                       return chest:Get_Int(1525) == 1
                    end   
                    return false
                 </PREREQUISITE>
              <PLAY_TIME_ACTION>
                 RSN_MarkManaAbilityStart()
              </PLAY_TIME_ACTION>
                     <PLAY_TIME_ACTION>
                   local spellToCast = EffectSource()
                        local refplayer = EffectSource():GetPlayer()
                      local Chest_Id = EffectSource():GetRef()
                      local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                      chest:Set_Int(1524, 1)
                      </PLAY_TIME_ACTION>
               </COST>
              <RESOLUTION_TIME_ACTION>
                   local spellToCast = EffectSource()
                   EffectController():CastSpellUsingResourceCost( spellToCast, 3 )
                 </RESOLUTION_TIME_ACTION>
              <RESOLUTION_TIME_ACTION>
                RSN_MarkManaAbilityEnd()
              </RESOLUTION_TIME_ACTION>
                </ACTIVATED_ABILITY>

         <SPELL_ABILITY  resource_id="1" active_zone="ZONE_ANY">
           <TARGET_DEFINITION id="0">   
             MTG():ReevaluateContinuousEffects()
                  EffectDC():Set_Int(1321, 3)
                  local filter = ClearFilter()
                  filter:SetZone( ZONE_BATTLEFIELD )
                  filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                  local subfilter = filter:AddSubFilter_Or()
                        subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                        subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
                        subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                </TARGET_DEFINITION>     
               <TARGET tag="CARD_QUERY_CHOOSE_NONLAND_PERMANENT_TO_PUT_INTO_HAND" definition="0" compartment="0" count="1"/>
               <RESOLUTION_TIME_ACTION>   
                  if EffectDC():Get_Int(1321) == 3 then
                     local refplayer = EffectSource():GetPlayer()
                     local Chest_Id = EffectSource():GetRef()
                     local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                     chest:Set_Int(1524, 0)
                     local target = EffectDC():Get_Targets(0) and EffectDC():Get_Targets(0):Get_CardPtr(0)
                     if  target ~= nil then
                         target:PutInHand()
                     end
                  end
                </RESOLUTION_TIME_ACTION>
                <FILTER filter_id="1">         
                        local filter = ClearFilter()
                        filter:SetZone( ZONE_BATTLEFIELD )
                        filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                        local subfilter = filter:AddSubFilter_Or()
                              subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                              subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                              subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                    </FILTER>
                <RESOLUTION_TIME_ACTION filter_id="1">
                    if EffectDC():Get_Int(1321) ~= 3 then
                       if FilteredCard() ~= nil then
                          FilteredCard():PutInHand()
                       end
                    end
               </RESOLUTION_TIME_ACTION>
        </SPELL_ABILITY>     

         <SPELL_ABILITY  resource_id="2" active_zone="ZONE_ANY">
               <FILTER filter_id="1">         
                    local filter = ClearFilter()
                          filter:SetZone( ZONE_BATTLEFIELD )
                          filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                          local subfilter = filter:AddSubFilter_Or()
                                subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                                subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                                subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                    </FILTER>
                       <PLAY_TIME_ACTION>
                   local refplayer = EffectSource():GetPlayer()
                   local Chest_Id = EffectSource():GetRef()
                   local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                   chest:Set_Int(1524, 0)
              local oDC = RSN_ObjectDC()
                    oDC:Int_Set(1524, 1)
                 </PLAY_TIME_ACTION>         
               <RESOLUTION_TIME_ACTION filter_id="1">
                     if FilteredCard() ~= nil then
                        FilteredCard():PutInHand()
                     end
               </RESOLUTION_TIME_ACTION>
           <SFX text="GLOBAL_TIDE_PLAY" />
         </SPELL_ABILITY>   


            <UTILITY_ABILITY resource_id="3">
              <COST mana_cost="{6}{U}" type="Mana" />
           </UTILITY_ABILITY>

               <AI_AVAILABILITY type="in_response" response_source="1" />
               <AI_AVAILABILITY window_step="begin_combat" window_turn="their_turn" type="window" />
               <AI_AVAILABILITY window_step="declare_attackers" window_turn="their_turn" type="window" />
               <AI_AVAILABILITY window_step="main_1" window_turn="my_turn" type="window" />
               <AI_AVAILABILITY window_step="declare_blockers" type="window" />
               <AI_AVAILABILITY window_step="end_of_turn" type="window" />
               <AI_AVAILABILITY type="in_response" response_source="1" response_target="1" />
               <AI_BASE_SCORE score="900" zone="ZONE_HAND" />
</CARD_V2>
I didn't test too much but seems works properly.
I only changed the STATIC ABILITY with ZONE_ANY for 3 STATICS: 1 with zone hand, one with stack and one with exile.
I didnt put a static with zone graveyard cause i dont know any card that could play these cards from graveyard, but if is necessary is easy to add one more static block.
This is the same idea i got yesterday but i just splitted it into 2 STATIC : HAND and EXILE or STACK and EXILE now i don't remember i was too tired, anyway the game was freezing, now i test your modify, anyway if it works we need to better check the GRAVEYARD casting.
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Overload at 95%

Postby braquio » 29 Aug 2014, 14:30

This is the same idea i got yesterday but i just splitted it into 2 STATIC : HAND and EXILE or STACK and EXILE now i don't remember i was too tired, anyway the game was freezing, now i test your modify, anyway if it works we need to better check the GRAVEYARD casting.
I'm tested with 1 block ZONE_ANY and 1 block ZONE_EXILE and the game was freezing, may be you did the same.
But with separate blocks for each zone seems works fine.
____________________________________________________________________________________________________________________________
Braquio Dotp2014 DLC
Alternative Sealed Campaigns for DotP 2014
User avatar
braquio
 
Posts: 143
Joined: 16 Feb 2014, 19:21
Has thanked: 15 times
Been thanked: 9 times

Re: Overload at 95%

Postby braquio » 29 Aug 2014, 14:36

I'm added the graveyard block, cause i see a way to play it from graveyard.
With cards that gives flashback like Snapcaster Mage

Cyclonic Rift NEO&LBN V3.3 DON'T WORK | Open
Code: Select all
    <?xml version='1.0' encoding='UTF-8'?>
    <CARD_V2 ExportVersion="1">
              <FILENAME text="NEO_LBN_CYCLONIC_RIFT_992270798" />
              <CARDNAME text="CYCLONIC_RIFT" />
              <TITLE>
                <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Cyclonic Rift]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Faille cyclonique]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Grieta ciclónica]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Rift des Sturmtiefs]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Squarcio Ciclonico]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[サイクロンの裂け目]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[회오리 균열]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Циклонический Разлом]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Fenda Ciclônica]]></LOCALISED_TEXT>
              </TITLE>
              <MULTIVERSEID value="992270798" />
              <ARTID value="992270798" />
              <ARTIST name="Chris Rahn" />
              <CASTING_COST cost="{1}{U}" />
              <FLAVOURTEXT>
                <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[The Izzet specialize in unnatural disaster.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les Izzet sont spécialisés dans les catastrophes artificielles.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Los ízzet se especializan en desastres no naturales.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Die Izzet sind auf unnatürliche Katastrophen spezialisiert.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Gli Izzet sono specializzati in catastrofi innaturali.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[イゼット団は不自然災害を専門としている。]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[이젯 길드의 특기는 부자연스러운 재해다.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Иззеты являются мастерами неприродных катастроф.]]></LOCALISED_TEXT>
                <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[A especialidade dos Izzet são os desastres não naturais.]]></LOCALISED_TEXT>
              </FLAVOURTEXT>
              <TYPE metaname="Instant" />
              <EXPANSION value="RTR" />
              <RARITY metaname="R" />
           
               <STATIC_ABILITY active_zone="ZONE_HAND">
                    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Return target nonland permanent you don’t control to its owner’s hand.]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Renvoyez un permanent non-terrain ciblé que vous ne contrôlez pas dans la main de son propriétaire.]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Regresa el permanente objetivo que no sea tierra que no controles a la mano de su propietario.]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Bringe eine bleibende Karte deiner Wahl, die kein Land ist und die du nicht kontrollierst, auf die Hand ihres Besitzers zurück.]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Fai tornare un permanente non terra bersaglio che non controlli in mano al suo proprietario.]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[あなたがコントロールしていない土地でないパーマネント1つを対象とし、それをオーナーの手札に戻す。]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[당신이 조종하지 않는 지속물 중 대지가 아닌 지속물 한 개를 목표로 정한다. 그 지속물을 소유자의 손으로 되돌린다.]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Верните целевой не являющийся землей перманент, который не находится под вашим контролем, в руку его владельца.]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Devolva a permanente alvo que não seja um terreno e que você não controle para a mão de seu dono.]]></LOCALISED_TEXT>
                  <CONTINUOUS_ACTION layer="0">
                       local refplayer = EffectSource():GetPlayer()
                       local Chest_Id = EffectSource():GetRef()
                       local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                       local oDC = RSN_ObjectDC()
                       if chest ~= nil then
                         local nState = chest:Get_Int(1524)
                         local nStateB =  oDC:Int_Get(1524)
                         if (nState == 1) or (nStateB == 1) then
                            EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                         else
                            EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                         end
                       else
                          chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                          chest:Set_Int(1524, 0)
                       end
                   </CONTINUOUS_ACTION>
              </STATIC_ABILITY>

       <STATIC_ABILITY active_zone="ZONE_STACK">
                  <CONTINUOUS_ACTION layer="0">
                       local refplayer = EffectSource():GetPlayer()
                       local Chest_Id = EffectSource():GetRef()
                       local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                       local oDC = RSN_ObjectDC()
                       if chest ~= nil then
                         local nState = chest:Get_Int(1524)
                         local nStateB =  oDC:Int_Get(1524)
                         if (nState == 1) or (nStateB == 1) then
                            EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                         else
                            EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                         end
                       else
                          chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                          chest:Set_Int(1524, 0)
                       end
                   </CONTINUOUS_ACTION>
              </STATIC_ABILITY>

       <STATIC_ABILITY active_zone="ZONE_EXILE">
                  <CONTINUOUS_ACTION layer="0">
                       local refplayer = EffectSource():GetPlayer()
                       local Chest_Id = EffectSource():GetRef()
                       local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                       local oDC = RSN_ObjectDC()
                       if chest ~= nil then
                         local nState = chest:Get_Int(1524)
                         local nStateB =  oDC:Int_Get(1524)
                         if (nState == 1) or (nStateB == 1) then
                            EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                         else
                            EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                         end
                       else
                          chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                          chest:Set_Int(1524, 0)
                       end
                   </CONTINUOUS_ACTION>
              </STATIC_ABILITY>

<STATIC_ABILITY active_zone="ZONE_GRAVEYARD">
              <CONTINUOUS_ACTION layer="0">
                   local refplayer = EffectSource():GetPlayer()
                   local Chest_Id = EffectSource():GetRef()
                   local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                   local oDC = RSN_ObjectDC()
                   if chest ~= nil then
                     local nState = chest:Get_Int(1524)
                     local nStateB =  oDC:Int_Get(1524)
                     if (nState == 1) or (nStateB == 1) then
                        EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                     else
                        EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                     end
                   else
                      chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                      chest:Set_Int(1524, 0)
                   end
               </CONTINUOUS_ACTION>
          </STATIC_ABILITY>
              <STATIC_ABILITY active_zone="ZONE_HAND">
           <CONTINUOUS_ACTION layer="1">
              local refplayer = EffectSource():GetPlayer()
         local Chest_Id = EffectSource():GetRef()
         local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
              if chest ~= nil then
                 local oDC = RSN_ObjectDC()
                 local valor = oDC:Int_Get(1524)
                 oDC:Int_Set(1524, 1)
                 if EffectController():CanCastSpellUsingResourceCost( EffectSource(), 3 ) then
                    chest:Set_Int(1525,1)   
                 else
                    chest:Set_Int(1525,0)
                 end
                  oDC:Int_Set(1524, valor)   
              else
                 chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                 chest:Set_Int(1525,0)
              end
           </CONTINUOUS_ACTION>
              </STATIC_ABILITY>

             <ACTIVATED_ABILITY forced_skip="1" qualifier="Alternate"  active_zone="ZONE_HAND">
                    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Overload {6}{U} |(You may cast this spell for its overload cost. If you do, change its text by replacing all instances of "target" with "each.")|]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Surcharge {6}{U} |(Vous pouvez lancer ce sort pour son coût de surcharge. Si vous faites ainsi, modifiez son texte en remplaçant toutes les occurrences de « ciblé(e) » par « chaque ».)|]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Sobrecarga {6}{U} | (Puedes lanzar este hechizo por su coste de sobrecarga. Si lo haces, cambia su texto reemplazando "el permanente objetivo" por "cada permanente".)]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Überlast {6}{U} |(Du kannst diesen Zauber für seine Überlast-Kosten wirken. Falls du dies tust, verändere seinen Text, indem du im Text alle Vorkommen von „deiner Wahl" durch „jeder" ersetzt.)|]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Sovraccarico {6}{U} |(Puoi lanciare questa magia per il suo costo di sovraccarico. Se lo fai, cambiane il testo sostituendo "un permanente non terra bersaglio" con "ogni permanente non terra".)|]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[超過 {6}{U} |(あなたはこの呪文をその超過コストで唱えてもよい。そうした場合、あなたがコントロールしていない土地でない各パーマネントをそれぞれオーナーの手札に戻す。)|]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[과부하 {6}{U} |(당신은 과부하 비용을 지불하여 이 주문을 발동할 수 있다. 그럴 경우, 이 주문은 "당신이 조종하지 않는 지속물 중 대지가 아닌 각 지속물을 소유자의 손으로 되돌린다"로 내용이 변한다.)|]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Перегрузка {6}{U} |(Вы можете разыграть это заклинание за его стоимость Перегрузки. Если вы это делаете, измените в его тексте все слова «целевой» на «каждый».)|]]></LOCALISED_TEXT>
                    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Sobrecarga {6}{U} |(Você pode conjurar esta mágica pagando seu custo de sobrecarga. Se fizer isso, altere seu texto substituindo todas as ocorrências de "a permanente alvo" por "cada permanente".)|]]></LOCALISED_TEXT>
                     <COST type="Generic">
                    <PREREQUISITE>
                        local refplayer = EffectSource():GetPlayer()
                        local Chest_Id = EffectSource():GetRef()
                        local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                        if chest ~= nil then
                           return chest:Get_Int(1525) == 1
                        end   
                        return false
                     </PREREQUISITE>
                  <PLAY_TIME_ACTION>
                     RSN_MarkManaAbilityStart()
                  </PLAY_TIME_ACTION>
                         <PLAY_TIME_ACTION>
                       local spellToCast = EffectSource()
                            local refplayer = EffectSource():GetPlayer()
                          local Chest_Id = EffectSource():GetRef()
                          local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                          chest:Set_Int(1524, 1)
                          </PLAY_TIME_ACTION>
                   </COST>
                  <RESOLUTION_TIME_ACTION>
                       local spellToCast = EffectSource()
                       EffectController():CastSpellUsingResourceCost( spellToCast, 3 )
                     </RESOLUTION_TIME_ACTION>
                  <RESOLUTION_TIME_ACTION>
                    RSN_MarkManaAbilityEnd()
                  </RESOLUTION_TIME_ACTION>
                    </ACTIVATED_ABILITY>

             <SPELL_ABILITY  resource_id="1" active_zone="ZONE_ANY">
               <TARGET_DEFINITION id="0">   
                 MTG():ReevaluateContinuousEffects()
                      EffectDC():Set_Int(1321, 3)
                      local filter = ClearFilter()
                      filter:SetZone( ZONE_BATTLEFIELD )
                      filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                      local subfilter = filter:AddSubFilter_Or()
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                    </TARGET_DEFINITION>     
                   <TARGET tag="CARD_QUERY_CHOOSE_NONLAND_PERMANENT_TO_PUT_INTO_HAND" definition="0" compartment="0" count="1"/>
                   <RESOLUTION_TIME_ACTION>   
                      if EffectDC():Get_Int(1321) == 3 then
                         local refplayer = EffectSource():GetPlayer()
                         local Chest_Id = EffectSource():GetRef()
                         local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                         chest:Set_Int(1524, 0)
                         local target = EffectDC():Get_Targets(0) and EffectDC():Get_Targets(0):Get_CardPtr(0)
                         if  target ~= nil then
                             target:PutInHand()
                         end
                      end
                    </RESOLUTION_TIME_ACTION>
                    <FILTER filter_id="1">         
                            local filter = ClearFilter()
                            filter:SetZone( ZONE_BATTLEFIELD )
                            filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                            local subfilter = filter:AddSubFilter_Or()
                                  subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                                  subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                                  subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                        </FILTER>
                    <RESOLUTION_TIME_ACTION filter_id="1">
                        if EffectDC():Get_Int(1321) ~= 3 then
                           if FilteredCard() ~= nil then
                              FilteredCard():PutInHand()
                           end
                        end
                   </RESOLUTION_TIME_ACTION>
            </SPELL_ABILITY>     

             <SPELL_ABILITY  resource_id="2" active_zone="ZONE_ANY">
                   <FILTER filter_id="1">         
                        local filter = ClearFilter()
                              filter:SetZone( ZONE_BATTLEFIELD )
                              filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                              local subfilter = filter:AddSubFilter_Or()
                                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                        </FILTER>
                           <PLAY_TIME_ACTION>
                       local refplayer = EffectSource():GetPlayer()
                       local Chest_Id = EffectSource():GetRef()
                       local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                       chest:Set_Int(1524, 0)
                  local oDC = RSN_ObjectDC()
                        oDC:Int_Set(1524, 1)
                     </PLAY_TIME_ACTION>         
                   <RESOLUTION_TIME_ACTION filter_id="1">
                         if FilteredCard() ~= nil then
                            FilteredCard():PutInHand()
                         end
                   </RESOLUTION_TIME_ACTION>
               <SFX text="GLOBAL_TIDE_PLAY" />
             </SPELL_ABILITY>   


                <UTILITY_ABILITY resource_id="3">
                  <COST mana_cost="{6}{U}" type="Mana" />
               </UTILITY_ABILITY>

                   <AI_AVAILABILITY type="in_response" response_source="1" />
                   <AI_AVAILABILITY window_step="begin_combat" window_turn="their_turn" type="window" />
                   <AI_AVAILABILITY window_step="declare_attackers" window_turn="their_turn" type="window" />
                   <AI_AVAILABILITY window_step="main_1" window_turn="my_turn" type="window" />
                   <AI_AVAILABILITY window_step="declare_blockers" type="window" />
                   <AI_AVAILABILITY window_step="end_of_turn" type="window" />
                   <AI_AVAILABILITY type="in_response" response_source="1" response_target="1" />
                   <AI_BASE_SCORE score="900" zone="ZONE_HAND" />
    </CARD_V2>
And now im not sure if with flashback you could play the spell overloaded.
If not, now is perfect, if yes we have to recode 8-[
I think you cant cuase flashback is an alternative cost as overload, and you only can choose one of them.
Last edited by braquio on 29 Aug 2014, 15:08, edited 2 times in total.
____________________________________________________________________________________________________________________________
Braquio Dotp2014 DLC
Alternative Sealed Campaigns for DotP 2014
User avatar
braquio
 
Posts: 143
Joined: 16 Feb 2014, 19:21
Has thanked: 15 times
Been thanked: 9 times

Re: Overload at 95%

Postby braquio » 29 Aug 2014, 15:06

The game freeze when i give flashback
Why works when is exiled and not when is on graveyard?
____________________________________________________________________________________________________________________________
Braquio Dotp2014 DLC
Alternative Sealed Campaigns for DotP 2014
User avatar
braquio
 
Posts: 143
Joined: 16 Feb 2014, 19:21
Has thanked: 15 times
Been thanked: 9 times

Re: Overload at 95%

Postby NeoAnderson » 29 Aug 2014, 15:27

I was Still testing my friend anyway, accidentally i have posted the version with RSN_Object, but it was just a test, so i am using the LinkedDC version, to avoid external function, also because they both work at the same way.

About the flashback issue, is not the only one i was encountering the same issue with cards like : Omniscience, Nightveil Specter...
(to test Nightveil Specter , i moved a Cyclonic Rift on topo of my library then i give the control of Nightveil Specter to an opponent and i forced it to attack. So he exiles a Cyclonic Rift then i take back the control of Nightveil Specter)

As you said i think that the problem is about the "Alternate cost", if i remember there was a rule who said "a card can have only an alternative cost", anyway it seems that Dotp engine can't handle more than one of it.
I also tried to remove qualifier="Alternate" from the activated ability (Honestly the card work as before, with or without) so the problem is about the utility ability.

To be sure i want to test Omniscience, Nightveil with cards like Fury of the Horde, Salvage Titan coded by Sumomole and Firemind.

2. About the ZONE code splitting after checked this issue about alternate costs, i want see if we can use only 2 block using 1 working into EXILE and another one into ZONE_ANY (inside this block i want to use a check like EffectSource():GetZone() ~= ZONE_EXILE to avoid the execution of the block)

Anyway i post my actual version as like your with 4 stack block with linkedDC :
CYCLONIC RIFT NEO&LBN V3.3 LinkedDC - Still to fix | Open
Code: Select all
<?xml version='1.0' encoding='UTF-8'?>
    <CARD_V2 ExportVersion="1">
      <FILENAME text="NEO_LBN_CYCLONIC_RIFT_992270798" />
      <CARDNAME text="CYCLONIC_RIFT" />
      <TITLE>
        <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Cyclonic Rift]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Faille cyclonique]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Grieta ciclónica]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Rift des Sturmtiefs]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Squarcio Ciclonico]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[サイクロンの裂け目]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[회오리 균열]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Циклонический Разлом]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Fenda Ciclônica]]></LOCALISED_TEXT>
      </TITLE>
      <MULTIVERSEID value="992270798" />
      <ARTID value="992270798" />
      <ARTIST name="Chris Rahn" />
      <CASTING_COST cost="{1}{U}" />
      <FLAVOURTEXT>
        <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[The Izzet specialize in unnatural disaster.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les Izzet sont spécialisés dans les catastrophes artificielles.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Los ízzet se especializan en desastres no naturales.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Die Izzet sind auf unnatürliche Katastrophen spezialisiert.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Gli Izzet sono specializzati in catastrofi innaturali.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[イゼット団は不自然災害を専門としている。]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[이젯 길드의 특기는 부자연스러운 재해다.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Иззеты являются мастерами неприродных катастроф.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[A especialidade dos Izzet são os desastres não naturais.]]></LOCALISED_TEXT>
      </FLAVOURTEXT>
      <TYPE metaname="Instant" />
      <EXPANSION value="RTR" />
      <RARITY metaname="R" />
   
       <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_HAND">
            <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Return target nonland permanent you don’t control to its owner’s hand.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Renvoyez un permanent non-terrain ciblé que vous ne contrôlez pas dans la main de son propriétaire.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Regresa el permanente objetivo que no sea tierra que no controles a la mano de su propietario.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Bringe eine bleibende Karte deiner Wahl, die kein Land ist und die du nicht kontrollierst, auf die Hand ihres Besitzers

zurück.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Fai tornare un permanente non terra bersaglio che non controlli in mano al suo proprietario.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[あなたがコントロールしていない土地でないパーマネント1つを対象とし、それをオーナーの手札に戻す。]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[당신이 조종하지 않는 지속물 중 대지가 아닌 지속물 한 개를 목표로 정한다. 그 지속물을 소유자의 손으로 되돌린다.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Верните целевой не являющийся землей перманент, который не находится под вашим контролем, в руку его владельца.]]

></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Devolva a permanente alvo que não seja um terreno e que você não controle para a mão de seu dono.]]></LOCALISED_TEXT>
          <CONTINUOUS_ACTION layer="0">
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
               if chest ~= nil then
                 local nState = chest:Get_Int(1524)
                 local nStateB = LinkedDC():Get_Int(1524)
                 if (nState == 1) or (nStateB == 1) then
                    EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                 else
                    EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                 end
               else
                  chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 0)
               end
           </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

       <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_STACK">
          <CONTINUOUS_ACTION layer="0">
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
               if chest ~= nil then
                 local nState = chest:Get_Int(1524)
                 local nStateB = LinkedDC():Get_Int(1524)
                 if (nState == 1) or (nStateB == 1) then
                    EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                 else
                    EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                 end
               else
                  chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 0)
               end
           </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

       <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_GRAVEYARD">
          <CONTINUOUS_ACTION layer="0">
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
               if chest ~= nil then
                 local nState = chest:Get_Int(1524)
                 local nStateB = LinkedDC():Get_Int(1524)
                 if (nState == 1) or (nStateB == 1) then
                    EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                 else
                    EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                 end
               else
                  chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 0)
               end
           </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

       <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_EXILE">
          <CONTINUOUS_ACTION layer="0">
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
               if chest ~= nil then
                 local nState = chest:Get_Int(1524)
                 local nStateB = LinkedDC():Get_Int(1524)
                 if (nState == 1) or (nStateB == 1) then
                    EffectSource():GetCurrentCharacteristics():GrantAbility(2)
                 else
                    EffectSource():GetCurrentCharacteristics():GrantAbility(1)
                 end
               else
                  chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 0)
               end
           </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

      <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_HAND">
   <CONTINUOUS_ACTION layer="1">
      local refplayer = EffectSource():GetPlayer()
                local Chest_Id = EffectSource():GetRef()
                local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
      if chest ~= nil then
         local valor = LinkedDC():Get_Int(1524)
         LinkedDC():Set_Int(1524, 1)
         if EffectController():CanCastSpellUsingResourceCost( EffectSource(), 3 ) then
            chest:Set_Int(1525,1)   
         else
            chest:Set_Int(1525,0)
         end
         LinkedDC():Set_Int(1524, valor)   
      else
         chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
         chest:Set_Int(1525,0)
      end
   </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

     <ACTIVATED_ABILITY forced_skip="1" qualifier="Alternate"  active_zone="ZONE_HAND" linked_ability_group="1">
            <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Overload {6}{U} |(You may cast this spell for its overload cost. If you do, change its text by replacing all instances of

"target" with "each.")|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Surcharge {6}{U} |(Vous pouvez lancer ce sort pour son coût de surcharge. Si vous faites ainsi, modifiez son texte en

remplaçant toutes les occurrences de « ciblé(e) » par « chaque ».)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Sobrecarga {6}{U} | (Puedes lanzar este hechizo por su coste de sobrecarga. Si lo haces, cambia su texto reemplazando "el

permanente objetivo" por "cada permanente".)]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Überlast {6}{U} |(Du kannst diesen Zauber für seine Überlast-Kosten wirken. Falls du dies tust, verändere seinen Text,

indem du im Text alle Vorkommen von „deiner Wahl" durch „jeder" ersetzt.)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Sovraccarico {6}{U} |(Puoi lanciare questa magia per il suo costo di sovraccarico. Se lo fai, cambiane il testo

sostituendo "un permanente non terra bersaglio" con "ogni permanente non terra".)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[超過 {6}{U} |(あなたはこの呪文をその超過コストで唱えてもよい。そうした場合、あなたがコントロールしていない土地でない各パーマネントをそれぞれオーナーの手札に戻す。)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[과부하 {6}{U} |(당신은 과부하 비용을 지불하여 이 주문을 발동할 수 있다. 그럴 경우, 이 주문은 "당신이 조종하지 않는 지속물 중 대지가 아닌 각 지속물을 소유자의 손으로 되돌린

다"로 내용이 변한다.)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Перегрузка {6}{U} |(Вы можете разыграть это заклинание за его стоимость Перегрузки. Если вы это делаете, измените в его

тексте все слова «целевой» на «каждый».)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Sobrecarga {6}{U} |(Você pode conjurar esta mágica pagando seu custo de sobrecarga. Se fizer isso, altere seu texto

substituindo todas as ocorrências de "a permanente alvo" por "cada permanente".)|]]></LOCALISED_TEXT>
             <COST type="Generic">
            <PREREQUISITE>
                local refplayer = EffectSource():GetPlayer()
                local Chest_Id = EffectSource():GetRef()
                local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                if chest ~= nil then
                   return chest:Get_Int(1525) == 1
                end   
                return false
             </PREREQUISITE>
          <PLAY_TIME_ACTION>
             RSN_MarkManaAbilityStart()
          </PLAY_TIME_ACTION>
                 <PLAY_TIME_ACTION>
               local spellToCast = EffectSource()
                    local refplayer = EffectSource():GetPlayer()
                  local Chest_Id = EffectSource():GetRef()
                  local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 1)
                  </PLAY_TIME_ACTION>
           </COST>
          <RESOLUTION_TIME_ACTION>
               local spellToCast = EffectSource()
               EffectController():CastSpellUsingResourceCost( spellToCast, 3 )
             </RESOLUTION_TIME_ACTION>
          <RESOLUTION_TIME_ACTION>
            RSN_MarkManaAbilityEnd()
          </RESOLUTION_TIME_ACTION>
            </ACTIVATED_ABILITY>

     <SPELL_ABILITY  resource_id="1">
       <TARGET_DEFINITION id="0">   
         MTG():ReevaluateContinuousEffects()
              EffectDC():Set_Int(1321, 3)
              local filter = ClearFilter()
              filter:SetZone( ZONE_BATTLEFIELD )
              filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
              local subfilter = filter:AddSubFilter_Or()
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
            </TARGET_DEFINITION>     
           <TARGET tag="CARD_QUERY_CHOOSE_NONLAND_PERMANENT_TO_PUT_INTO_HAND" definition="0" compartment="0" count="1"/>
           <RESOLUTION_TIME_ACTION>   
              if EffectDC():Get_Int(1321) == 3 then
                 local refplayer = EffectSource():GetPlayer()
                 local Chest_Id = EffectSource():GetRef()
                 local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                 chest:Set_Int(1524, 0)
                 local target = EffectDC():Get_Targets(0) and EffectDC():Get_Targets(0):Get_CardPtr(0)
                 if  target ~= nil then
                     target:PutInHand()
                 end
              end
            </RESOLUTION_TIME_ACTION>
            <FILTER filter_id="1">         
                    local filter = ClearFilter()
                    filter:SetZone( ZONE_BATTLEFIELD )
                    filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                    local subfilter = filter:AddSubFilter_Or()
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                </FILTER>
            <RESOLUTION_TIME_ACTION filter_id="1">
                if EffectDC():Get_Int(1321) ~= 3 then
                   if FilteredCard() ~= nil then
                      FilteredCard():PutInHand()
                   end
                end
           </RESOLUTION_TIME_ACTION>
    </SPELL_ABILITY>     

     <SPELL_ABILITY  resource_id="2" linked_ability_group="1">
           <FILTER filter_id="1">         
                local filter = ClearFilter()
                      filter:SetZone( ZONE_BATTLEFIELD )
                      filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                      local subfilter = filter:AddSubFilter_Or()
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                </FILTER>
                   <PLAY_TIME_ACTION>
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
               chest:Set_Int(1524, 0)
               LinkedDC():Set_Int(1524, 1)
             </PLAY_TIME_ACTION>         
           <RESOLUTION_TIME_ACTION filter_id="1">
                 if FilteredCard() ~= nil then
                    FilteredCard():PutInHand()
                 end
           </RESOLUTION_TIME_ACTION>
       <SFX text="GLOBAL_TIDE_PLAY" />
     </SPELL_ABILITY>   


        <UTILITY_ABILITY resource_id="3">
          <COST mana_cost="{6}{U}" type="Mana" />
       </UTILITY_ABILITY>

           <AI_AVAILABILITY type="in_response" response_source="1" />
           <AI_AVAILABILITY window_step="begin_combat" window_turn="their_turn" type="window" />
           <AI_AVAILABILITY window_step="declare_attackers" window_turn="their_turn" type="window" />
           <AI_AVAILABILITY window_step="main_1" window_turn="my_turn" type="window" />
           <AI_AVAILABILITY window_step="declare_blockers" type="window" />
           <AI_AVAILABILITY window_step="end_of_turn" type="window" />
           <AI_AVAILABILITY type="in_response" response_source="1" response_target="1" />
           <AI_BASE_SCORE score="900" zone="ZONE_HAND" />
</CARD_V2>
UPDATE 1 : Salvage Titan combined with Omniscience works and show me 3 different options Normal Casting cost, Alternate casting cost of Salvage Titan and also Free casting cost of Omniscience. #-o
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Overload at 95%

Postby braquio » 29 Aug 2014, 15:48

ONLY RULES:

From Chandra Ablaze gatherer:
Code: Select all
If you cast a card "without paying its mana cost," you can't pay any alternative costs. You can pay additional costs, such as kicker costs.
I see the same in other cards that let you play cards from graveyard as free.

So with these cards you cant use overload.

With flashback the same.

I dont know any card that let you play another card(no itself) from graveyard a is normal cast, withouth an alternative play or alternative cost, if exist theorically you could use overload, im not sure.
The same for Nightveil Specter, with this i think you could use overload, and is a problem.


PROGRAMMING QUESTIONS:

Aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaah!!!! #-o #-o #-o
____________________________________________________________________________________________________________________________
Braquio Dotp2014 DLC
Alternative Sealed Campaigns for DotP 2014
User avatar
braquio
 
Posts: 143
Joined: 16 Feb 2014, 19:21
Has thanked: 15 times
Been thanked: 9 times

Re: Overload at 95%

Postby NeoAnderson » 29 Aug 2014, 16:50

braquio wrote:ONLY RULES:

From Chandra Ablaze gatherer:
Code: Select all
If you cast a card "without paying its mana cost," you can't pay any alternative costs. You can pay additional costs, such as kicker costs.
I see the same in other cards that let you play cards from graveyard as free.

So with these cards you cant use overload.

With flashback the same.

I dont know any card that let you play another card(no itself) from graveyard a is normal cast, withouth an alternative play or alternative cost, if exist theorically you could use overload, im not sure.
The same for Nightveil Specter, with this i think you could use overload, and is a problem.


PROGRAMMING QUESTIONS:

Aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaah!!!! #-o #-o #-o
About the alternate cost i already know that we can't use overload when we play it from other zone, but the issue still remains, normal cast crash with the kind of cards who grants "normal cast" from other zone!
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Overload at 95%

Postby RiiakShiNal » 30 Aug 2014, 00:14

NeoAnderson wrote:Honestly it could be more simple, but the main problem was the function EffectSource():GetRef(), iwas hoping it could return a unique value for each istance of a card but it seems to return the same value for each instance of the same card. If anyone knows an alternative function who returns a unique id for each instance it could make the things more easy to handle!!!
Object() returns the card instance (meaning multiple copies in a deck will each have different Object() references) and it remains the same for only that instance of the card no matter how many times it changes zones (means Object() is constant for any given card instance).

If you want to use the ObjectDC functions then just use RSN_GetObjectDC() instead of RSN_ObjectDC(). You can pass the card pointer you want to use the ObjectDC on to RSN_GetObjectDC() so you could pass it Object() if you wanted to retain the chest across zone changes.
RiiakShiNal
Programmer
 
Posts: 2185
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 497 times

Re: Overload at 95%

Postby NeoAnderson » 30 Aug 2014, 00:52

RiiakShiNal wrote:
NeoAnderson wrote:Honestly it could be more simple, but the main problem was the function EffectSource():GetRef(), iwas hoping it could return a unique value for each istance of a card but it seems to return the same value for each instance of the same card. If anyone knows an alternative function who returns a unique id for each instance it could make the things more easy to handle!!!
Object() returns the card instance (meaning multiple copies in a deck will each have different Object() references) and it remains the same for only that instance of the card no matter how many times it changes zones (means Object() is constant for any given card instance).

If you want to use the ObjectDC functions then just use RSN_GetObjectDC() instead of RSN_ObjectDC(). You can pass the card pointer you want to use the ObjectDC on to RSN_GetObjectDC() so you could pass it Object() if you wanted to retain the chest across zone changes.
Ok i know i can use the Object() to retrieve the card pointer (different for each instances), also if i was looking for an integer value to be used to create a chest for each instances.
I know i can do it anyway but i have to make a different chest structure, i have to start from a value (example : 800) then i have to save both information i need Object pointer and integer values.
When another istance enter in action i have to check starting from 800 comparing each object pointer until i found it, if not it means it will be a new chest to add.

An example could be :
Code: Select all
local ObjFound = 0
local refplayer = Object():GetPlayer()
local chest = refplayer:PlayerDataChest():Get_Chest(800)
if chest ~= nil then
   local indexChest = chest:Get_Int(0)
   for i = 1, indexChest do
       local chest_OBJ = chest:Get_Chest(i) 
       if chest ~= nil then
          local Current_OBJ = chest_OBJ:Get_CardPtr(0)
          if Current_OBJ ~= nil then
             if Current_OBJ == Object() then
                ObjFound = 1 

                  **** Found do something *****
             end
          end
       end
   end
 ******* If not found add the Object to the chest*******
   if ObjFound == 0 then
      chest:Int_Inc(0)   
      indexChest = chest:Get_Int(0)
      local chest_OBJ = chest:Make_Chest(indexChest)
      chest_OBJ:Set_CardPtr(0, Object())
      ****Eventually Protect the pointer****
else
   chest = refplayer:PlayerDataChest():Make_Chest(800)
   chest:Set_Int(0, 1)
   local indexChest = chest:Get_Int(0)
   local chest_OBJ = chest:Make_Chest(indexChest)
   chest_OBJ:Set_CardPtr(0, Object())
   ****Eventually Protect the pointer****
   chest:Int_Inc(0)   
end
Anyway have you some idea why the game free when this card interact with card like Omniscience, Nightveil Specter ??
I can confirm that if we have a card who cast for free from exile it works.
There is somekind of conflict when is granted the "normal cast" as alternate cost for exile zone!

2. Another urgent question, do you know if when you make a copy of a spell are also copied some kind information about the chest??
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Overload at 95%

Postby NeoAnderson » 30 Aug 2014, 03:56

Ok i think we have reached the best we can obtain with all the limitations of Dotp engine..
I finally resolved all the bugs caused by card like Omniscience, Bituminous Blast (and other CASCADE cards),Epic Experiment...etc.
About all cards like Nightveil Specter, Elkin Bottle, Muse Vessel ....etc...it is a partial work, because it can only play the card in "normal cast". Anyway there are really few cards with this kind of interaction!


About other question like flashback and cascade the card should work as expected! (Anyway need more tests)
You can’t use OverLoad with Flashback or Cascade
See, when you use an ability like cascade or flashback to cast a spell from a place you normally couldn’t, what you’re doing is casting it for an alternative cost (even “without paying its mana cost” still counts as an alternativee cost). overload, too, is an alternative cost. From : http://blogs.magicjudges.org/rulestips/2012/10/you-cant-use-overload-with-flashback-or-cascade/

Here you can find the last card version please help me to make other tests :

CYCLONIC RIFT NEO&LBN V4.0 | Open
Code: Select all
<?xml version='1.0' encoding='UTF-8'?>
    <CARD_V2 ExportVersion="1">
      <FILENAME text="NEO_LBN_CYCLONIC_RIFT_992270798" />
      <CARDNAME text="CYCLONIC_RIFT" />
      <TITLE>
        <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Cyclonic Rift]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Faille cyclonique]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Grieta ciclónica]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Rift des Sturmtiefs]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Squarcio Ciclonico]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[サイクロンの裂け目]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[회오리 균열]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Циклонический Разлом]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Fenda Ciclônica]]></LOCALISED_TEXT>
      </TITLE>
      <MULTIVERSEID value="992270798" />
      <ARTID value="992270798" />
      <ARTIST name="Chris Rahn" />
      <CASTING_COST cost="{1}{U}" />
      <FLAVOURTEXT>
        <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[The Izzet specialize in unnatural disaster.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les Izzet sont spécialisés dans les catastrophes artificielles.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Los ízzet se especializan en desastres no naturales.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Die Izzet sind auf unnatürliche Katastrophen spezialisiert.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Gli Izzet sono specializzati in catastrofi innaturali.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[イゼット団は不自然災害を専門としている。]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[이젯 길드의 특기는 부자연스러운 재해다.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Иззеты являются мастерами неприродных катастроф.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[A especialidade dos Izzet são os desastres não naturais.]]></LOCALISED_TEXT>
      </FLAVOURTEXT>
      <TYPE metaname="Instant" />
      <EXPANSION value="RTR" />
      <RARITY metaname="R" />
   
       <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_ANY">
            <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Return target nonland permanent you don’t control to its owner’s hand.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Renvoyez un permanent non-terrain ciblé que vous ne contrôlez pas dans la main de son propriétaire.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Regresa el permanente objetivo que no sea tierra que no controles a la mano de su propietario.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Bringe eine bleibende Karte deiner Wahl, die kein Land ist und die du nicht kontrollierst, auf die Hand ihres Besitzers zurück.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Fai tornare un permanente non terra bersaglio che non controlli in mano al suo proprietario.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[あなたがコントロールしていない土地でないパーマネント1つを対象とし、それをオーナーの手札に戻す。]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[당신이 조종하지 않는 지속물 중 대지가 아닌 지속물 한 개를 목표로 정한다. 그 지속물을 소유자의 손으로 되돌린다.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Верните целевой не являющийся землей перманент, который не находится под вашим контролем, в руку его владельца.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Devolva a permanente alvo que não seja um terreno e que você não controle para a mão de seu dono.]]></LOCALISED_TEXT>
          <CONTINUOUS_ACTION layer="0">
            if EffectSource():GetZone() ~= ZONE_EXILE then
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
               if chest ~= nil then
                 local nState = chest:Get_Int(1524)
                 local nStateB = LinkedDC():Get_Int(1524)
                 if (nState == 1) or (nStateB == 1) then
                    EffectSource():GetCurrentCharacteristics():GrantAbility(20)
                 else
                    EffectSource():GetCurrentCharacteristics():GrantAbility(10)
                 end
               else
                  chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 0)
               end
            end
           </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

       <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_EXILE">
          <CONTINUOUS_ACTION layer="0">
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
               if chest ~= nil then
                 local nState = chest:Get_Int(1524)
                 local nStateB = LinkedDC():Get_Int(1524)
                 if (nState == 1) or (nStateB == 1) then
                    EffectSource():GetCurrentCharacteristics():GrantAbility(20)
                 else
                    EffectSource():GetCurrentCharacteristics():GrantAbility(10)
                 end
               else
                  chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 0)
               end
           </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

      <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_HAND">
   <CONTINUOUS_ACTION layer="1">
      local refplayer = EffectSource():GetPlayer()
                local Chest_Id = EffectSource():GetRef()
                local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
      if chest ~= nil then
         local valor = LinkedDC():Get_Int(1524)
         LinkedDC():Set_Int(1524, 1)
         if EffectController():CanCastSpellUsingResourceCost( EffectSource(), 3 ) then
            chest:Set_Int(1525,1)   
         else
            chest:Set_Int(1525,0)
         end
         LinkedDC():Set_Int(1524, valor)   
      else
         chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
         chest:Set_Int(1525,0)
      end
   </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

     <ACTIVATED_ABILITY forced_skip="1" qualifier="Alternate"  active_zone="ZONE_HAND" linked_ability_group="1">
            <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Overload {6}{U} |(You may cast this spell for its overload cost. If you do, change its text by replacing all instances of "target" with "each.")|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Surcharge {6}{U} |(Vous pouvez lancer ce sort pour son coût de surcharge. Si vous faites ainsi, modifiez son texte en remplaçant toutes les occurrences de « ciblé(e) » par « chaque ».)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Sobrecarga {6}{U} | (Puedes lanzar este hechizo por su coste de sobrecarga. Si lo haces, cambia su texto reemplazando "el
permanente objetivo" por "cada permanente".)]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Überlast {6}{U} |(Du kannst diesen Zauber für seine Überlast-Kosten wirken. Falls du dies tust, verändere seinen Text, indem du im Text alle Vorkommen von „deiner Wahl" durch „jeder" ersetzt.)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Sovraccarico {6}{U} |(Puoi lanciare questa magia per il suo costo di sovraccarico. Se lo fai, cambiane il testo sostituendo "un permanente non terra bersaglio" con "ogni permanente non terra".)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[超過 {6}{U} |(あなたはこの呪文をその超過コストで唱えてもよい。そうした場合、あなたがコントロールしていない土地でない各パーマネントをそれぞれオーナーの手札に戻す。)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[과부하 {6}{U} |(당신은 과부하 비용을 지불하여 이 주문을 발동할 수 있다. 그럴 경우, 이 주문은 "당신이 조종하지 않는 지속물 중 대지가 아닌 각 지속물을 소유자의 손으로 되돌린다"로 내용이 변한다.)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Перегрузка {6}{U} |(Вы можете разыграть это заклинание за его стоимость Перегрузки. Если вы это делаете, измените в его тексте все слова «целевой» на «каждый».)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Sobrecarga {6}{U} |(Você pode conjurar esta mágica pagando seu custo de sobrecarga. Se fizer isso, altere seu texto substituindo todas as ocorrências de "a permanente alvo" por "cada permanente".)|]]></LOCALISED_TEXT>
             <COST type="Generic">
            <PREREQUISITE>
                local refplayer = EffectSource():GetPlayer()
                local Chest_Id = EffectSource():GetRef()
                local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                if chest ~= nil then
                   return chest:Get_Int(1525) == 1
                end   
                return false
             </PREREQUISITE>
          <PLAY_TIME_ACTION>
             RSN_MarkManaAbilityStart()
          </PLAY_TIME_ACTION>
                 <PLAY_TIME_ACTION>
               local spellToCast = EffectSource()
                    local refplayer = EffectSource():GetPlayer()
                  local Chest_Id = EffectSource():GetRef()
                  local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 1)
                  </PLAY_TIME_ACTION>
           </COST>
          <RESOLUTION_TIME_ACTION>
               local spellToCast = EffectSource()
               EffectController():CastSpellUsingResourceCost( spellToCast, 3 )
             </RESOLUTION_TIME_ACTION>
          <RESOLUTION_TIME_ACTION>
            RSN_MarkManaAbilityEnd()
          </RESOLUTION_TIME_ACTION>
            </ACTIVATED_ABILITY>

     <SPELL_ABILITY  resource_id="10">
       <TARGET_DEFINITION id="0">   
              EffectDC():Set_Int(1321, 3)
              local filter = ClearFilter()
              filter:SetZone( ZONE_BATTLEFIELD )
              filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
              local subfilter = filter:AddSubFilter_Or()
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
            </TARGET_DEFINITION>     
           <TARGET tag="CARD_QUERY_CHOOSE_NONLAND_PERMANENT_TO_PUT_INTO_HAND" definition="0" compartment="0" count="1"/>
           <RESOLUTION_TIME_ACTION>   
              if EffectDC():Get_Int(1321) == 3 then
                 local refplayer = EffectSource():GetPlayer()
                 local Chest_Id = EffectSource():GetRef()
                 local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                 chest:Set_Int(1524, 0)
                 local target = EffectDC():Get_Targets(0) and EffectDC():Get_Targets(0):Get_CardPtr(0)
                 if  target ~= nil then
                     target:PutInHand()
                 end
              end
            </RESOLUTION_TIME_ACTION>
            <FILTER filter_id="1">         
                    local filter = ClearFilter()
                    filter:SetZone( ZONE_BATTLEFIELD )
                    filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                    local subfilter = filter:AddSubFilter_Or()
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                </FILTER>
            <RESOLUTION_TIME_ACTION filter_id="1">
                if EffectDC():Get_Int(1321) ~= 3 then
                   if FilteredCard() ~= nil then
                      FilteredCard():PutInHand()
                   end
                end
           </RESOLUTION_TIME_ACTION>
    </SPELL_ABILITY>     

     <SPELL_ABILITY  resource_id="20" linked_ability_group="1">
           <FILTER filter_id="1">         
                local filter = ClearFilter()
                      filter:SetZone( ZONE_BATTLEFIELD )
                      filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                      local subfilter = filter:AddSubFilter_Or()
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                </FILTER>
                   <PLAY_TIME_ACTION>
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
               chest:Set_Int(1524, 0)
               LinkedDC():Set_Int(1524, 1)
             </PLAY_TIME_ACTION>         
           <RESOLUTION_TIME_ACTION filter_id="1">
                 if FilteredCard() ~= nil then
                    FilteredCard():PutInHand()
                 end
           </RESOLUTION_TIME_ACTION>
       <SFX text="GLOBAL_TIDE_PLAY" />
     </SPELL_ABILITY>   

        <UTILITY_ABILITY resource_id="3">
          <COST mana_cost="{6}{U}" type="Mana" />
       </UTILITY_ABILITY>

           <AI_AVAILABILITY type="in_response" response_source="1" />
           <AI_AVAILABILITY window_step="begin_combat" window_turn="their_turn" type="window" />
           <AI_AVAILABILITY window_step="declare_attackers" window_turn="their_turn" type="window" />
           <AI_AVAILABILITY window_step="main_1" window_turn="my_turn" type="window" />
           <AI_AVAILABILITY window_step="declare_blockers" type="window" />
           <AI_AVAILABILITY window_step="end_of_turn" type="window" />
           <AI_AVAILABILITY type="in_response" response_source="1" response_target="1" />
           <AI_BASE_SCORE score="900" zone="ZONE_HAND" />
</CARD_V2>
Possible interactions cards List | Open
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Overload at 95%

Postby RiiakShiNal » 30 Aug 2014, 12:29

NeoAnderson wrote:Ok i know i can use the Object() to retrieve the card pointer (different for each instances), also if i was looking for an integer value to be used to create a chest for each instances.
I know i can do it anyway but i have to make a different chest structure, i have to start from a value (example : 800) then i have to save both information i need Object pointer and integer values.
When another istance enter in action i have to check starting from 800 comparing each object pointer until i found it, if not it means it will be a new chest to add.

An example could be :
Code: Select all
local ObjFound = 0
local refplayer = Object():GetPlayer()
local chest = refplayer:PlayerDataChest():Get_Chest(800)
if chest ~= nil then
   local indexChest = chest:Get_Int(0)
   for i = 1, indexChest do
       local chest_OBJ = chest:Get_Chest(i) 
       if chest ~= nil then
          local Current_OBJ = chest_OBJ:Get_CardPtr(0)
          if Current_OBJ ~= nil then
             if Current_OBJ == Object() then
                ObjFound = 1 

                  **** Found do something *****
             end
          end
       end
   end
 ******* If not found add the Object to the chest*******
   if ObjFound == 0 then
      chest:Int_Inc(0)   
      indexChest = chest:Get_Int(0)
      local chest_OBJ = chest:Make_Chest(indexChest)
      chest_OBJ:Set_CardPtr(0, Object())
      ****Eventually Protect the pointer****
else
   chest = refplayer:PlayerDataChest():Make_Chest(800)
   chest:Set_Int(0, 1)
   local indexChest = chest:Get_Int(0)
   local chest_OBJ = chest:Make_Chest(indexChest)
   chest_OBJ:Set_CardPtr(0, Object())
   ****Eventually Protect the pointer****
   chest:Int_Inc(0)   
end
This is pretty much exactly what the ObjectDC functions do with the exception that I use the DuelDataChest() instead of the PlayerDataChest() and I don't protect the card pointer (since to replicate the ObjectDC behavior from DotP 2013 the chest is supposed to get cleared when changing zones). The advantage of storing the chest in the DuelDataChest() instead of the PlayerDataChest() is that if the card changes controllers the chest remains valid where under PlayerDataChest the chest would become invalid.

Though I do have an experimental function I made specifically for protecting the card pointer for an ObjectDC chest to protect the chest contents from being cleared when changing zones. Though since it was never needed I never included it into the ObjectDC functions. It only works for ObjectDCs for the EffectSource though (I didn't make a targetable protect function).
Code: Select all
RSN_ProtectObjectDC = function()
   local oDC = nil
   -- Get our fake ObjectDC repository.
   local oObjectDCChest = MTG():DuelDataChest():Get_Chest( RSN_REGISTER_OBJECTDC_CHEST )
   if (oObjectDCChest == nil) then
      -- Repository doesn't exist so create it.
      oObjectDCChest = MTG():DuelDataChest():Make_Chest( RSN_REGISTER_OBJECTDC_CHEST )
   end

   -- Find out how many objectDCs we have stored.
   local nCount = oObjectDCChest:Int_Get( RSN_REGISTER_OBJECTDC_CHEST_COUNT )

   -- Look though our stored fake ObjectDCs to see if we have one for this card.
   for i = 1, nCount do
      -- Get our stored ObjectDC repository item.
      local oTestDC = oObjectDCChest:Get_Chest( i )
      if (oTestDC ~= nil) then
         -- Get the card pointer for this ObjectDC
         local oTestCard = oTestDC:Get_CardPtr( 0 )

         -- Check to see if it is our object.
         if (oTestCard == oCard) then
            -- This is the right repository item so protect our pointer so it doesn't get lost crossing zones.
            oTestDC:Protect_CardPtr( 0 )

            -- We found what we were looking for so exit the loop.
            break
         end
      end
   end
end
NeoAnderson wrote:Anyway have you some idea why the game free when this card interact with card like Omniscience, Nightveil Specter ??
I can confirm that if we have a card who cast for free from exile it works.
There is somekind of conflict when is granted the "normal cast" as alternate cost for exile zone!
No I don't know why, this is probably just another DotP bug.

NeoAnderson wrote:2. Another urgent question, do you know if when you make a copy of a spell are also copied some kind information about the chest??
I do know the answer to this. No, chest information is not copied when a spell is copied. This also applies to all card copies whenever a card is copied no chest information from the original card is copied to the new card.
RiiakShiNal
Programmer
 
Posts: 2185
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 497 times

Re: Overload at 95%

Postby NeoAnderson » 30 Aug 2014, 13:01

RiiakShiNal wrote:This is pretty much exactly what the ObjectDC functions do with the exception that I use the DuelDataChest() instead of the PlayerDataChest() and I don't protect the card pointer (since to replicate the ObjectDC behavior from DotP 2013 the chest is supposed to get cleared when changing zones). The advantage of storing the chest in the DuelDataChest() instead of the PlayerDataChest() is that if the card changes controllers the chest remains valid where under PlayerDataChest the chest would become invalid.

Though I do have an experimental function I made specifically for protecting the card pointer for an ObjectDC chest to protect the chest contents from being cleared when changing zones. Though since it was never needed I never included it into the ObjectDC functions. It only works for ObjectDCs for the EffectSource though (I didn't make a targetable protect function).
CODE | Open
Code: Select all
RSN_ProtectObjectDC = function()
   local oDC = nil
   -- Get our fake ObjectDC repository.
   local oObjectDCChest = MTG():DuelDataChest():Get_Chest( RSN_REGISTER_OBJECTDC_CHEST )
   if (oObjectDCChest == nil) then
      -- Repository doesn't exist so create it.
      oObjectDCChest = MTG():DuelDataChest():Make_Chest( RSN_REGISTER_OBJECTDC_CHEST )
   end

   -- Find out how many objectDCs we have stored.
   local nCount = oObjectDCChest:Int_Get( RSN_REGISTER_OBJECTDC_CHEST_COUNT )

   -- Look though our stored fake ObjectDCs to see if we have one for this card.
   for i = 1, nCount do
      -- Get our stored ObjectDC repository item.
      local oTestDC = oObjectDCChest:Get_Chest( i )
      if (oTestDC ~= nil) then
         -- Get the card pointer for this ObjectDC
         local oTestCard = oTestDC:Get_CardPtr( 0 )

         -- Check to see if it is our object.
         if (oTestCard == oCard) then
            -- This is the right repository item so protect our pointer so it doesn't get lost crossing zones.
            oTestDC:Protect_CardPtr( 0 )

            -- We found what we were looking for so exit the loop.
            break
         end
      end
   end
end
Thanks a lot for the answer. :D
RiiakShiNal wrote:
NeoAnderson wrote:Anyway have you some idea why the game free when this card interact with card like Omniscience, Nightveil Specter ??
I can confirm that if we have a card who cast for free from exile it works.
There is somekind of conflict when is granted the "normal cast" as alternate cost for exile zone!
No I don't know why, this is probably just another DotP bug.
I have found the problem, it was the calling of MTG():ReevaluateContinuousEffects() inside the target block. Probably it was in conflict with the "normal cast" granted utility ability.
RiiakShiNal wrote:
NeoAnderson wrote:2. Another urgent question, do you know if when you make a copy of a spell are also copied some kind information about the chest??
I do know the answer to this. No, chest information is not copied when a spell is copied. This also applies to all card copies whenever a card is copied no chest information from the original card is copied to the new card.
This is so bad, also because we don't have any TRIGGER that fires when we use CopySpell functions, so we cannot understand when a spell is generating a copy. For Example with the tokens we don't have this problem because when we use PutTokenOntoBattlefield you can pass a DataChest as parameter!
ANYWAY : The last version is really close to be a full work approximation as i said in the post above we have only one kind of interaction that is limited (when we use cards who says "You can play a card from a zone") in this case we can only play "Normal cast". So what you think can we consider this OVERLOAD good enough?
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Overload at 95%

Postby NeoAnderson » 30 Aug 2014, 15:10

Ok i think we have reached the best we can obtain with all the limitations of Dotp engine..
I finally resolved all the bugs caused by card like Omniscience, Bituminous Blast (and other CASCADE cards),Epic Experiment...etc.
About all cards like Nightveil Specter, Elkin Bottle, Muse Vessel ....etc...it is a partial work, because it can only play the card in "normal cast". Anyway there are really few cards with this kind of interaction!


About other question like flashback and cascade the card should work as expected! (Anyway need more tests)
You can’t use OverLoad with Flashback or Cascade
See, when you use an ability like cascade or flashback to cast a spell from a place you normally couldn’t, what you’re doing is casting it for an alternative cost (even “without paying its mana cost” still counts as an alternativee cost). overload, too, is an alternative cost. From : http://blogs.magicjudges.org/rulestips/2012/10/you-cant-use-overload-with-flashback-or-cascade/

UPDATE: CHANGELOG REV 4.1
- Fixed issue with FLASHBACK
ver 4.0 Keep index also when the spell was resolved, so Flashback had problem to works because it was retrieving the old informations about how the spell was played before.
For example : A card cast with overload (without legal targets) went into graveyard, the we played Past in Flames, if there weren't legal targets in play the card into graveyard was playable anyway.


Here you can find the last card version please help me to make other tests :

CYCLONIC RIFT NEO&LBN V4.1 | Open
Code: Select all
<?xml version='1.0' encoding='UTF-8'?>
    <CARD_V2 ExportVersion="1">
      <FILENAME text="NEO_LBN_CYCLONIC_RIFT_992270798" />
      <CARDNAME text="CYCLONIC_RIFT" />
      <TITLE>
        <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Cyclonic Rift]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Faille cyclonique]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Grieta ciclónica]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Rift des Sturmtiefs]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Squarcio Ciclonico]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[サイクロンの裂け目]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[회오리 균열]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Циклонический Разлом]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Fenda Ciclônica]]></LOCALISED_TEXT>
      </TITLE>
      <MULTIVERSEID value="992270798" />
      <ARTID value="992270798" />
      <ARTIST name="Chris Rahn" />
      <CASTING_COST cost="{1}{U}" />
      <FLAVOURTEXT>
        <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[The Izzet specialize in unnatural disaster.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les Izzet sont spécialisés dans les catastrophes artificielles.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Los ízzet se especializan en desastres no naturales.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Die Izzet sind auf unnatürliche Katastrophen spezialisiert.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Gli Izzet sono specializzati in catastrofi innaturali.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[イゼット団は不自然災害を専門としている。]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[이젯 길드의 특기는 부자연스러운 재해다.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Иззеты являются мастерами неприродных катастроф.]]></LOCALISED_TEXT>
        <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[A especialidade dos Izzet são os desastres não naturais.]]></LOCALISED_TEXT>
      </FLAVOURTEXT>
      <TYPE metaname="Instant" />
      <EXPANSION value="RTR" />
      <RARITY metaname="R" />
   
       <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_ANY">
            <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Return target nonland permanent you don’t control to its owner’s hand.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Renvoyez un permanent non-terrain ciblé que vous ne contrôlez pas dans la main de son propriétaire.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Regresa el permanente objetivo que no sea tierra que no controles a la mano de su propietario.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Bringe eine bleibende Karte deiner Wahl, die kein Land ist und die du nicht kontrollierst, auf die Hand ihres Besitzers zurück.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Fai tornare un permanente non terra bersaglio che non controlli in mano al suo proprietario.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[あなたがコントロールしていない土地でないパーマネント1つを対象とし、それをオーナーの手札に戻す。]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[당신이 조종하지 않는 지속물 중 대지가 아닌 지속물 한 개를 목표로 정한다. 그 지속물을 소유자의 손으로 되돌린다.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Верните целевой не являющийся землей перманент, который не находится под вашим контролем, в руку его владельца.]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Devolva a permanente alvo que não seja um terreno e que você não controle para a mão de seu dono.]]></LOCALISED_TEXT>
          <CONTINUOUS_ACTION layer="0">
            if EffectSource():GetZone() ~= ZONE_EXILE then
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
               if chest ~= nil then
                 local nState = chest:Get_Int(1524)
                 local nStateB = LinkedDC():Get_Int(1524)
                 if (nState == 1) or (nStateB == 1) then
                    EffectSource():GetCurrentCharacteristics():GrantAbility(20)
                 else
                    EffectSource():GetCurrentCharacteristics():GrantAbility(10)
                 end
               else
                  chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 0)
               end
            end
           </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

       <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_EXILE">
          <CONTINUOUS_ACTION layer="0">
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
               if chest ~= nil then
                 local nState = chest:Get_Int(1524)
                 local nStateB = LinkedDC():Get_Int(1524)
                 if (nState == 1) or (nStateB == 1) then
                    EffectSource():GetCurrentCharacteristics():GrantAbility(20)
                 else
                    EffectSource():GetCurrentCharacteristics():GrantAbility(10)
                 end
               else
                  chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 0)
               end
           </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

      <STATIC_ABILITY linked_ability_group="1" active_zone="ZONE_HAND">
   <CONTINUOUS_ACTION layer="1">
      local refplayer = EffectSource():GetPlayer()
                local Chest_Id = EffectSource():GetRef()
                local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
      if chest ~= nil then
         local valor = LinkedDC():Get_Int(1524)
         LinkedDC():Set_Int(1524, 1)
         if EffectController():CanCastSpellUsingResourceCost( EffectSource(), 3 ) then
            chest:Set_Int(1525,1)   
         else
            chest:Set_Int(1525,0)
         end
         LinkedDC():Set_Int(1524, valor)   
      else
         chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
         chest:Set_Int(1525,0)
      end
   </CONTINUOUS_ACTION>
      </STATIC_ABILITY>

     <ACTIVATED_ABILITY forced_skip="1" qualifier="Alternate"  active_zone="ZONE_HAND" linked_ability_group="1">
            <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Overload {6}{U} |(You may cast this spell for its overload cost. If you do, change its text by replacing all instances of "target" with "each.")|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Surcharge {6}{U} |(Vous pouvez lancer ce sort pour son coût de surcharge. Si vous faites ainsi, modifiez son texte en remplaçant toutes les occurrences de « ciblé(e) » par « chaque ».)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Sobrecarga {6}{U} | (Puedes lanzar este hechizo por su coste de sobrecarga. Si lo haces, cambia su texto reemplazando "el
permanente objetivo" por "cada permanente".)]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Überlast {6}{U} |(Du kannst diesen Zauber für seine Überlast-Kosten wirken. Falls du dies tust, verändere seinen Text, indem du im Text alle Vorkommen von „deiner Wahl" durch „jeder" ersetzt.)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Sovraccarico {6}{U} |(Puoi lanciare questa magia per il suo costo di sovraccarico. Se lo fai, cambiane il testo sostituendo "un permanente non terra bersaglio" con "ogni permanente non terra".)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[超過 {6}{U} |(あなたはこの呪文をその超過コストで唱えてもよい。そうした場合、あなたがコントロールしていない土地でない各パーマネントをそれぞれオーナーの手札に戻す。)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[과부하 {6}{U} |(당신은 과부하 비용을 지불하여 이 주문을 발동할 수 있다. 그럴 경우, 이 주문은 "당신이 조종하지 않는 지속물 중 대지가 아닌 각 지속물을 소유자의 손으로 되돌린다"로 내용이 변한다.)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Перегрузка {6}{U} |(Вы можете разыграть это заклинание за его стоимость Перегрузки. Если вы это делаете, измените в его тексте все слова «целевой» на «каждый».)|]]></LOCALISED_TEXT>
            <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Sobrecarga {6}{U} |(Você pode conjurar esta mágica pagando seu custo de sobrecarga. Se fizer isso, altere seu texto substituindo todas as ocorrências de "a permanente alvo" por "cada permanente".)|]]></LOCALISED_TEXT>
             <COST type="Generic">
            <PREREQUISITE>
                local refplayer = EffectSource():GetPlayer()
                local Chest_Id = EffectSource():GetRef()
                local chest = refplayer:PlayerDataChest():Get_Chest(Chest_Id)
                if chest ~= nil then
                   return chest:Get_Int(1525) == 1
                end   
                return false
             </PREREQUISITE>
          <PLAY_TIME_ACTION>
             RSN_MarkManaAbilityStart()
          </PLAY_TIME_ACTION>
                 <PLAY_TIME_ACTION>
               local spellToCast = EffectSource()
                    local refplayer = EffectSource():GetPlayer()
                  local Chest_Id = EffectSource():GetRef()
                  local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                  chest:Set_Int(1524, 1)
                  </PLAY_TIME_ACTION>
           </COST>
          <RESOLUTION_TIME_ACTION>
               local spellToCast = EffectSource()
               EffectController():CastSpellUsingResourceCost( spellToCast, 3 )
             </RESOLUTION_TIME_ACTION>
          <RESOLUTION_TIME_ACTION>
            RSN_MarkManaAbilityEnd()
          </RESOLUTION_TIME_ACTION>
            </ACTIVATED_ABILITY>

     <SPELL_ABILITY  resource_id="10">
       <TARGET_DEFINITION id="0">   
              EffectDC():Set_Int(1321, 3)
              local filter = ClearFilter()
              filter:SetZone( ZONE_BATTLEFIELD )
              filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
              local subfilter = filter:AddSubFilter_Or()
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
                    subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
            </TARGET_DEFINITION>     
           <TARGET tag="CARD_QUERY_CHOOSE_NONLAND_PERMANENT_TO_PUT_INTO_HAND" definition="0" compartment="0" count="1"/>
           <RESOLUTION_TIME_ACTION>   
              if EffectDC():Get_Int(1321) == 3 then
                 local refplayer = EffectSource():GetPlayer()
                 local Chest_Id = EffectSource():GetRef()
                 local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
                 chest:Set_Int(1524, 0)
                 local target = EffectDC():Get_Targets(0) and EffectDC():Get_Targets(0):Get_CardPtr(0)
                 if  target ~= nil then
                     target:PutInHand()
                 end
              end
            </RESOLUTION_TIME_ACTION>
            <FILTER filter_id="1">         
                    local filter = ClearFilter()
                    filter:SetZone( ZONE_BATTLEFIELD )
                    filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                    local subfilter = filter:AddSubFilter_Or()
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                          subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                </FILTER>
            <RESOLUTION_TIME_ACTION filter_id="1">
                if EffectDC():Get_Int(1321) ~= 3 then
                   if FilteredCard() ~= nil then
                      FilteredCard():PutInHand()
                   end
                end
           </RESOLUTION_TIME_ACTION>
    </SPELL_ABILITY>     

     <SPELL_ABILITY  resource_id="20" linked_ability_group="1">
           <FILTER filter_id="1">         
                local filter = ClearFilter()
                      filter:SetZone( ZONE_BATTLEFIELD )
                      filter:Add( FE_CONTROLLER, OP_NOT, EffectController())
                      local subfilter = filter:AddSubFilter_Or()
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ARTIFACT )
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )         
                            subfilter:Add( FE_TYPE, OP_IS, CARD_TYPE_ENCHANTMENT )
                </FILTER>
                   <PLAY_TIME_ACTION>
               local refplayer = EffectSource():GetPlayer()
               local Chest_Id = EffectSource():GetRef()
               local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
               chest:Set_Int(1524, 0)
               LinkedDC():Set_Int(1524, 1)
             </PLAY_TIME_ACTION>         
           <RESOLUTION_TIME_ACTION filter_id="1">
                 if FilteredCard() ~= nil then
                    FilteredCard():PutInHand()
                 end
           </RESOLUTION_TIME_ACTION>
       <SFX text="GLOBAL_TIDE_PLAY" />
     </SPELL_ABILITY>   

<TRIGGERED_ABILITY linked_ability_group="1" replacement_effect="1" active_zone="ZONE_ANY">
 <TRIGGER value="SPELL_RESOLVED">
   return  TriggerObject() == Object()
</TRIGGER>
      <RESOLUTION_TIME_ACTION>
    local refplayer = EffectSource():GetPlayer()
    local Chest_Id = EffectSource():GetRef()
    local chest = refplayer:PlayerDataChest():Make_Chest(Chest_Id)
    chest:Clear()
    LinkedDC():Clear()
    </RESOLUTION_TIME_ACTION>
   </TRIGGERED_ABILITY>


        <UTILITY_ABILITY resource_id="3">
          <COST mana_cost="{6}{U}" type="Mana" />
       </UTILITY_ABILITY>

           <AI_AVAILABILITY type="in_response" response_source="1" />
           <AI_AVAILABILITY window_step="begin_combat" window_turn="their_turn" type="window" />
           <AI_AVAILABILITY window_step="declare_attackers" window_turn="their_turn" type="window" />
           <AI_AVAILABILITY window_step="main_1" window_turn="my_turn" type="window" />
           <AI_AVAILABILITY window_step="declare_blockers" type="window" />
           <AI_AVAILABILITY window_step="end_of_turn" type="window" />
           <AI_AVAILABILITY type="in_response" response_source="1" response_target="1" />
           <AI_BASE_SCORE score="900" zone="ZONE_HAND" />
</CARD_V2>
Possible interactions cards List UPDATE ver 1.1 | Open
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

Re: Overload at 95%

Postby RiiakShiNal » 30 Aug 2014, 21:44

NeoAnderson wrote:This is so bad, also because we don't have any TRIGGER that fires when we use CopySpell functions, so we cannot understand when a spell is generating a copy. For Example with the tokens we don't have this problem because when we use PutTokenOntoBattlefield you can pass a DataChest as parameter!
If CopySpell returns a card pointer (which I believe it does) then you can always use the ObjectDC functions (accessing another card's chest is exactly what it was designed for).

You would simply store the card pointer you get in a local (or a register) then pass it to RSN_GetObjectDC() with the second parameter set to true to create and get the new ObjectDC chest then set what ever you want.

NeoAnderson wrote:
ANYWAY : The last version is really close to be a full work approximation as i said in the post above we have only one kind of interaction that is limited (when we use cards who says "You can play a card from a zone") in this case we can only play "Normal cast". So what you think can we consider this OVERLOAD good enough?
I can't answer that at this point I have not analyzed the code to see if there are any areas where it will fail (I have not looked at Strive yet either as I'm still in the process of an OS upgrade, though I'm probably going to have to kill that soon as it has only been slowly advancing for the last week).
RiiakShiNal
Programmer
 
Posts: 2185
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 497 times

Re: Overload at 95%

Postby NeoAnderson » 30 Aug 2014, 22:19

RiiakShiNal wrote:
NeoAnderson wrote:This is so bad, also because we don't have any TRIGGER that fires when we use CopySpell functions, so we cannot understand when a spell is generating a copy. For Example with the tokens we don't have this problem because when we use PutTokenOntoBattlefield you can pass a DataChest as parameter!
If CopySpell returns a card pointer (which I believe it does) then you can always use the ObjectDC functions (accessing another card's chest is exactly what it was designed for).
You would simply store the card pointer you get in a local (or a register) then pass it to RSN_GetObjectDC() with the second parameter set to true to create and get the new ObjectDC chest then set what ever you want.
But the main problem is in this way you have to modify the copy spell to do what you want ( i already tested copyspell function return a temporary card, so also a cardpointer, and it expire at end of the ABILITY (SPELL, ACTIVATED, TRIGGER)you cannot store longer also if you protect it). So if you don't cast the copy during the ability you cannot keep it anymore.
Anyway there i no way from an external card to understand if a copy is cast (or better to understand the copy who has copied).
NeoAnderson wrote:ANYWAY : The last version is really close to be a full work approximation as i said in the post above we have only one kind of interaction that is limited (when we use cards who says "You can play a card from a zone") in this case we can only play "Normal cast". So what you think can we consider this OVERLOAD good enough?
RiiakShiNal wrote:I can't answer that at this point I have not analyzed the code to see if there are any areas where it will fail (I have not looked at Strive yet either as I'm still in the process of an OS upgrade, though I'm probably going to have to kill that soon as it has only been slowly advancing for the last week).
I know that you still have to give me an answer about strive :wink: don't worry just add to the "TO DO LIST" :lol: .
Anyway the last small thing unsolved i think is unsolvable, but is not a big deal, because there are really few cards (about 10 cards) that have that effect and the overload cards can be still played but without overload function.
NeoAnderson
 
Posts: 914
Joined: 10 Sep 2013, 07:49
Has thanked: 18 times
Been thanked: 139 times

PreviousNext

Return to Programming Talk

Who is online

Users browsing this forum: No registered users and 28 guests


Who is online

In total there are 28 users online :: 0 registered, 0 hidden and 28 guests (based on users active over the past 10 minutes)
Most users ever online was 4143 on 23 Jan 2024, 08:21

Users browsing this forum: No registered users and 28 guests

Login Form