It is currently 15 Sep 2025, 20:20
   
Text Size

Formal Request Thread

Moderator: CCGHQ Admins

Re: Formal Request Thread

Postby RiiakShiNal » 15 Aug 2013, 21:04

That is because you have an invalid XML format (you closed an ACTIVATED_ABILITY twice (it even told you what line [69] and position in the line [5] to look at):
Code: Select all
...
    <AI_AVAILABILITY type="in_response" response_source="1" />
    <AI_AVAILABILITY type="in_response" response_target="1" />
  </ACTIVATED_ABILITY>
  </ACTIVATED_ABILITY>
  <TARGET tag="CARD_QUERY_CHOOSE_PERMANENT_TO_TAP_OR_UNTAP" definition="0" compartment="0" count="1" />
    <TARGET_DEFINITION id="0">
...
RiiakShiNal
Programmer
 
Posts: 2189
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 497 times

Re: Formal Request Thread

Postby drleg3nd » 16 Aug 2013, 03:37

ok I really don't know what im doing wrong with this card..i took off the 2nd activated ability but still no good.
| Open
Code: Select all
<?xml version='1.0' encoding='UTF-8'?>
<CARD_V2 ExportVersion="1">
  <FILENAME text="HIDDEN_STRINGS_812369021" />
  <CARDNAME text="HIDDEN_STRINGS" />
  <TITLE>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Hidden Strings]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Fils cachés]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Hilos ocultos]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Verborgene Fäden]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Fili Nascosti]]></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[Hidden Strings]]></LOCALISED_TEXT>
  </TITLE>
  <MULTIVERSEID value="812369021" />
  <ARTID value="812369021" />
  <ARTIST name="Daarken" />
  <CASTING_COST cost="{1}{U}" />
  <TYPE metaname="Sorcery" />
  <EXPANSION value="DGM" />
  <RARITY metaname="C" />
  <ACTIVATED_ABILITY>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[You may tap or untap target permanent, then you may tap or untap another target permanent.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Vous pouvez engager ou dégager le permanent ciblé, puis engager ou dégager un autre permanent ciblé.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Puedes girar o enderezar el permanente objetivo, luego puedes girar o enderezar otro permanente objetivo.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Du kannst eine bleibende Karte deiner Wahl tappen oder enttappen, dann kannst du eine andere bleibende Karte deiner Wahl tappen oder enttappen.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Puoi TAPpare o STAPpare un permanente bersaglio, poi puoi TAPpare o STAPpare un altro permanente bersaglio.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[パーマネント1つと、他のパーマネント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[You may tap or untap target permanent, then you may tap or untap another target permanent.]]></LOCALISED_TEXT>
  <TARGET tag="CARD_QUERY_CHOOSE_PERMANENT_TO_TAP_OR_UNTAP" definition="0" compartment="0" count="1" />
    <TARGET_DEFINITION id="0">
    local filter = ClearFilter()
    filter:Add( FE_CARD_INSTANCE, OP_NOT, EffectSource() )
    TFM_FilterPermanents(filter)
    </TARGET_DEFINITION>
    <RESOLUTION_TIME_ACTION>
    local player = EffectController()
    local target = EffectDC():Get_Targets(0):Get_CardPtr(0)
    if player ~= nil and target ~= nil then
       player:BeginNewMultipleChoice()
       player:AddMultipleChoiceAnswer("UI_CONDITIONAL_QUESTION_YES")
       player:AddMultipleChoiceAnswer("UI_CONDITIONAL_QUESTION_NO")
       player:AskMultipleChoiceQuestion("TFM_CARD_QUERY_TAP_OR_UNTAP_THIS_PERMANENT", target)
    end
    </RESOLUTION_TIME_ACTION>
    <RESOLUTION_TIME_ACTION>
    local player = EffectController()
    local target = EffectDC():Get_Targets(0):Get_CardPtr(0)
    if player ~= nil and target ~= nil and player:GetMultipleChoiceResult() == 0 then
       if target:IsTapped() then
          target:Untap()
       else
          target:Tap()
       end
    end
    </RESOLUTION_TIME_ACTION>
    <AI_SIMPLIFIED_TARGETING compartment="0" hint="HINT_NEUTRAL" />
    <AI_AVAILABILITY window_step="begin_combat" window_turn="their_turn" type="window" />
    <AI_AVAILABILITY window_step="declare_attackers" window_turn="my_turn" type="window" />
    <AI_AVAILABILITY window_step="main_1" window_turn="my_turn" type="window" />
    <AI_AVAILABILITY window_step="main_2" window_turn="my_turn" type="window" />
    <AI_AVAILABILITY window_step="end_of_turn" type="window" />
    <AI_AVAILABILITY type="in_response" response_source="1" />
    <AI_AVAILABILITY type="in_response" response_target="1" />
  </ACTIVATED_ABILITY>
  <TARGET tag="CARD_QUERY_CHOOSE_PERMANENT_TO_TAP_OR_UNTAP" definition="0" compartment="0" count="1" />
    <TARGET_DEFINITION id="0">
    local filter = ClearFilter()
    filter:Add( FE_CARD_INSTANCE, OP_NOT, EffectSource() )
    TFM_FilterPermanents(filter)
    </TARGET_DEFINITION>
    <RESOLUTION_TIME_ACTION>
    local player = EffectController()
    local target = EffectDC():Get_Targets(0):Get_CardPtr(0)
    if player ~= nil and target ~= nil then
       player:BeginNewMultipleChoice()
       player:AddMultipleChoiceAnswer("UI_CONDITIONAL_QUESTION_YES")
       player:AddMultipleChoiceAnswer("UI_CONDITIONAL_QUESTION_NO")
       player:AskMultipleChoiceQuestion("TFM_CARD_QUERY_TAP_OR_UNTAP_THIS_PERMANENT", target)
    end
    </RESOLUTION_TIME_ACTION>
    <RESOLUTION_TIME_ACTION>
    local player = EffectController()
    local target = EffectDC():Get_Targets(0):Get_CardPtr(0)
    if player ~= nil and target ~= nil and player:GetMultipleChoiceResult() == 0 then
       if target:IsTapped() then
          target:Untap()
       else
          target:Tap()
       end
    end
    </RESOLUTION_TIME_ACTION>
    <AI_SIMPLIFIED_TARGETING compartment="0" hint="HINT_NEUTRAL" />
    <AI_AVAILABILITY window_step="begin_combat" window_turn="their_turn" type="window" />
    <AI_AVAILABILITY window_step="declare_attackers" window_turn="my_turn" type="window" />
    <AI_AVAILABILITY window_step="main_1" window_turn="my_turn" type="window" />
    <AI_AVAILABILITY window_step="main_2" window_turn="my_turn" type="window" />
    <AI_AVAILABILITY window_step="end_of_turn" type="window" />
    <AI_AVAILABILITY type="in_response" response_source="1" />
    <AI_AVAILABILITY type="in_response" response_target="1" />
  </ACTIVATED_ABILITY>
  <SPELL_ABILITY linked_ability_group="1">
   <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Cipher]]></LOCALISED_TEXT>
   <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Cryptage]]></LOCALISED_TEXT>
   <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Cifrar.]]></LOCALISED_TEXT>
   <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Chiffrieren]]></LOCALISED_TEXT>
   <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Cifrare]]></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[Cifrar]]></LOCALISED_TEXT>
   <RESOLUTION_TIME_ACTION>
      local filter = ClearFilter()
      filter:Add(FE_TYPE, OP_IS, CARD_TYPE_CREATURE)
      filter:Add(FE_CONTROLLER, OP_IS, EffectController() )
      if EffectSource():IsToken() == false then
         EffectController():ChooseItem( "CARD_QUERY_CHOOSE_A_CARD_TO_ENCODE_ONTO", EffectDC():Make_Targets(1), QUERY_FLAG_MAY )
      end
    </RESOLUTION_TIME_ACTION>
   <RESOLUTION_TIME_ACTION>
      local cipherDC = EffectDC():Get_Targets(1)
      if cipherDC ~= nil then
         local chosenCard = cipherDC:Get_CardPtr(0)
         if chosenCard ~= nil then
            local effectSource = EffectSource()
         
            if (effectSource ~= nil) then
               effectSource:Exile()
             
               effectSource:NailOnto(chosenCard)
               LinkedDC():Set_CardPtr(0, effectSource)
            end
         end
      end
    </RESOLUTION_TIME_ACTION>
   <CONTINUOUS_ACTION layer="6">
      local chosenCardDC = EffectDC():Get_Targets(1)
      if chosenCardDC ~= nil then
         local chosencard = chosenCardDC:Get_CardPtr(0)
         if chosencard ~= nil then
            local characteristics = chosencard:GetCurrentCharacteristics()
            characteristics:GrantAbility(1)
            chosencard:AddScore(200)
         end
      end
    </CONTINUOUS_ACTION>
   <DURATION>
      if LinkedDC():Get_CardPtr(0) ~= nil then
         local chosenCardDC = EffectDC():Get_Targets(1)
         if chosenCardDC ~= nil and chosenCardDC:Get_CardPtr(0) ~= nil then
            return false
         end
      end
      return true
    </DURATION>
  </SPELL_ABILITY>
</CARD_V2>
drleg3nd
 
Posts: 528
Joined: 14 May 2012, 20:05
Has thanked: 5 times
Been thanked: 30 times

Re: Formal Request Thread

Postby sumomole » 16 Aug 2013, 04:20

drleg3nd wrote:ok I really don't know what im doing wrong with this card..i took off the 2nd activated ability but still no good.
This is a sorcery, don't use activated abilities, try this.
| Open
Code: Select all
      <SPELL_ABILITY>
        <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[You may tap or untap target permanent, then you may tap or untap another target permanent.]]></LOCALISED_TEXT>
        <TARGET tag="CARD_QUERY_CHOOSE_PERMANENT_TO_TAP_OR_UNTAP" definition="0" compartment="0" count="1" dependency="1" />
        <TARGET tag="CARD_QUERY_CHOOSE_PERMANENT_TO_TAP_OR_UNTAP" definition="1" compartment="1" count="1" />
        <TARGET_DEFINITION id="0">
        local filter = ClearFilter()
        filter:Add( FE_IS_PERMANENT, true )
        </TARGET_DEFINITION>
        <TARGET_DEFINITION id="1">
        local filter = ClearFilter()
        filter:Add( FE_IS_PERMANENT, true )
        local first_card = EffectDC():Get_Targets(0):Get_CardPtr(0)
        if first_card ~= nil then
           filter:Add( FE_CARD_INSTANCE, OP_NOT, first_card )
        end
        </TARGET_DEFINITION>
        <RESOLUTION_TIME_ACTION repeating="1">
        local n = MTG():GetActionRepCount()
        local player = EffectController()
        local parity = n % 2
        if n &lt; 4 then
          local target = EffectDC():Get_Targets(n/2):Get_CardPtr(0)
          if target ~= nil then
            if parity == 0 then
              player:BeginNewMultipleChoice()   
              player:AddMultipleChoiceAnswer( "CARD_QUERY_OPTION_PERMANENT_TAP" )
              player:AddMultipleChoiceAnswer( "CARD_QUERY_OPTION_PERMANENT_UNTAP" )   
              player:AskMultipleChoiceQuestion( "CARD_QUERY_MC_TAP_OR_UNTAP", target )
            else
               local result = player:GetMultipleChoiceResult()
              if result == 0 then
                 target:Tap()
              elseif result == 1 then
                 target:Untap()
              end
            end
          end
           return true       
        else
           return false
        end
        </RESOLUTION_TIME_ACTION>
      </SPELL_ABILITY>
EDIT: I made ​​a mistake, it have two different targets, I fixed it.
Last edited by sumomole on 16 Aug 2013, 04:57, edited 1 time in total.
User avatar
sumomole
Programmer
 
Posts: 611
Joined: 07 Jun 2011, 08:34
Has thanked: 51 times
Been thanked: 234 times

Re: Formal Request Thread

Postby MC Brodie » 16 Aug 2013, 04:32

For one the tap/untap target permanent is a <SPELL_ABILITY> not an <ACTIVATED_ABILITY>. Although it was an activated ability in the card you got the code from, this card is a sorcery. In the filter block I don't think you need to filter out the EffectSource() since since this card won't be a permanent on the battlefield but in the end that shouldn't cause you problems. You could remove this line:

Code: Select all
filter:Add( FE_CARD_INSTANCE, OP_NOT, EffectSource() )
Also, you don't have the complete cipher code. You still need the triggered ability that lets you copy the card if the encoded creature does combat damage to a player.

In the end, I am not entirely sure on how to code this card. The way the card reads, you choose 1 target then tap/untap the permanent, then you choose another target and tap/untap the second permanent. I couldn't figure out how to choose the targets in two steps. In all my versions you would choose 2 targets and are then asked to tap/untap those permanents. I don't know if this matters or not. Then again this may be the way the card should be work.


Edit: Or, just do what sumomole said :D . I've seen the GetActionRepCount() and parity thing in a couple of cards but was never sure on what it did. AFter looking at it again, I see its the repetition count on a repeating Resolution_Time_Action which would answer my question above. Thanks sumomole
-----------------------------------------------------------------------
Song of the Day: 46 and 2 (cover)
MC Brodie
 
Posts: 310
Joined: 01 Jun 2013, 00:10
Has thanked: 44 times
Been thanked: 34 times

Re: Formal Request Thread

Postby drleg3nd » 16 Aug 2013, 05:54

thx guys,will try it out and let you know how it works
drleg3nd
 
Posts: 528
Joined: 14 May 2012, 20:05
Has thanked: 5 times
Been thanked: 30 times

Re: Formal Request Thread

Postby Zarroc » 16 Aug 2013, 13:47

Hey guys

can anybody help me with Glimpse of Nature? I implemented "Whenever you cast a creature spell,..., draw a card" as a TRIGGERED_ABILITY but i have absoluteloy no idea how to check if Glimpse of Nature was cast this turn.
User avatar
Zarroc
 
Posts: 16
Joined: 28 Jun 2013, 13:06
Has thanked: 1 time
Been thanked: 3 times

Re: Formal Request Thread

Postby MC Brodie » 16 Aug 2013, 14:00

Try having the spell ability activate a delayed trigger that lasts until EOT
-----------------------------------------------------------------------
Song of the Day: 46 and 2 (cover)
MC Brodie
 
Posts: 310
Joined: 01 Jun 2013, 00:10
Has thanked: 44 times
Been thanked: 34 times

Re: Formal Request Thread

Postby Zarroc » 16 Aug 2013, 14:51

Thanks for your reply but i'm new to modding dotp so i don't know how to implement a delayed trigger can you give me an example pls? :D
User avatar
Zarroc
 
Posts: 16
Joined: 28 Jun 2013, 13:06
Has thanked: 1 time
Been thanked: 3 times

Re: Formal Request Thread

Postby MC Brodie » 16 Aug 2013, 15:14

Search this thread for "CreateDelayedTrigger" and it should give you a few examples.

Alternatively, I'd suggest to download a bunch of cards from the experienced modders and use Riiak's Deck Builder. You can do an advanced search of the xmls without having to unpack all of the wads. His deck builder is very helpful in making cards.
-----------------------------------------------------------------------
Song of the Day: 46 and 2 (cover)
MC Brodie
 
Posts: 310
Joined: 01 Jun 2013, 00:10
Has thanked: 44 times
Been thanked: 34 times

Re: Formal Request Thread

Postby BloodReyvyn » 16 Aug 2013, 15:56

Started making one of the cards from the new "Theros" set spoilers, but I was very unsure about this ability and am not sure if it is meant to be a subtype, supertype, type, or something else...

Polukranos, World Eater (Untested) | Open
Image
Code: Select all
<?xml version='1.0' encoding='UTF-8'?>
<CARD_V2 ExportVersion="1">
  <FILENAME text="POLUKRANOS_WORLD_EATER_973001" />
  <CARDNAME text="POLUKRANOS_WORLD_EATER" />
  <TITLE>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Polukranos, World Eater]]></LOCALISED_TEXT>
  </TITLE>
  <MULTIVERSEID value="973001" />
  <ARTID value="973001" />
  <ARTIST name="Johann Bodin" />
  <CASTING_COST cost="{2}{G}{G}" />
  <SUPERTYPE metaname="Legendary" />
  <TYPE metaname="Creature" />
  <SUB_TYPE metaname="Hydra" />
  <EXPANSION value="M12" />
  <RARITY metaname="M" />
  <POWER value="5" />
  <TOUGHNESS value="5" />
  <ACTIVATED_ABILITY>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)]]></LOCALISED_TEXT>
    <COST mana_cost="{X}{X}{G}" type="Mana" />
    <AVAILABILITY>
      if TriggerObject():GetSuperType():Test(SUPERTYPE_MONSTROUS) ~= true then
        return true
      else
        return false
      end
    </AVAILABILITY>
    <RESOLUTION_TIME_ACTION>
      if EffectController() ~= nil then
        EffectSource():AddCounters( MTG():PlusOnePlusOneCounters(), GetEffectX() )
      end
    </RESOLUTION_TIME_ACTION>
    <CONTINUOUS_ACTION layer="4">
      if EffectSource() ~= nil then
       local characteristics = EffectSource():GetCurrentCharacteristics()
       local subtype = characteristics:SuperType_GetWritable()
       subtype:Add( SUPERTYPE_MONSTROUS )
      end
    </CONTINUOUS_ACTION>
    <DURATION>
      return (EffectDC():Get_Targets(0):Get_CardPtr(0) == nil)
    </DURATION>
    <TARGET tag="CARD_QUERY_CHOOSE_DEAL_1_DAMAGE" definition="0" compartment="0" count=GetEffectX() damage_assignment="1" />
    <TARGET_DEFINITION id="0">
      local filter = ClearFilter()
      filter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
      filter:Add( FE_TEAM, OP_NOT, EffectController():GetTeam() )
    </TARGET_DEFINITION>
    <RESOLUTION_TIME_ACTION>
      local source = EffectSourceLKI()
      local targetDC = EffectDC():Get_Targets(0)
      for i=0,(GetEffectX() - 1) do
       local target_creature = targetDC:Get_CardPtr(i)
       local damage = targetDC:Get_Assignment(i)
       if ( target_creature ~= nil ) then   
         source:DealDamageTo(damage, target_creature)
          target_creature:DealDamageTo(target_creature:GetCurrentCharacteristics():Power_Get(), EffectSource() ) 
       end
      end
    </RESOLUTION_TIME_ACTION>
    <AI_SIMPLIFIED_TARGETING compartment="0" hint="HINT_ENEMY_ONLY" />
  </ACTIVATED_ABILITY>
  <STATIC_ABILITY>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[When Polukranos, World Eater becomes monstrous, it deals X damage divided as you choose among any number of target creatures your opponents control. Those creatures deal damage equal to their power to Polukranos.]]></LOCALISED_TEXT>
  </STATIC_ABILITY>
  <SFX text="COMBAT_BITE_LARGE_ATTACK" power_boundary_min="4" power_boundary_max="-1" />
  <SFX text="COMBAT_BITE_SMALL_ATTACK" power_boundary_min="1" power_boundary_max="3" />
</CARD_V2>
Last edited by BloodReyvyn on 16 Aug 2013, 15:59, edited 1 time in total.
"There's an experience worse than blindness - it's the certainty that your vision is perfect and the horror that there's no world around you to see."
User avatar
BloodReyvyn
 
Posts: 421
Joined: 19 May 2013, 13:29
Has thanked: 53 times
Been thanked: 40 times

Re: Formal Request Thread

Postby Zarroc » 16 Aug 2013, 15:59

MC Brodie wrote:Search this thread for "CreateDelayedTrigger" and it should give you a few examples.

Alternatively, I'd suggest to download a bunch of cards from the experienced modders and use Riiak's Deck Builder. You can do an advanced search of the xmls without having to unpack all of the wads. His deck builder is very helpful in making cards.
I'm already using riiaks deckbuilder(great tool!) and I used the filters to find similar cards but that only helped me with the first part. I will test creating a delayed trigger when I'm at home :)
User avatar
Zarroc
 
Posts: 16
Joined: 28 Jun 2013, 13:06
Has thanked: 1 time
Been thanked: 3 times

Re: Formal Request Thread

Postby thefiremind » 16 Aug 2013, 16:13

BloodReyvyn wrote:Started making one of the cards from the new "Theros" set spoilers, but I was very unsure about this ability and am not sure if it is meant to be a subtype, supertype, type, or something else...
I'd like to read the rulings in order to be sure (too bad we can't yet) but according to me, it's not a type or anything like that, I think it's more of a status, something that doesn't affect the card in any way other than the abilities that care about it. You could use a LinkedDC register as a flag (remember to add linked_ability_group="1" to the abilities that read or write it):
Code: Select all
LinkedDC():Set_Int(0, 1) -- becomes monstrous
Code: Select all
if LinkedDC():Get_Int(0) ~= 1 then
   -- it isn't monstrous
end
then you leave the second ability as a dummy STATIC_ABILITY just to have the text on the card (as it is now), and make the first activated ability create a delayed ABILITY_RESOLVED trigger that actually does what the second ability is supposed to do. If you want to be picky, replicate the second ability text on the delayed trigger as well, so you can read it when selecting the targets.
Of course this approach won't be enough in case there are cards that make other cards monstrous.
< Former DotP 2012/2013/2014 modder >
Currently busy with life...
User avatar
thefiremind
Programmer
 
Posts: 3515
Joined: 07 Nov 2011, 10:55
Has thanked: 118 times
Been thanked: 722 times

Re: Formal Request Thread

Postby RiiakShiNal » 16 Aug 2013, 16:32

That approach also won't work properly if other cards need to check a card to see if it is "monstrous" as LinkedDC() is only accessible on a single card (can't be checked from other cards), if you are going to need to check it from a different card then you are probably going to need a more expansive workaround like my ObjectDC functions, my Characteristics functions, or you could always make your own system.
RiiakShiNal
Programmer
 
Posts: 2189
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 497 times

Re: Formal Request Thread

Postby BloodReyvyn » 16 Aug 2013, 16:40

Kinda figured it would be something like that.

However, unless it conflicts with some other rules using Supertype or subtype would not be a terrible approximation if only that it would be easy to check "monstrous status" or even filter "monstrous" cards with new cards as they come out without having to touch code in existing cards. I used Supertype because I thought it would be cool to have a card that was a Monstrous Legendary Creature. :P
"There's an experience worse than blindness - it's the certainty that your vision is perfect and the horror that there's no world around you to see."
User avatar
BloodReyvyn
 
Posts: 421
Joined: 19 May 2013, 13:29
Has thanked: 53 times
Been thanked: 40 times

Re: Formal Request Thread

Postby RiiakShiNal » 16 Aug 2013, 17:36

Well, without seeing the rulings we are still just guessing about what "monstrous" is, so it very well could be a Super- or Sub-Type. If so then that would definitely alleviate the issues with needing to use a LinkedDC() or ObjectDC workaround.
RiiakShiNal
Programmer
 
Posts: 2189
Joined: 16 May 2011, 21:37
Has thanked: 75 times
Been thanked: 497 times

PreviousNext

Return to 2014

Who is online

Users browsing this forum: No registered users and 18 guests

Main Menu

User Menu

Our Partners


Who is online

In total there are 18 users online :: 0 registered, 0 hidden and 18 guests (based on users active over the past 10 minutes)
Most users ever online was 7967 on 09 Sep 2025, 23:08

Users browsing this forum: No registered users and 18 guests

Login Form