Board index
Programs with AI or Rules Enforcement
Magic: The Gathering - Duels of the Planeswalkers
New MTG Cards and Decks (2010, 2012, 2013, 2014, 2015, Magic Duels)



Card Creation Request Thread
User-made mods in DLC (Downloadable Content) form.
Get MTG cards here for your DotP that aren't available anywhere else!
Get MTG cards here for your DotP that aren't available anywhere else!
Moderator: CCGHQ Admins
Re: Card Creation Request Thread
by NEMESiS » 19 Jun 2013, 01:18
Very simple question, when I want to draw 2 cards when I kick a spell how does it have to be made?
- Code: Select all
<RESOLUTION_TIME_ACTION>
local kicker = Object():Kicked()
if kicker ~= 0 then
EffectController():DrawCard()
end
</RESOLUTION_TIME_ACTION>
-
NEMESiS - Posts: 460
- Joined: 03 Jan 2013, 04:02
- Location: Pools of Becoming
- Has thanked: 70 times
- Been thanked: 21 times
Re: Card Creation Request Thread
by RiiakShiNal » 19 Jun 2013, 01:29
If you just want to draw 2 cards when kicked then just double the calls to DrawCard():
- Code: Select all
<RESOLUTION_TIME_ACTION>
local kicker = Object():Kicked()
if kicker ~= 0 then
EffectController():DrawCard()
EffectController():DrawCard()
end
</RESOLUTION_TIME_ACTION>
- Code: Select all
<RESOLUTION_TIME_ACTION>
local kicker = Object():Kicked()
if kicker ~= 0 then
PlayerDrawCards( EffectController(), 2 )
end
</RESOLUTION_TIME_ACTION>
Just getting started: Xander9009's DotP 2014 Community Wad
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
- RiiakShiNal
- Programmer
- Posts: 2188
- Joined: 16 May 2011, 21:37
- Has thanked: 75 times
- Been thanked: 497 times
Re: Card Creation Request Thread
by gorem2k » 19 Jun 2013, 01:46
Almost! it doesn't remove any counter after damage. and if I activate 3 more times after that, there's no damage.RiiakShiNal wrote:Try this:Edit: Forgot to add the triggered ability to reset the count, now added.
- Code: Select all
<ACTIVATED_ABILITY auto_skip="1">
<LOCALISED_TEXT LanguageCode="en-US"><![CDATA[{1}{R}: Put a +1/+1 counter on Ashling the Pilgrim. If this is the third time this ability has resolved this turn, remove all +1/+1 counters from Ashling the Pilgrim, and it deals that much damage to each creature and each player.]]></LOCALISED_TEXT>
<COST type="Mana" cost="{1}{R}" />
<RESOLUTION_TIME_ACTION>
if EffectSource() ~= nil then
EffectSource():AddCounters( MTG():PlusOnePlusOneCounters(), 1 )
end
ObjectDC():Int_Inc(0)
</RESOLUTION_TIME_ACTION>
<RESOLUTION_TIME_ACTION>
if (ObjectDC():Int_Get(0) == 3) then
local num_counters = EffectSource():CountCounters( MTG():PlusOnePlusOneCounters() )
if (num_counters > 0) then
-- Deal damage to players
for i=0,MTG():GetNumberOfPlayers()-1 do
MTG():GetNthPlayer(i):DealDamage( num_counters, EffectSource() )
end
-- Deal damage to creatures
local oFilter = Object():GetFilter()
oFilter:Clear()
oFilter:AddCardType( CARD_TYPE_CREATURE )
oFilter:SetZone( ZONE_IN_PLAY )
local nCount = oFilter:EvaluateObjects()
if (nCount > 0) then
for i=0,nCount-1 do
local oCard = oFilter:GetNthEvaluatedObject(i)
if (oCard ~= nil) then
oCard:DealDamage( num_counters, EffectSource() )
end
end
end
end
end
</RESOLUTION_TIME_ACTION>
</ACTIVATED_ABILITY>
<TRIGGERED_ABILITY internal="1" active_zone="ZONE_ANY">
<TRIGGER value="TRIGGER_END_OF_TURN" />
<RESOLUTION_TIME_ACTION>
ObjectDC():Int_Set( 0, 0 )
</RESOLUTION_TIME_ACTION>
</TRIGGERED_ABILITY>
Re: Card Creation Request Thread
by NEMESiS » 19 Jun 2013, 02:04
@Sumomole, for some reason Survival Cache does not rebound. I even copied and pasted it from Distortion Strike and no luck.
-
NEMESiS - Posts: 460
- Joined: 03 Jan 2013, 04:02
- Location: Pools of Becoming
- Has thanked: 70 times
- Been thanked: 21 times
Re: Card Creation Request Thread
by RiiakShiNal » 19 Jun 2013, 02:25
Ahh, forgot about that, I really should stop coding when I'm tired.gorem2k wrote:Almost! it doesn't remove any counter after damage. and if I activate 3 more times after that, there's no damage.
- Code: Select all
<ACTIVATED_ABILITY auto_skip="1">
<LOCALISED_TEXT LanguageCode="en-US"><![CDATA[{1}{R}: Put a +1/+1 counter on Ashling the Pilgrim. If this is the third time this ability has resolved this turn, remove all +1/+1 counters from Ashling the Pilgrim, and it deals that much damage to each creature and each player.]]></LOCALISED_TEXT>
<COST type="Mana" cost="{1}{R}" />
<RESOLUTION_TIME_ACTION>
if EffectSource() ~= nil then
EffectSource():AddCounters( MTG():PlusOnePlusOneCounters(), 1 )
end
ObjectDC():Int_Inc(0)
</RESOLUTION_TIME_ACTION>
<RESOLUTION_TIME_ACTION>
if (ObjectDC():Int_Get(0) == 3) then
local num_counters = EffectSource():CountCounters( MTG():PlusOnePlusOneCounters() )
if (num_counters > 0) then
EffectSource():RemoveCounters( MTG():PlusOnePlusOneCounters(), num_counters )
-- Deal damage to players
for i=0,MTG():GetNumberOfPlayers()-1 do
MTG():GetNthPlayer(i):DealDamage( num_counters, EffectSource() )
end
-- Deal damage to creatures
local oFilter = Object():GetFilter()
oFilter:Clear()
oFilter:AddCardType( CARD_TYPE_CREATURE )
oFilter:SetZone( ZONE_IN_PLAY )
local nCount = oFilter:EvaluateObjects()
if (nCount > 0) then
for i=0,nCount-1 do
local oCard = oFilter:GetNthEvaluatedObject(i)
if (oCard ~= nil) then
oCard:DealDamage( num_counters, EffectSource() )
end
end
end
end
end
</RESOLUTION_TIME_ACTION>
</ACTIVATED_ABILITY>
<TRIGGERED_ABILITY internal="1" active_zone="ZONE_ANY">
<TRIGGER value="TRIGGER_END_OF_TURN" />
<RESOLUTION_TIME_ACTION>
ObjectDC():Int_Set( 0, 0 )
</RESOLUTION_TIME_ACTION>
</TRIGGERED_ABILITY>
Just getting started: Xander9009's DotP 2014 Community Wad
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
- RiiakShiNal
- Programmer
- Posts: 2188
- Joined: 16 May 2011, 21:37
- Has thanked: 75 times
- Been thanked: 497 times
Re: Card Creation Request Thread
by gorem2k » 19 Jun 2013, 02:49
Better! but I suggest you take a good rest. before reading furtherRiiakShiNal wrote:Ahh, forgot about that, I really should stop coding when I'm tired.gorem2k wrote:Almost! it doesn't remove any counter after damage. and if I activate 3 more times after that, there's no damage.
- Code: Select all
<ACTIVATED_ABILITY auto_skip="1">
<LOCALISED_TEXT LanguageCode="en-US"><![CDATA[{1}{R}: Put a +1/+1 counter on Ashling the Pilgrim. If this is the third time this ability has resolved this turn, remove all +1/+1 counters from Ashling the Pilgrim, and it deals that much damage to each creature and each player.]]></LOCALISED_TEXT>
<COST type="Mana" cost="{1}{R}" />
<RESOLUTION_TIME_ACTION>
if EffectSource() ~= nil then
EffectSource():AddCounters( MTG():PlusOnePlusOneCounters(), 1 )
end
ObjectDC():Int_Inc(0)
</RESOLUTION_TIME_ACTION>
<RESOLUTION_TIME_ACTION>
if (ObjectDC():Int_Get(0) == 3) then
local num_counters = EffectSource():CountCounters( MTG():PlusOnePlusOneCounters() )
if (num_counters > 0) then
EffectSource():RemoveCounters( MTG():PlusOnePlusOneCounters(), num_counters )
-- Deal damage to players
for i=0,MTG():GetNumberOfPlayers()-1 do
MTG():GetNthPlayer(i):DealDamage( num_counters, EffectSource() )
end
-- Deal damage to creatures
local oFilter = Object():GetFilter()
oFilter:Clear()
oFilter:AddCardType( CARD_TYPE_CREATURE )
oFilter:SetZone( ZONE_IN_PLAY )
local nCount = oFilter:EvaluateObjects()
if (nCount > 0) then
for i=0,nCount-1 do
local oCard = oFilter:GetNthEvaluatedObject(i)
if (oCard ~= nil) then
oCard:DealDamage( num_counters, EffectSource() )
end
end
end
end
ObjectDC():Int_Set( 0, 0 )
end
</RESOLUTION_TIME_ACTION>
</ACTIVATED_ABILITY>
<TRIGGERED_ABILITY internal="1" active_zone="ZONE_ANY">
<TRIGGER value="TRIGGER_END_OF_TURN" />
<RESOLUTION_TIME_ACTION>
ObjectDC():Int_Set( 0, 0 )
</RESOLUTION_TIME_ACTION>
</TRIGGERED_ABILITY>

it only triggers when there are 3 counters on it, so I can't put 2 counters then another 2 on next turn. it will reset at 3 everytime. sorry about that...
Re: Card Creation Request Thread
by RiiakShiNal » 19 Jun 2013, 02:52
Actually, it does not trigger when there are 3 counters it triggers "If this is the third time this ability has resolved this turn", so yes you can add 2 counters one turn then 2 more the next turn, and so on.gorem2k wrote:Better! but I suggest you take a good rest. before reading further![]()
it only triggers when there are 3 counters on it, so I can't put 2 counters then another 2 on next turn. sorry about that...
Maybe we both need some rest.
Edit: Nevermind, I misread what you meant there. I have an error in my internal TRIGGERED_ABILITY:
The TRIGGER should be:
- Code: Select all
<TRIGGER value="END_OF_TURN" />

Just getting started: Xander9009's DotP 2014 Community Wad
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
Need a deck builder: DotP 2014 Deck Builder
Problems Modding: DotP 2014 Frequent Modding Mistakes
- RiiakShiNal
- Programmer
- Posts: 2188
- Joined: 16 May 2011, 21:37
- Has thanked: 75 times
- Been thanked: 497 times
Re: Card Creation Request Thread
by sumomole » 19 Jun 2013, 07:46
Rebound effect has two parts, the 1st part is in spell to exile itself, and the 2nd part is a trigger ability to play itself from exile. do you have copied and pasted both?NEMESiS wrote:@Sumomole, for some reason Survival Cache does not rebound. I even copied and pasted it from Distortion Strike and no luck.
-
sumomole - Programmer
- Posts: 611
- Joined: 07 Jun 2011, 08:34
- Has thanked: 51 times
- Been thanked: 234 times
Re: Card Creation Request Thread
by castled » 19 Jun 2013, 08:37
I wanna have some cards below 

special rule: If you have no card but the card you take from this effect, you can choose not to discard this one.









- castled
- Posts: 84
- Joined: 09 Oct 2010, 14:50
- Location: Shenzhen,China
- Has thanked: 16 times
- Been thanked: 1 time
Re: Card Creation Request Thread
by NEMESiS » 19 Jun 2013, 10:49
Apparently I had missed part of that.sumomole wrote:Rebound effect has two parts, the 1st part is in spell to exile itself, and the 2nd part is a trigger ability to play itself from exile. do you have copied and pasted both?NEMESiS wrote:@Sumomole, for some reason Survival Cache does not rebound. I even copied and pasted it from Distortion Strike and no luck.

Sorry to bother you.
-
NEMESiS - Posts: 460
- Joined: 03 Jan 2013, 04:02
- Location: Pools of Becoming
- Has thanked: 70 times
- Been thanked: 21 times
Re: Card Creation Request Thread
by sumomole » 19 Jun 2013, 12:36
You can find Doomsday & Gamble in my mod.castled wrote:I wanna have some cards below
If you want to use Omnath, Locus of Mana, you need my mana token and mana fuction, since D13 is no mana pool, also, all mana source must can be manually tapped, for example, I have coded a FOREST_624993 that can be manually tapped, and more need to code your own.

- Attachments
-
cards.zip
- Windfall & Molten Psyche & Omnath, Locus of Mana
- (555.9 KiB) Downloaded 334 times
-
sumomole - Programmer
- Posts: 611
- Joined: 07 Jun 2011, 08:34
- Has thanked: 51 times
- Been thanked: 234 times
Re: Card Creation Request Thread
by gorem2k » 19 Jun 2013, 19:24
plays fine. disregard
Last edited by gorem2k on 20 Jun 2013, 19:45, edited 1 time in total.
Re: Card Creation Request Thread
by NEMESiS » 20 Jun 2013, 02:52
Does anyone have Skeletal Scrying? Also, if someone can give me the graveyard ability for Undead Gladiator would be greatly appreciated.
-
NEMESiS - Posts: 460
- Joined: 03 Jan 2013, 04:02
- Location: Pools of Becoming
- Has thanked: 70 times
- Been thanked: 21 times
Re: Card Creation Request Thread
by sumomole » 20 Jun 2013, 12:50
HereNEMESiS wrote:Does anyone have Skeletal Scrying? Also, if someone can give me the graveyard ability for Undead Gladiator would be greatly appreciated.
-
sumomole - Programmer
- Posts: 611
- Joined: 07 Jun 2011, 08:34
- Has thanked: 51 times
- Been thanked: 234 times
Re: Card Creation Request Thread
by castled » 21 Jun 2013, 13:33
thx you very very very much, code of 2013 is extremely different to 2012
I still want 2 cards...


and... how can you deal with some card like this

rule http://www.mtgdeckbuilder.net/forums/messages.aspx?TopicID=3067
I still want 2 cards...


and... how can you deal with some card like this

rule http://www.mtgdeckbuilder.net/forums/messages.aspx?TopicID=3067
- castled
- Posts: 84
- Joined: 09 Oct 2010, 14:50
- Location: Shenzhen,China
- Has thanked: 16 times
- Been thanked: 1 time
Return to New MTG Cards and Decks (2010, 2012, 2013, 2014, 2015, Magic Duels)
Who is online
Users browsing this forum: No registered users and 3 guests