Card Development Questions
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins
Re: Card Development Questions
by jeffwadsworth » 02 Sep 2011, 16:01
Other cards that will benefit from Sol's work on targeting are Jilt and Consume Strength.
- jeffwadsworth
- Super Tester Elite
- Posts: 1172
- Joined: 20 Oct 2010, 04:47
- Location: USA
- Has thanked: 287 times
- Been thanked: 70 times
Re: Card Development Questions
by ArsenalNut » 02 Sep 2011, 19:18
I haven't seen one. I don't remember exactly which card I was trying to script probably something with a coin flip. I'll look at my notes when I get home and write more details. I remember the problem with adding a IsTargeted property has to do with the targeted objects being associated with the ability instance and not the host card instance so there's no list to check against in the source card.friarsol wrote:I'll take a look at it, since Target is one of mine. Does an Issue already exist for this?
Edit: The card I was trying to script was Incremental Growth which needs to target three unique targets.
So many cards, so little time
-
ArsenalNut - Posts: 512
- Joined: 08 Jul 2011, 03:49
- Has thanked: 27 times
- Been thanked: 121 times
Re: Card Development Questions
by Iran » 02 Sep 2011, 20:33
I was trying to script Incremental Blight that is the same case. Will be need alter the Targeting code?ArsenalNut wrote: Edit: The card I was trying to script was Incremental Growth which needs to target three unique targets.
I think friarsol make some changes about this.
Re: Card Development Questions
by friarsol » 02 Sep 2011, 20:49
I already made the changes. Here's the code for the new Arc Trail. The SubAbilities would just follow suit:
- Code: Select all
A:SP$ DealDamage | Cost$ 1 R | ValidTgts$ Creature,Player,Planeswalker | TgtPrompt$ Select target creature or player (2 damage) | NumDmg$ 2 | SubAbility$ SVar=DBDealDamage | SpellDescription$ CARDNAME deals 2 damage to target creature or player and 1 damage to another target creature or player.
SVar:DBDealDamage:DB$ DealDamage | ValidTgts$ Creature,Player,Planeswalker | TgtPrompt$ Select target creature or player (1 damage) | TargetUnique$ True | NumDmg$ 1
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: Card Development Questions
by ArsenalNut » 02 Sep 2011, 23:17
Incremental Growth worked great with the new script key. I already checked it in.
So many cards, so little time
-
ArsenalNut - Posts: 512
- Joined: 08 Jul 2011, 03:49
- Has thanked: 27 times
- Been thanked: 121 times
Re: Card Development Questions
by Iran » 03 Sep 2011, 00:28
I Make the script for Incremental Blight, almost same script of the Incremental Growth.
- Code: Select all
Name:Incremental Blight
ManaCost:3 B B
Types:Sorcery
Text:no text
A:SP$ PutCounter | Cost$ 3 B B | ValidTgts$ Creature | TgtPrompt$ Select target creature |
TargetUnique$ True | CounterType$ M1M1 | CounterNum$ 1 | SubAbility$ DBTwoCounters |
SpellDescription$ Put a -1/-1 counter on target creature, two -1/-1 counters on another target creature, and three -1/-1 counters on a third creature.
SVar:DBTwoCounters:DB$ PutCounter | Cost$ 0 | ValidTgts$ Creature |TgtPrompt$ Select another
target creature | TargetUnique$ True | CounterType$ M1M1 | CounterNum$ 2 |SubAbility$ DBThreeCounters
SVar:DBThreeCounters:DB$ PutCounter | Cost$ 0 | ValidTgts$ Creature |TgtPrompt$ Select a third
target creature | TargetUnique$ True | CounterType$ M1M1 | CounterNum$ 3
End
Re: Card Development Questions
by ArsenalNut » 03 Sep 2011, 02:02
I committed Incremental Blight to the code repository. Thank you.Iran wrote:I Make the script for Incremental Blight, almost same script of the Incremental Growth.
- Code: Select all
Name:Incremental Blight
ManaCost:3 B B
Types:Sorcery
Text:no text
A:SP$ PutCounter | Cost$ 3 B B | ValidTgts$ Creature | TgtPrompt$ Select target creature |
TargetUnique$ True | CounterType$ M1M1 | CounterNum$ 1 | SubAbility$ DBTwoCounters |
SpellDescription$ Put a -1/-1 counter on target creature, two -1/-1 counters on another target creature, and three -1/-1 counters on a third creature.
SVar:DBTwoCounters:DB$ PutCounter | Cost$ 0 | ValidTgts$ Creature |TgtPrompt$ Select another
target creature | TargetUnique$ True | CounterType$ M1M1 | CounterNum$ 2 |SubAbility$ DBThreeCounters
SVar:DBThreeCounters:DB$ PutCounter | Cost$ 0 | ValidTgts$ Creature |TgtPrompt$ Select a third
target creature | TargetUnique$ True | CounterType$ M1M1 | CounterNum$ 3
End
So many cards, so little time
-
ArsenalNut - Posts: 512
- Joined: 08 Jul 2011, 03:49
- Has thanked: 27 times
- Been thanked: 121 times
Re: Card Development Questions
by friarsol » 03 Sep 2011, 16:15
Oh I just realized that the AI grabs its legal target list differently than the Human does. I'm going to go through the AFs and reuse the same function for both Players. The AI might cheat a bit when it comes to playing these cards until I'm done with that.
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: Card Development Questions
by ZzzzSleep » 04 Sep 2011, 06:50
Looking at Stormkirk Noble (http://www.wizards.com/Magic/Magazine/A ... ily/td/158), is there any way to script the ability "Stormkirk Noble can't be blocked by humans"?
Re: Card Development Questions
by Hellfish » 04 Sep 2011, 08:07
Yep, check out Sloth's "CantBeBlockedBy" keyword on cards like Manta Ray, Mudbrawler Raiders or Wanderbrine Rootcutters.
So now you're
Screaming for the blood of the cookie monster
Evil puppet demon of obesity
Time to change the tune of his fearful ballad
C is for "Lettuce," that's good enough for me
Screaming for the blood of the cookie monster
Evil puppet demon of obesity
Time to change the tune of his fearful ballad
C is for "Lettuce," that's good enough for me
-
Hellfish - Programmer
- Posts: 1297
- Joined: 07 Jun 2009, 10:41
- Location: South of the Pumphouse
- Has thanked: 110 times
- Been thanked: 169 times
Re: Card Development Questions
by ZzzzSleep » 04 Sep 2011, 14:18
Thanks! I should have Stormkirk Noble up in a day or so...
Re: Card Development Questions
by Iran » 05 Sep 2011, 00:21
I Make the script for Innistrad card Endless Ranks of the Dead. I'm not sure is 100% correct.
Is possible to script Olivia Voldaren (card of the Innistrad Set) or is not scriptable?
The mechanism of transform in this set (Innistrad) will be dificult to implement in forge.
http://mtgsalvation.com/innistrad-spoiler.html
Is possible to script Olivia Voldaren (card of the Innistrad Set) or is not scriptable?
The mechanism of transform in this set (Innistrad) will be dificult to implement in forge.
http://mtgsalvation.com/innistrad-spoiler.html
- Code: Select all
Name:Endless Ranks of the Dead
Cost:2 B B
Types:Enchantment
Text:no text
T:Mode$ Phase | Phase$ Upkeep | TriggerZones$ Battlefield | Execute$ TrigToken | TriggerDescription$
At the beginning of your upkeep, put X 2/2 black zombie creature tokens onto the battlefield, where X is half the number of the zombies you control, rounded down.
SVar:TrigToken:AB$Token | Cost$ 0 | TokenImage$ B 2 2 Zombie | TokenAmount$ X | TokenName$ Zombie | TokenTypes$ Creature,Zombie | TokenOwner$ You | TokenPower$ 2 | TokenToughness$ 2 | TokenColors$ Black
SVar:X:Count$Valid Creature.zombie+YouCtrl/HalfDown
End
Last edited by Iran on 05 Sep 2011, 03:15, edited 1 time in total.
Re: Card Development Questions
by Iran » 05 Sep 2011, 02:04
How do works the CostChange:{params} keyword?.Which params this keyword use?. Is possible make a spell you cast cost B G W B U with this keyword?. Is possible to script Fist of Suns with this keyword?
thanks
thanks
Re: Card Development Questions
by slapshot5 » 05 Sep 2011, 05:49
You'd want the AltCost SVar for this. Look at the script for Bringer of the Black Dawn for an example. I don't think Fist of Suns would currently be doable.Iran wrote:How do works the CostChange:{params} keyword?.Which params this keyword use?. Is possible make a spell you cast cost B G W B U with this keyword?. Is possible to script Fist of Suns with this keyword?
thanks
-slapshot5
- slapshot5
- Programmer
- Posts: 1391
- Joined: 03 Jan 2010, 17:47
- Location: Mac OS X
- Has thanked: 25 times
- Been thanked: 68 times
Re: Card Development Questions
by Sloth » 05 Sep 2011, 06:34
Please use this topic for Innistrad cards: viewtopic.php?f=52&t=5315Iran wrote:I Make the script for Innistrad card Endless Ranks of the Dead. I'm not sure is 100% correct.
Is possible to script Olivia Voldaren (card of the Innistrad Set) or is not scriptable?
The mechanism of transform in this set (Innistrad) will be dificult to implement in forge.
http://mtgsalvation.com/innistrad-spoiler.html
- Code: Select all
Name:Endless Ranks of the Dead
Cost:2 B B
Types:Enchantment
Text:no text
T:Mode$ Phase | Phase$ Upkeep | TriggerZones$ Battlefield | Execute$ TrigToken | TriggerDescription$
At the beginning of your upkeep, put X 2/2 black zombie creature tokens onto the battlefield, where X is half the number of the zombies you control, rounded down.
SVar:TrigToken:AB$Token | Cost$ 0 | TokenImage$ B 2 2 Zombie | TokenAmount$ X | TokenName$ Zombie | TokenTypes$ Creature,Zombie | TokenOwner$ You | TokenPower$ 2 | TokenToughness$ 2 | TokenColors$ Black
SVar:X:Count$Valid Creature.zombie+YouCtrl/HalfDown
End
And don't forget to claim them.

-
Sloth - Programmer
- Posts: 3498
- Joined: 23 Jun 2009, 19:40
- Has thanked: 125 times
- Been thanked: 507 times
Who is online
Users browsing this forum: No registered users and 82 guests