Page 20 of 26

Re: Report cards error here

PostPosted: 22 Sep 2013, 15:57
by GrovyleXShinyCelebi
Cool, also, do you know how to set an interrogation so only to check permanents (I know permanent isn't a card type and looking through the interrogation functions I can't find any way to make it so an interrogation will check when a permanent enters the graveyard from the battlefield this turn; I don't yet know if AddType works for interrogations).

Re: Report cards error here

PostPosted: 22 Sep 2013, 18:19
by thefiremind
GrovyleXShinyCelebi wrote:Cool, also, do you know how to set an interrogation so only to check permanents (I know permanent isn't a card type and looking through the interrogation functions I can't find any way to make it so an interrogation will check when a permanent enters the graveyard from the battlefield this turn; I don't yet know if AddType works for interrogations).
If something enters the battlefield from the graveyard, then it's a permanent, there's no doubt about it: it can't be instant or sorcery because it entered the battlefield, and it can't be an invisible token because it was in the graveyard. So I'd suggest to ignore the check for the card type.

Re: Report cards error here

PostPosted: 22 Sep 2013, 23:11
by GrovyleXShinyCelebi
thefiremind wrote:
GrovyleXShinyCelebi wrote:Cool, also, do you know how to set an interrogation so only to check permanents (I know permanent isn't a card type and looking through the interrogation functions I can't find any way to make it so an interrogation will check when a permanent enters the graveyard from the battlefield this turn; I don't yet know if AddType works for interrogations).
If something enters the battlefield from the graveyard, then it's a permanent, there's no doubt about it: it can't be instant or sorcery because it entered the battlefield, and it can't be an invisible token because it was in the graveyard. So I'd suggest to ignore the check for the card type.
Odd, I tried exactly what you said with Bitter Ordeal, and each time my spell hits the graveyard a new clone of the spell pops up, then another one appears when THAT clone hits the graveyard, and it's just an endless cycle.

I'm sure I said from ZONE_BATTLEFIELD, not ZONE_STACK. I don't have access to my code now, but do you know why this is happening?

Re: Report cards error here

PostPosted: 22 Sep 2013, 23:36
by thefiremind
GrovyleXShinyCelebi wrote:Odd, I tried exactly what you said with Bitter Ordeal, and each time my spell hits the graveyard a new clone of the spell pops up, then another one appears when THAT clone hits the graveyard, and it's just an endless cycle.
This is the code from Caller of the Claw (official expansion):
Caller of the Claw official interrogation code | Open
Code: Select all
    local interrogation = MTG():ClearInterrogationQuery()
    interrogation:SetPlayer( EffectController() )
    interrogation:SetFromZone( ZONE_BATTLEFIELD )
    interrogation:SetToZone( ZONE_GRAVEYARD )
    interrogation:SetType( CARD_TYPE_CREATURE )
    interrogation:SetNonTokenOnly()
    local tokens = interrogation:Count( INTERROGATE_CARDS_MOVED_ZONE, INTERROGATE_THIS_TURN )
My guess was that the following should be enough:
My guess about what's enough for gravestorm | Open
Code: Select all
    local interrogation = MTG():ClearInterrogationQuery()
    interrogation:SetFromZone( ZONE_BATTLEFIELD )
    interrogation:SetToZone( ZONE_GRAVEYARD )
    local count = interrogation:Count( INTERROGATE_CARDS_MOVED_ZONE, INTERROGATE_THIS_TURN )
...but if you say it isn't, then maybe there's something weird in how the interrogation internally works.
If you add a SetType with a permanent type of your choice, does it correctly count the permanents of that type that go to the graveyard from the battlefield? If it does, then this should work:
A better guess (hopefully) | Open
Code: Select all
    local count = 0
    for t=CARD_TYPE_ARTIFACT,CARD_TYPE_PLANESWALKER do
       if t ~= CARD_TYPE_INSTANT then
          local interrogation = MTG():ClearInterrogationQuery()
          interrogation:SetFromZone( ZONE_BATTLEFIELD )
          interrogation:SetToZone( ZONE_GRAVEYARD )
          interrogation:SetType( t )
          count = count + interrogation:Count( INTERROGATE_CARDS_MOVED_ZONE, INTERROGATE_THIS_TURN )
       end
    end
Instant needs to be excluded because it's number 3 and we are looping from 0 to 5 (they are in alphabetical order).

Re: Report cards error here

PostPosted: 23 Sep 2013, 22:18
by GrovyleXShinyCelebi
So I playtested Bitter Ordeal, making the modification to the interrogation query as shown here:

Code: Select all
 <SPELL_ABILITY>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Déluge de cimetière]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[ Gräbersturm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Tempesta sepolcrale]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[ 墓地ストーム]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Могильный шторм]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Rajada Tumular]]></LOCALISED_TEXT>
  <TRIGGERED_ABILITY active_zone="ZONE_STACK">
    <TRIGGER value="SPELL_PLAYED" simple_qualifier="self" />
    <RESOLUTION_TIME_ACTION>
     local count = 0
    for t=CARD_TYPE_ARTIFACT,CARD_TYPE_PLANESWALKER do
       if t ~= CARD_TYPE_INSTANT then
          local interrogation = MTG():ClearInterrogationQuery()
          interrogation:SetFromZone( ZONE_BATTLEFIELD )
          interrogation:SetToZone( ZONE_GRAVEYARD )
          interrogation:SetType( t )
          count = count + interrogation:Count( INTERROGATE_CARDS_MOVED_ZONE, INTERROGATE_THIS_TURN )
          if count &gt; 0 then
            for i=0,count-1 do
             local copy = EffectController():CopySpell( EffectSourceLKI() )
             EffectController():ChooseNewTargets(copy)
           end
         end
       end
    end
    </RESOLUTION_TIME_ACTION>
  </TRIGGERED_ABILITY> 
  </SPELL_ABILITY>
I did a test where in my debug deck I sacrificed a Hidden Horror right before playing this card. This time, though, the card makes FOUR copies of the card whenever the original hits the graveyard, and then when THOSE clones hit the graveyard THOSE ones make FOUR copies of themselves...

What's going on here?

Re: Report cards error here

PostPosted: 23 Sep 2013, 23:09
by thefiremind
GrovyleXShinyCelebi wrote:This time, though, the card makes FOUR copies of the card whenever the original hits the graveyard, and then when THOSE clones hit the graveyard THOSE ones make FOUR copies of themselves...

What's going on here?
You nested the code wrong... the copies should be made outside the card type loop. You may also want to prevent the bug where the additional copies won't allow you to choose any target if the original spell leaves the stack before they are created, as I explained here. Enclosing the triggered ability inside a spell ability probably messed up things even more (I know that my web generator will put gravestorm into a SPELL_ABILITY, but that's just because I set it as the default behaviour for instants and sorceries :mrgreen:).
Code: Select all
  <TRIGGERED_ABILITY active_zone="ZONE_STACK">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Déluge de cimetière]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Gräbersturm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Tempesta sepolcrale]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[墓地ストーム]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Могильный шторм]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Rajada Tumular]]></LOCALISED_TEXT>
    <TRIGGER value="SPELL_PLAYED" simple_qualifier="self">
    EffectDC():Make_Chest(0):CopyFrom( TriggerObject():GetDataChest() )
    return true
    </TRIGGER>
    <RESOLUTION_TIME_ACTION>
    local count = 0
    for t=CARD_TYPE_ARTIFACT,CARD_TYPE_PLANESWALKER do
       if t ~= CARD_TYPE_INSTANT then
          local interrogation = MTG():ClearInterrogationQuery()
          interrogation:SetFromZone( ZONE_BATTLEFIELD )
          interrogation:SetToZone( ZONE_GRAVEYARD )
          interrogation:SetType( t )
          count = count + interrogation:Count( INTERROGATE_CARDS_MOVED_ZONE, INTERROGATE_THIS_TURN )
       end
    end
    if count &gt; 0 then
       for i=0,count-1 do
          local copy = EffectController():CopySpell( TriggerObjectLKI(), EffectDC():Get_Chest(0) )
          EffectController():ChooseNewTargets(copy)
       end
    end
    </RESOLUTION_TIME_ACTION>
  </TRIGGERED_ABILITY>
Now that I think about it, the copies that you blamed on the gravestorm ability triggering on any kind of card might actually have been created because gravestorm was inside a SPELL_ABILITY, so it was executed as a part of the spell resolution. If that's so, then the loop on card types would be useless, and my "first guess" on the previous topic would be enough.

Re: Report cards error here

PostPosted: 23 Sep 2013, 23:53
by GrovyleXShinyCelebi
thefiremind wrote:
GrovyleXShinyCelebi wrote:This time, though, the card makes FOUR copies of the card whenever the original hits the graveyard, and then when THOSE clones hit the graveyard THOSE ones make FOUR copies of themselves...

What's going on here?
You nested the code wrong... the copies should be made outside the card type loop. You may also want to prevent the bug where the additional copies won't allow you to choose any target if the original spell leaves the stack before they are created, as I explained here. Enclosing the triggered ability inside a spell ability probably messed up things even more (I know that my web generator will put gravestorm into a SPELL_ABILITY, but that's just because I set it as the default behaviour for instants and sorceries :mrgreen:).
Code: Select all
  <TRIGGERED_ABILITY active_zone="ZONE_STACK">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Déluge de cimetière]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Gräbersturm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Tempesta sepolcrale]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[墓地ストーム]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Gravestorm]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Могильный шторм]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Rajada Tumular]]></LOCALISED_TEXT>
    <TRIGGER value="SPELL_PLAYED" simple_qualifier="self">
    EffectDC():Make_Chest(0):CopyFrom( TriggerObject():GetDataChest() )
    return true
    </TRIGGER>
    <RESOLUTION_TIME_ACTION>
    local count = 0
    for t=CARD_TYPE_ARTIFACT,CARD_TYPE_PLANESWALKER do
       if t ~= CARD_TYPE_INSTANT then
          local interrogation = MTG():ClearInterrogationQuery()
          interrogation:SetFromZone( ZONE_BATTLEFIELD )
          interrogation:SetToZone( ZONE_GRAVEYARD )
          interrogation:SetType( t )
          count = count + interrogation:Count( INTERROGATE_CARDS_MOVED_ZONE, INTERROGATE_THIS_TURN )
       end
    end
    if count &gt; 0 then
       for i=0,count-1 do
          local copy = EffectController():CopySpell( TriggerObjectLKI(), EffectDC():Get_Chest(0) )
          EffectController():ChooseNewTargets(copy)
       end
    end
    </RESOLUTION_TIME_ACTION>
  </TRIGGERED_ABILITY>
Now that I think about it, the copies that you blamed on the gravestorm ability triggering on any kind of card might actually have been created because gravestorm was inside a SPELL_ABILITY, so it was executed as a part of the spell resolution. If that's so, then the loop on card types would be useless, and my "first guess" on the previous topic would be enough.
Aah! I can't believe I'd put a TRIGGERED_ABILITY block inside of a SPELL_ABILITY block and not notice it :oops:

Thanks for catching my mistake!

Re: Report cards error here

PostPosted: 24 Sep 2013, 23:32
by GrovyleXShinyCelebi
Another problem:

I've been trying to make Archangel of Strife for about an hour, and nothing seems to be working:

Code: Select all
 <TITLE>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Archangel of Strife]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Archange de la discorde]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Arcángel del conflicto]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Erzengel des Streits]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Arcangelo del Conflitto]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[敵対の大天使]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Archangel of Strife]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Archangel of Strife]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Archangel of Strife]]></LOCALISED_TEXT>
  </TITLE>
  <MULTIVERSEID value="228246" />
  <ARTID value="131682" />
  <ARTIST name="Greg Staples" />
  <CASTING_COST cost="" />
  <TYPE metaname="Creature" />
  <SUB_TYPE metaname="Angel" />
  <EXPANSION value="CMD" />
  <RARITY metaname="R" />
  <POWER value="6" />
  <TOUGHNESS value="6" />
   <TRIGGERED_ABILITY linked_ability_group="1">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Au moment où l’Archange de la discorde arrive sur le champ de bataille, chaque joueur choisit entre la guerre et la paix.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[En cuanto el Arcángel del conflicto entre al campo de batalla, cada jugador elige guerra o paz.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Sowie der Erzengel des Streits ins Spiel kommt, bestimmt jeder Spieler „Krieg” oder „Frieden”.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Mentre l’Arcangelo del Conflitto entra nel campo di battaglia, ogni giocatore sceglie guerra o pace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[敵対の大天使が戦場に出るに際し、各プレイヤーは「戦争」か「平和」のいずれかを選ぶ。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
   <TRIGGER value="ZONECHANGE_END" simple_qualifier="self" to_zone="ZONE_BATTLEFIELD" />
  <RESOLUTION_TIME_ACTION repeating="1">
  local n = MTG():GetActionRepCount()
  local jugadores = MTG():GetNumberOfPlayers()
  if (n &lt; jugadores) then
          local player = MTG():GetNthPlayer(n)
          player:BeginNewMultipleChoice()
        player:AddMultipleChoiceAnswer( "CARD_QUERY_OPTION_WAR" )
        player:AddMultipleChoiceAnswer( "CARD_QUERY_OPTION_PEACE" )
          player:AskMultipleChoiceQuestion( "CARD_QUERY_MC_CHOOSE_WAR_OR_PEACE" )
 else
     for i=0, (jugadores-1) do
   local player = MTG():GetNthPlayer(i)
        local result = player:GetMultipleChoiceResult()
        LinkedDC():Set_Int(i, result)
        LinkedDC():Set_PlayerPtr(4+i, player)
     end
  end   
  </RESOLUTION_TIME_ACTION>
  </TRIGGERED_ABILITY>
  <STATIC_ABILITY linked_ability_group="1">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les créatures contrôlées par les joueurs qui ont choisi la guerre gagnent +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Las criaturas controladas por los jugadores que eligieron guerra obtienen +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Kreaturen, die von Spielern kontrolliert werden, die „Krieg” gewählt haben, erhalten +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Le creature controllate dai giocatori che hanno scelto guerra prendono +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[「戦争」を選んだプレイヤーがコントロールするクリーチャーは+3/+0の修整を受ける。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
  <FILTER filter_id="0">
  local filter = ClearFilter()
  filter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
  </FILTER>
  <CONTINUOUS_ACTION layer="7C" filter_id="0">
  local card = FilteredCard()
  if card ~= nil then
     local n = MTG():GetNumberOfPlayers()
     for i=0, (n-1) do
        local result = LinkedDC():Get_Int(i)
        local player = LinkedDC():Get_PlayerPtr(4+i)
        if (result ~= nil) and (player ~= nil) then
             if (result == 0) and (card:GetOwner() == player ) then
               card:GetCurrentCharacteristics():Power_Add( 3 )
             card:GetCurrentCharacteristics():Toughness_Add( 0 )
                  elseif (result == 1) and (card:GetOwner() == player ) then
               card:GetCurrentCharacteristics():Power_Add( 0 )
             card:GetCurrentCharacteristics():Toughness_Add( 3 )
       end
   end
     end
  end
 </CONTINUOUS_ACTION>
  </STATIC_ABILITY>
  <STATIC_ABILITY>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les créatures contrôlées par les joueurs qui ont choisi la paix gagnent +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Las criaturas controladas por los jugadores que eligieron paz obtienen +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Kreaturen, die von Spielern kontrolliert werden, die „Frieden” gewählt haben, erhalten +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Le creature controllate dai giocatori che hanno scelto pace prendono +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[「平和」を選んだプレイヤーがコントロールするクリーチャーは+0/+3の修整を受ける。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
  </STATIC_ABILITY>
  <HELP title="MORE_INFO_BADGE_TITLE_10" body="MORE_INFO_BADGE_BODY_10" zone="ZONE_ANY" />
  <SFX text="COMBAT_ANGEL_LARGE_ATTACK" power_boundary_min="4" power_boundary_max="-1" />
  <SFX text="COMBAT_ANGEL_SMALL_ATTACK" power_boundary_min="1" power_boundary_max="3" />
After a bit of playtesting I believe I narrowed part of the problem to the player pointer, which for some reason the game is failing to recognize. I started with "LinkedDC():Set_PlayerPtr(COMPARTMENT_ID_PLR_REGISTER_0+i, player)" and "local player = LinkedDC():Get_PlayerPtr(COMPARTMENT_ID_PLR_REGISTER_0+i)", that failing to work I switched the code to what it is now (I figure there won't be more than 4-5 players in any one match) which still doesn't work...

Taking out all references to the "player" variable (including "card:GetOwner() == player") I get a card that gives all creatures +6/+0 ... regardless to how I answer the multiple choice!

Can anyone be of assistance? Huge thanks!

Re: Report cards error here

PostPosted: 24 Sep 2013, 23:51
by thefiremind
The repeating actions need a return value in order to decide if they need to be repeated (true) or not (false). The default is false, so your repeating action actually runs only once, asking the choice to the first player and doing nothing else. You need to add a "return true" before the "else".
About the static ability, why are you checking the owner of the creatures instead of the controller?
Last thing, the "As <this> enters the battlefield" triggers should be made in ZONECHANGE_TRANSITION. It's not really relevant for Archangel of Strife, but try to use ZONECHANGE_END on Sewer Nemesis and it will die before you can choose.

Re: Report cards error here

PostPosted: 25 Sep 2013, 00:04
by GrovyleXShinyCelebi
Hah! Thanks! Didn't know about the return value for the repeating actions!

Another thing, does COMPARTMENT_ID_PLR_REGISTER_0 work for Duels 2014?

Re: Report cards error here

PostPosted: 25 Sep 2013, 00:07
by thefiremind
GrovyleXShinyCelebi wrote:Another thing, does COMPARTMENT_ID_PLR_REGISTER_0 work for Duels 2014?
The constant is still defined, but that's not really important, you can use any register.

This is my attempt at coding the abilities:
Archangel of Strife abilities (untested) | Open
Code: Select all
  <TRIGGERED_ABILITY linked_ability_group="1" replacement_query="1">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Au moment où l’Archange de la discorde arrive sur le champ de bataille, chaque joueur choisit entre la guerre et la paix.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[En cuanto el Arcángel del conflicto entre al campo de batalla, cada jugador elige guerra o paz.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Sowie der Erzengel des Streits ins Spiel kommt, bestimmt jeder Spieler „Krieg” oder „Frieden”.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Mentre l’Arcangelo del Conflitto entra nel campo di battaglia, ogni giocatore sceglie guerra o pace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[敵対の大天使が戦場に出るに際し、各プレイヤーは「戦争」か「平和」のいずれかを選ぶ。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <TRIGGER value="ZONECHANGE_TRANSITION" simple_qualifier="self" to_zone="ZONE_BATTLEFIELD" />
    <RESOLUTION_TIME_ACTION repeating="1">
    local n = MTG():GetActionRepCount()
    local nPlayers = MTG():GetNumberOfPlayers()
    if n &lt; nPlayers then
       local player = MTG():GetNthPlayer(n)
       player:BeginNewMultipleChoice()
       player:AddMultipleChoiceAnswer( "CARD_QUERY_OPTION_WAR" )
       player:AddMultipleChoiceAnswer( "CARD_QUERY_OPTION_PEACE" )
       player:AskMultipleChoiceQuestion( "CARD_QUERY_MC_CHOOSE_WAR_OR_PEACE" )
       return true
    else
       for i=0,nPlayers-1 do
          LinkedDC():Set_Int( i, MTG():GetNthPlayer(i):GetMultipleChoiceResult() )
       end
    end
    return false
    </RESOLUTION_TIME_ACTION>
  </TRIGGERED_ABILITY>
  <STATIC_ABILITY linked_ability_group="1">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les créatures contrôlées par les joueurs qui ont choisi la guerre gagnent +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Las criaturas controladas por los jugadores que eligieron guerra obtienen +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Kreaturen, die von Spielern kontrolliert werden, die „Krieg” gewählt haben, erhalten +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Le creature controllate dai giocatori che hanno scelto guerra prendono +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[「戦争」を選んだプレイヤーがコントロールするクリーチャーは+3/+0の修整を受ける。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <FILTER filter_id="0">
    local filter = ClearFilter()
    filter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
    filter:Add( FE_LUA_CONDITION, 1, EffectController(), EffectDC() )
    </FILTER>
    <FILTER_CONDITION id="1">
    local creature = FilteredCard()
    if creature ~= nil then
       local player = creature:GetController()
       for i=0,MTG():GetNumberOfPlayers()-1 do
          if player == MTG():GetNthPlayer(i) and LinkedDC():Get_Int(i) == 0 then
             return true
          end
       end
    end
    return false
    </FILTER_CONDITION>
    <CONTINUOUS_ACTION layer="7C" filter_id="0">
    if FilteredCard() ~= nil then
       FilteredCard():GetCurrentCharacteristics():Power_Add(3)
    end
    </CONTINUOUS_ACTION>
  </STATIC_ABILITY>
  <STATIC_ABILITY>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les créatures contrôlées par les joueurs qui ont choisi la paix gagnent +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Las criaturas controladas por los jugadores que eligieron paz obtienen +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Kreaturen, die von Spielern kontrolliert werden, die „Frieden” gewählt haben, erhalten +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Le creature controllate dai giocatori che hanno scelto pace prendono +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[「平和」を選んだプレイヤーがコントロールするクリーチャーは+0/+3の修整を受ける。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <FILTER filter_id="0">
    local filter = ClearFilter()
    filter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
    filter:Add( FE_LUA_CONDITION, 1, EffectController(), EffectDC() )
    </FILTER>
    <FILTER_CONDITION id="1">
    local creature = FilteredCard()
    if creature ~= nil then
       local player = creature:GetController()
       for i=0,MTG():GetNumberOfPlayers()-1 do
          if player == MTG():GetNthPlayer(i) and LinkedDC():Get_Int(i) == 1 then
             return true
          end
       end
    end
    return false
    </FILTER_CONDITION>
    <CONTINUOUS_ACTION layer="7C" filter_id="0">
    if FilteredCard() ~= nil then
       FilteredCard():GetCurrentCharacteristics():Toughness_Add(3)
    end
    </CONTINUOUS_ACTION>
  </STATIC_ABILITY>

Re: Report cards error here

PostPosted: 25 Sep 2013, 01:07
by GrovyleXShinyCelebi
Something I don't get about ( FE_LUA_CONDITION, 1, EffectController(), EffectDC() ), why must you put "EffectController()" and "EffectDC()"? I believe the "1" means "if this condition return true", but what's up with the last 2 values?

Originally, I took Archangel of Strife as an opportunity to practice making a loop with "local parity = n % 2", but after it never working after a half hour of testing I decided to scrap that method and just pull off the code with the tried-and-true, copying-and-pasting from Fleshbag Marauder. Does that method get the same result as this one? Is it rendered obselete with repeating RESOLUTION_TIME_ACTION blocks?

Apologies for the barrage of n00b questions, I'm trying to learn some things from making this card.

Re: Report cards error here

PostPosted: 25 Sep 2013, 08:42
by thefiremind
GrovyleXShinyCelebi wrote:Something I don't get about ( FE_LUA_CONDITION, 1, EffectController(), EffectDC() ), why must you put "EffectController()" and "EffectDC()"? I believe the "1" means "if this condition return true", but what's up with the last 2 values?
"1" means that you are referring to FILTER_CONDITION with id="1". I don't know why we need to specify EffectController() and EffectDC(), either... but official cards do that and it seems to work, so I don't bother. :lol:

GrovyleXShinyCelebi wrote:Originally, I took Archangel of Strife as an opportunity to practice making a loop with "local parity = n % 2", but after it never working after a half hour of testing I decided to scrap that method and just pull off the code with the tried-and-true, copying-and-pasting from Fleshbag Marauder. Does that method get the same result as this one? Is it rendered obselete with repeating RESOLUTION_TIME_ACTION blocks?
When you use parity you are using repeating actions anyway: the parity check is needed when you want to do something on even iterations and something different on odd iterations. If you use parity, you usually apply the effect of the latest choice before going on asking to the other players. I don't think this would have any impact on Archangel of Strife. DotP is usually loose on this kind of problems even on official cards. If you read the rules, you'll notice that when a choice must be performed by all players, the first to choose should be the active player, but this is totally ignored on DotP (unless they dynamically shift the active player to MTG():GetNthPlayer(0), which I never paid attention to, but something tells me they don't).

Re: Report cards error here

PostPosted: 25 Sep 2013, 23:45
by GrovyleXShinyCelebi
thefiremind wrote:
GrovyleXShinyCelebi wrote:Another thing, does COMPARTMENT_ID_PLR_REGISTER_0 work for Duels 2014?
The constant is still defined, but that's not really important, you can use any register.

This is my attempt at coding the abilities:
Archangel of Strife abilities (untested) | Open
Code: Select all
  <TRIGGERED_ABILITY linked_ability_group="1" replacement_query="1">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Au moment où l’Archange de la discorde arrive sur le champ de bataille, chaque joueur choisit entre la guerre et la paix.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[En cuanto el Arcángel del conflicto entre al campo de batalla, cada jugador elige guerra o paz.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Sowie der Erzengel des Streits ins Spiel kommt, bestimmt jeder Spieler „Krieg” oder „Frieden”.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Mentre l’Arcangelo del Conflitto entra nel campo di battaglia, ogni giocatore sceglie guerra o pace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[敵対の大天使が戦場に出るに際し、各プレイヤーは「戦争」か「平和」のいずれかを選ぶ。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <TRIGGER value="ZONECHANGE_TRANSITION" simple_qualifier="self" to_zone="ZONE_BATTLEFIELD" />
    <RESOLUTION_TIME_ACTION repeating="1">
    local n = MTG():GetActionRepCount()
    local nPlayers = MTG():GetNumberOfPlayers()
    if n &lt; nPlayers then
       local player = MTG():GetNthPlayer(n)
       player:BeginNewMultipleChoice()
       player:AddMultipleChoiceAnswer( "CARD_QUERY_OPTION_WAR" )
       player:AddMultipleChoiceAnswer( "CARD_QUERY_OPTION_PEACE" )
       player:AskMultipleChoiceQuestion( "CARD_QUERY_MC_CHOOSE_WAR_OR_PEACE" )
       return true
    else
       for i=0,nPlayers-1 do
          LinkedDC():Set_Int( i, MTG():GetNthPlayer(i):GetMultipleChoiceResult() )
       end
    end
    return false
    </RESOLUTION_TIME_ACTION>
  </TRIGGERED_ABILITY>
  <STATIC_ABILITY linked_ability_group="1">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les créatures contrôlées par les joueurs qui ont choisi la guerre gagnent +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Las criaturas controladas por los jugadores que eligieron guerra obtienen +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Kreaturen, die von Spielern kontrolliert werden, die „Krieg” gewählt haben, erhalten +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Le creature controllate dai giocatori che hanno scelto guerra prendono +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[「戦争」を選んだプレイヤーがコントロールするクリーチャーは+3/+0の修整を受ける。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <FILTER filter_id="0">
    local filter = ClearFilter()
    filter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
    filter:Add( FE_LUA_CONDITION, 1, EffectController(), EffectDC() )
    </FILTER>
    <FILTER_CONDITION id="1">
    local creature = FilteredCard()
    if creature ~= nil then
       local player = creature:GetController()
       for i=0,MTG():GetNumberOfPlayers()-1 do
          if player == MTG():GetNthPlayer(i) and LinkedDC():Get_Int(i) == 0 then
             return true
          end
       end
    end
    return false
    </FILTER_CONDITION>
    <CONTINUOUS_ACTION layer="7C" filter_id="0">
    if FilteredCard() ~= nil then
       FilteredCard():GetCurrentCharacteristics():Power_Add(3)
    end
    </CONTINUOUS_ACTION>
  </STATIC_ABILITY>
  <STATIC_ABILITY>
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les créatures contrôlées par les joueurs qui ont choisi la paix gagnent +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Las criaturas controladas por los jugadores que eligieron paz obtienen +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Kreaturen, die von Spielern kontrolliert werden, die „Frieden” gewählt haben, erhalten +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Le creature controllate dai giocatori che hanno scelto pace prendono +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[「平和」を選んだプレイヤーがコントロールするクリーチャーは+0/+3の修整を受ける。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <FILTER filter_id="0">
    local filter = ClearFilter()
    filter:Add( FE_TYPE, OP_IS, CARD_TYPE_CREATURE )
    filter:Add( FE_LUA_CONDITION, 1, EffectController(), EffectDC() )
    </FILTER>
    <FILTER_CONDITION id="1">
    local creature = FilteredCard()
    if creature ~= nil then
       local player = creature:GetController()
       for i=0,MTG():GetNumberOfPlayers()-1 do
          if player == MTG():GetNthPlayer(i) and LinkedDC():Get_Int(i) == 1 then
             return true
          end
       end
    end
    return false
    </FILTER_CONDITION>
    <CONTINUOUS_ACTION layer="7C" filter_id="0">
    if FilteredCard() ~= nil then
       FilteredCard():GetCurrentCharacteristics():Toughness_Add(3)
    end
    </CONTINUOUS_ACTION>
  </STATIC_ABILITY>
So, I was testing out my Archangel of Strife and so far everything works except for one little thing: no matter if I select "War" or "Peace", the card just gives everything +3/+0 anyways! I tried out your code (you forgot an active_zone="ZONE_TRANSITION" tag, by the way :x ) but the problem is still there! I've tried everything I could for about another half hour, but nothing seems to be working! What could be going on? Has the result been mispointed so LinkedDC():Get_Int(i) will always return 0 regardless of what happens?

Re: Report cards error here

PostPosted: 26 Sep 2013, 08:44
by thefiremind
GrovyleXShinyCelebi wrote:So, I was testing out my Archangel of Strife and so far everything works except for one little thing: no matter if I select "War" or "Peace", the card just gives everything +3/+0 anyways! I tried out your code (you forgot an active_zone="ZONE_TRANSITION" tag, by the way :x ) but the problem is still there! I've tried everything I could for about another half hour, but nothing seems to be working! What could be going on? Has the result been mispointed so LinkedDC():Get_Int(i) will always return 0 regardless of what happens?
In case someone already read what I wrote here before, well, forget it: the problem wasn't LinkedDC that gets wiped, but the repeating loop. In fact, even though GetMultipleChoiceResult now is called from the player, it seems that it can't be saved on a player basis. This means that the parity is needed. I tested the following code and it works.
Archangel of Strife abilities (2nd attempt) (tested) | Open
Code: Select all
  <TRIGGERED_ABILITY linked_ability_group="1" replacement_query="1" active_zone="ZONE_TRANSITION">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Au moment où l’Archange de la discorde arrive sur le champ de bataille, chaque joueur choisit entre la guerre et la paix.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[En cuanto el Arcángel del conflicto entre al campo de batalla, cada jugador elige guerra o paz.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Sowie der Erzengel des Streits ins Spiel kommt, bestimmt jeder Spieler „Krieg” oder „Frieden”.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Mentre l’Arcangelo del Conflitto entra nel campo di battaglia, ogni giocatore sceglie guerra o pace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[敵対の大天使が戦場に出るに際し、各プレイヤーは「戦争」か「平和」のいずれかを選ぶ。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[As Archangel of Strife enters the battlefield, each player chooses war or peace.]]></LOCALISED_TEXT>
    <TRIGGER value="ZONECHANGE_TRANSITION" simple_qualifier="self" to_zone="ZONE_BATTLEFIELD" />
    <RESOLUTION_TIME_ACTION repeating="1">
    local n = MTG():GetActionRepCount()
    local parity = n%2
    local index = n/2
    if index &lt; MTG():GetNumberOfStartingPlayers() then
       local player = MTG():GetNthStartingPlayer(index)
       if player ~= nil then
          if parity == 0 then
             player:BeginNewMultipleChoice()
             player:AddMultipleChoiceAnswer("CARD_QUERY_OPTION_WAR")
             player:AddMultipleChoiceAnswer("CARD_QUERY_OPTION_PEACE")
             player:AskMultipleChoiceQuestion( "CARD_QUERY_MC_CHOOSE_WAR_OR_PEACE", EffectSource() )
          else
             LinkedDC():Set_Int( index, player:GetMultipleChoiceResult()+1 )
          end
       end
       return true
    end
    return false
    </RESOLUTION_TIME_ACTION>
  </TRIGGERED_ABILITY>
  <STATIC_ABILITY linked_ability_group="1">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les créatures contrôlées par les joueurs qui ont choisi la guerre gagnent +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Las criaturas controladas por los jugadores que eligieron guerra obtienen +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Kreaturen, die von Spielern kontrolliert werden, die „Krieg” gewählt haben, erhalten +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Le creature controllate dai giocatori che hanno scelto guerra prendono +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[「戦争」を選んだプレイヤーがコントロールするクリーチャーは+3/+0の修整を受ける。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Creatures controlled by players who chose war get +3/+0.]]></LOCALISED_TEXT>
    <FILTER filter_id="1">
    local filter = ClearFilter()
    filter:Add(FE_TYPE, OP_IS, CARD_TYPE_CREATURE)
    filter:Add( FE_LUA_CONDITION, 1, EffectController(), EffectDC() )
    </FILTER>
    <FILTER_CONDITION id="1">
    local creature = FilteredCard()
    if creature ~= nil then
       local player = creature:GetController()
       for i=0,MTG():GetNumberOfStartingPlayers()-1 do
          if player == MTG():GetNthStartingPlayer(i) and LinkedDC():Get_Int(i) == 1 then
             return true
          end
       end
    end
    return false
    </FILTER_CONDITION>
    <CONTINUOUS_ACTION layer="7C" filter_id="1">
    if FilteredCard() ~= nil then
       FilteredCard():GetCurrentCharacteristics():Power_Add(3)
    end
    </CONTINUOUS_ACTION>
  </STATIC_ABILITY>
  <STATIC_ABILITY linked_ability_group="1">
    <LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[Les créatures contrôlées par les joueurs qui ont choisi la paix gagnent +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[Las criaturas controladas por los jugadores que eligieron paz obtienen +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[Kreaturen, die von Spielern kontrolliert werden, die „Frieden” gewählt haben, erhalten +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[Le creature controllate dai giocatori che hanno scelto pace prendono +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[「平和」を選んだプレイヤーがコントロールするクリーチャーは+0/+3の修整を受ける。]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ko-KR"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="ru-RU"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <LOCALISED_TEXT LanguageCode="pt-BR"><![CDATA[Creatures controlled by players who chose peace get +0/+3.]]></LOCALISED_TEXT>
    <FILTER filter_id="2">
    local filter = ClearFilter()
    filter:Add(FE_TYPE, OP_IS, CARD_TYPE_CREATURE)
    filter:Add( FE_LUA_CONDITION, 2, EffectController(), EffectDC() )
    </FILTER>
    <FILTER_CONDITION id="2">
    local creature = FilteredCard()
    if creature ~= nil then
       local player = creature:GetController()
       for i=0,MTG():GetNumberOfStartingPlayers()-1 do
          if player == MTG():GetNthStartingPlayer(i) and LinkedDC():Get_Int(i) == 2 then
             return true
          end
       end
    end
    return false
    </FILTER_CONDITION>
    <CONTINUOUS_ACTION layer="7C" filter_id="2">
    if FilteredCard() ~= nil then
       FilteredCard():GetCurrentCharacteristics():Toughness_Add(3)
    end
    </CONTINUOUS_ACTION>
  </STATIC_ABILITY>
I also noticed that in a FFA match with more than 2 players we need to keep the player association through the starting players list, otherwise what happens is that if player #2 loses, player #3 will shift up 1 place in the (non-starting) players list and his creatures will be affected by the choice made by player #2.