Board index
Programs with AI or Rules Enforcement
Magic: The Gathering - Duels of the Planeswalkers
Programming Talk



Need help programming a card
Moderator: CCGHQ Admins
Re: Need help programming a card
by sadlyblue » 18 Mar 2012, 23:14
For myr superion may i sugest a trick like automated automaton.
Since you know which creatures will produce mana, the requisites for playing it would be to have 2 of them in play, with no summoning sickness, and untapped.
When you play the card, it will tap them. I don't see any other way.
But its a lot of work.
Since you know which creatures will produce mana, the requisites for playing it would be to have 2 of them in play, with no summoning sickness, and untapped.
When you play the card, it will tap them. I don't see any other way.
But its a lot of work.
Re: Need help programming a card
by marcus00005 » 19 Mar 2012, 05:12
yeah i can see how that will work sadlyblue but i am not that good at it yet still in beginners area for programming on magic cards.
- marcus00005
- Posts: 14
- Joined: 12 Jan 2012, 02:13
- Has thanked: 0 time
- Been thanked: 0 time
Re: Need help programming a card
by marcus00005 » 22 Mar 2012, 16:37
hello again need a little help with a few cards. i was doing myr propagator i got his ability to work but had a problem with figure just how make him copy himself. i tap him and i can copy himself and the other creature if choose to copy. i went with kiki-jiki copy ability. also is there a code i can tweak for the imprint ability for semblance anvil and myr welder or best coding to choose to do them.
here is what i have for myr propagator
<ACTIVATED_ABILITY>
<LOCALISED_TEXT LanguageCode="en-US"><![CDATA[{T}: Put a token that's a copy of target nonlegendary creature you control onto the battlefield. That token has haste. Sacrifice it at the beginning of the next end step.]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[]]></LOCALISED_TEXT>
<COST type="TapSelf" />
<TARGET_DETERMINATION>
local filter = Object():GetFilter()
filter:Clear()
filter:AddCardType( CARD_TYPE_CREATURE )
filter:SetZone( ZONE_IN_PLAY )
return TargetBadF()
</TARGET_DETERMINATION>
<PLAY_TIME_ACTION target_choosing="SELF">
ChooseTarget( "CARD_QUERY_CHOOSE_CREATURE_TO_COPY" )
</PLAY_TIME_ACTION>
<RESOLUTION_TIME_ACTION>
local targetCard = Object():GetTargetCard()
local player = Object():GetController()
local mystore = Storage(Object())
if targetCard ~= nil then
local token = MTG():ObtainTokenFromSpec( targetCard:GetSpec(), Object():GetPlayer() )
mystore.push(token)
token:PutIntoPlay(Object():GetPlayer())
end
</RESOLUTION_TIME_ACTION>
<AI_AVAILABILITY behaviour="InResponseOrDuringCombatOrBeforeMyUntap" />
<AI_BASE_SCORE score="600" zone="in_play" />
</ACTIVATED_ABILITY>
</CARD_V2>
once i have those cards my myr deck is all finish thanks to help of the "thefiremind" and "eglin" thanks for the help.
here is what i have for myr propagator
<ACTIVATED_ABILITY>
<LOCALISED_TEXT LanguageCode="en-US"><![CDATA[{T}: Put a token that's a copy of target nonlegendary creature you control onto the battlefield. That token has haste. Sacrifice it at the beginning of the next end step.]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[]]></LOCALISED_TEXT>
<COST type="TapSelf" />
<TARGET_DETERMINATION>
local filter = Object():GetFilter()
filter:Clear()
filter:AddCardType( CARD_TYPE_CREATURE )
filter:SetZone( ZONE_IN_PLAY )
return TargetBadF()
</TARGET_DETERMINATION>
<PLAY_TIME_ACTION target_choosing="SELF">
ChooseTarget( "CARD_QUERY_CHOOSE_CREATURE_TO_COPY" )
</PLAY_TIME_ACTION>
<RESOLUTION_TIME_ACTION>
local targetCard = Object():GetTargetCard()
local player = Object():GetController()
local mystore = Storage(Object())
if targetCard ~= nil then
local token = MTG():ObtainTokenFromSpec( targetCard:GetSpec(), Object():GetPlayer() )
mystore.push(token)
token:PutIntoPlay(Object():GetPlayer())
end
</RESOLUTION_TIME_ACTION>
<AI_AVAILABILITY behaviour="InResponseOrDuringCombatOrBeforeMyUntap" />
<AI_BASE_SCORE score="600" zone="in_play" />
</ACTIVATED_ABILITY>
</CARD_V2>
once i have those cards my myr deck is all finish thanks to help of the "thefiremind" and "eglin" thanks for the help.
- marcus00005
- Posts: 14
- Joined: 12 Jan 2012, 02:13
- Has thanked: 0 time
- Been thanked: 0 time
Re: Need help programming a card
by thefiremind » 22 Mar 2012, 17:43
Myr Propagator is easy because it doesn't need any target, it just makes a token out of itself. Here is my version:
- Code: Select all
<?xml version='1.0'?>
<CARD_V2 custom="true">
<FILENAME text="MYR_PROPAGATOR_19991521" />
<CARDNAME text="MYR_PROPAGATOR" />
<TITLE>
<LOCALISED_TEXT LanguageCode="en-US"><![CDATA[Myr Propagator]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[]]></LOCALISED_TEXT>
</TITLE>
<MULTIVERSEID value="19991521" />
<ARTID value="19991521" />
<FRAMECOLOUR name="A" />
<COLOUR value="A" />
<ARTIST name="Ryan Pancoast" />
<CASTING_COST cost="{3}" />
<FLAVOURTEXT>
<LOCALISED_TEXT LanguageCode="en-US"><![CDATA[“We will ingest and remake this world in our image, not unlike some admirable designs I have seen here.”
—Vorinclex, Voice of Hunger]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[]]></LOCALISED_TEXT>
</FLAVOURTEXT>
<TYPE metaname="Artifact" order_de-DE="0" order_es-ES="1" order_fr-FR="1" order_it-IT="1" order_jp-JA="0" />
<TYPE metaname="Creature" order_de-DE="1" order_es-ES="0" order_fr-FR="0" order_it-IT="0" order_jp-JA="0" />
<SUB_TYPE metaname="Myr" order_de-DE="0" order_es-ES="0" order_fr-FR="0" order_it-IT="0" order_jp-JA="0" />
<EXPANSION value="SOM" />
<RARITY metaname="R" />
<POWER value="1" />
<TOUGHNESS value="1" />
<ACTIVATED_ABILITY>
<LOCALISED_TEXT LanguageCode="en-US"><![CDATA[{3}, {T}: Put a token that’s a copy of Myr Propagator onto the battlefield.]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="de-DE"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="es-ES"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="fr-FR"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="it-IT"><![CDATA[]]></LOCALISED_TEXT>
<LOCALISED_TEXT LanguageCode="jp-JA"><![CDATA[]]></LOCALISED_TEXT>
<COST type="TapSelf" />
<COST type="Mana" cost="{3}" />
<RESOLUTION_TIME_ACTION>
local token = MTG():ObtainTokenFromSpec( Object():GetSpec(), Object():GetPlayer() )
if token ~= nil then
token:PutIntoPlay( Object():GetPlayer() )
end
</RESOLUTION_TIME_ACTION>
<AI_AVAILABILITY behaviour="InResponseOrDuringCombatOrBeforeMyUntap" />
<AI_BASE_SCORE score="600" zone="in_play" />
</ACTIVATED_ABILITY>
<SFX text="COMBAT_BLUNT_LARGE_ATTACK" power_boundary_min="4" power_boundary_max="-1" />
<SFX text="COMBAT_BLUNT_SMALL_ATTACK" power_boundary_min="1" power_boundary_max="3" />
</CARD_V2>
< Former DotP 2012/2013/2014 modder >
Currently busy with life...
Currently busy with life...
-
thefiremind - Programmer
- Posts: 3515
- Joined: 07 Nov 2011, 10:55
- Has thanked: 118 times
- Been thanked: 722 times
19 posts
• Page 2 of 2 • 1, 2
Who is online
Users browsing this forum: No registered users and 2 guests