Card Contributions
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, Agetian, friarsol, Blacksmith, KrazyTheFox, CCGHQ Admins
Re: Card Contributions
by ArsenalNut » 26 Jun 2012, 17:06
Your syntax for the Continuous Static Effect is not correct which is causing the error. The corrected line starts with "S:" not "T:"PowerClaws wrote:Ok, so i noticed that someone had said Gauntlet of Power wasnt in forge, so i decided id see if i could find cards that did its effect and kinda blend them together, so heres my attempt, i did try adding it to the cards folder zip and testing it but it gave me an error, which leads me to think that... i have no idea what im doing, but if it helps anyone, ive included the error
- corrected syntax for static effect | Open
- S:Mode$ Continuous | Affected$ Creature.ChosenColor | AddPower$ 1 | AddToughness$ 1 | Description$ Creatures of the chosen color get +1/+1.
There is another issue with your script. The taps of mana trigger doesn't check to see if the mana produced is the same color as the chosen color so every basic land would produce an extra mana. I am not sure if Forge currently has a way to check the type produced.
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 Contributions
by torridus » 04 Jul 2012, 05:28
Hello everyone, I took care of some M13 cards. I also posted in the Developer's Corner but I wasn't certain if I should post here as well.
The first couple of cards had already been claimed but I needed to code them to test a couple of deck ideas, and figured I'd share since they were already done! Please let me know if anything is incorrect because I haven't attempted to code in cards since Forge 10/19/2010, and I haven't had the time to test anything other than Thragtusk as of yet.

The first couple of cards had already been claimed but I needed to code them to test a couple of deck ideas, and figured I'd share since they were already done! Please let me know if anything is incorrect because I haven't attempted to code in cards since Forge 10/19/2010, and I haven't had the time to test anything other than Thragtusk as of yet.
- Thragtusk | Open
- Code: Select all
Name:Thragtusk
ManaCost:4 G
Types:Creature Beast
Text:no text
PT:5/3
T:Mode$ ChangesZone | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ Life | TriggerDescription$ Whenever this creature enters the battlefield, you gain 5 life.
T:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Any | ValidCard$ Card.Self | Execute$ Token | TriggerDescription$ Whenever this creature leaves the battlefield, put a 3/3 green Beast creature token onto the battlefield
SVar:Token:AB$ Token | Cost$ 0 | TokenOwner$ You | TokenName$ Beast | TokenColors$ Green | TokenTypes$ Creature,Beast | TokenPower$ 3 | TokenToughness$ 3 | TokenAmount$ 1
SVar:Life:DB$ GainLife | Defined$ You | LifeAmount$ 5
SVar:Rarity:Rare
Oracle:When Thragtusk enters the battlefield, you gain 5 life. When Thragtusk leaves the battlefield, put a 3/3 green Beast creature token onto the battlefield.
End
- Captain's Call | Open
- Code: Select all
Name:Captain's Call
ManaCost:3 W
Types:Sorcery
Text:Put three 1/1 white Soldier creature tokens onto the battlefield.
A:SP$ Token | Cost$ 3 W | TokenAmount$ 3 | TokenName$ Soldier | TokenTypes$ Creature,Soldier | TokenOwner$ You | TokenColors$ White | TokenPower$ 1 | TokenToughness$ 1
SVar:PlayMain1:TRUE
SVar:Rarity:Common
Oracle:Put three 1/1 white Soldier creature tokens onto the battlefield.
End
- Show of Valor | Open
- Code: Select all
Name:Show of Valor
ManaCost:1 W
Types:Instant
Text:no text
A:SP$ Pump | Cost$ 1 W | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumAtt$ +2 | NumDef$ +4 | SpellDescription$ Target creature gets +2/+4 until end of turn.
SVar:Rarity:Common
Oracle:Target creature gets +2/+4 until end of turn.
End
- Prized Elephant | Open
- Code: Select all
Name:Prized Elephant
ManaCost:3 W
Types:Creature Elephant
Text:no text
PT:3/3
S:Mode$ Continuous | Affected$ Card.Self | AddPower$ 1 | AddToughness$ 1 | CheckSVar$ X | SVarCompare$ GE1 | Description$ CARDNAME gets +1/+1 as long as you control a Forest.
A:AB$ Pump | Cost$ G | KW$ Trample | SpellDescription$ CARDNAME gets trample until end of turn.
SVar:X:Count$Valid Forest.YouCtrl
SVar:Rarity:Uncommon
Oracle:Prized Elephant gets +1/+1 as long as you control a Forest.\nG: Prized Elephant gains trample until end of turn.
End
- Arctic Aven | Open
- Code: Select all
Name:Arctic Aven
ManaCost:2 U
Types:Creature Bird
Text:no text
PT:2/1
K:Flying
S:Mode$ Continuous | Affected$ Card.Self | AddPower$ 1 | AddToughness$ 1 | CheckSVar$ X | SVarCompare$ GE1 | Description$ CARDNAME gets +1/+1 as long as you control a Plains.
A:AB$ Pump | Cost$ W | KW$ Lifelink | SpellDescription$ CARDNAME gets lifelink until end of turn.
SVar:X:Count$Valid Plains.YouCtrl
SVar:Rarity:Uncommon
Oracle:Arctic Aven gets +1/+1 as long as you control a Plains.\nW: Arctic Aven gains lifelink until end of turn.
End
- Harbor Bandit | Open
- Code: Select all
Name:Harbor Bandit
ManaCost:2 B
Types:Creature Human Rogue
Text:no text
PT:2/2
S:Mode$ Continuous | Affected$ Card.Self | AddPower$ 1 | AddToughness$ 1 | CheckSVar$ X | SVarCompare$ GE1 | Description$ CARDNAME gets +1/+1 as long as you control a Island.
A:AB$ Pump | Cost$ 1 U | KW$ Unblockable | SpellDescription$ CARDNAME is unblockable this turn.
SVar:X:Count$Valid Island.YouCtrl
SVar:Rarity:Uncommon
Oracle:Harbor Bandit gets +1/+1 as long as you control an Island.\n1 W: Harbor Bandit is unblockable this turn.
End
- Crimson Muckwader | Open
- Code: Select all
Name:Crimson Muckwader
ManaCost:1 R
Types:Creature Lizard
Text:no text
PT:2/1
S:Mode$ Continuous | Affected$ Card.Self | AddPower$ 1 | AddToughness$ 1 | CheckSVar$ X | SVarCompare$ GE1 | Description$ CARDNAME gets +1/+1 as long as you control a Swamp.
A:AB$ Pump | Cost$ 2 B | KW$ Regenerate | SpellDescription$ Regenerate CARDNAME.
SVar:X:Count$Valid Swamp.YouCtrl
SVar:Rarity:Uncommon
Oracle:Crimson Muckwader gets +1/+1 as long as you control a Swamp.\n2 B: Regenerate Crimson Muckwader.
End
- Flinthoof Boar | Open
- Code: Select all
Name:Flinthoof Boar
ManaCost:1 G
Types:Creature Boar
Text:no text
PT:2/2
S:Mode$ Continuous | Affected$ Card.Self | AddPower$ 1 | AddToughness$ 1 | CheckSVar$ X | SVarCompare$ GE1 | Description$ CARDNAME gets +1/+1 as long as you control a Mountain.
A:AB$ Pump | Cost$ R | KW$ Haste | SpellDescription$ CARDNAME gains haste until end of turn.
SVar:X:Count$Valid Mountain.YouCtrl
SVar:Rarity:Uncommon
Oracle:Flinthoof Boar gets +1/+1 as long as you control a Mountain.\nR: Flinthoof Boar gains haste until end of turn.
End
- Touch of the Eternal | Open
- Code: Select all
Name:Touch of the Eternal
ManaCost:5 W W
Types:Enchantment
Text:no text
T:Mode$ Phase | Phase$ Upkeep | TriggerZones$ Battlefield | Execute$ TrigLife | TriggerDescription$ At the beginning of your upkeep, your life total becomes equal to the number of permanents you control.
SVar:TrigLife:AB$SetLife | Cost$ 0 | Defined$ You | LifeAmount$ X
SVar:X:Count$TypeYouCtrl.Permanent
SVar:Rarity:Rare
Oracle:At the beginning of your upkeep, your life total becomes equal to the number of permanents you control.
End
Re: Card Contributions
by friarsol » 04 Jul 2012, 14:14
torridus,
For scripting cards before they are released please keep them in the thread devoted to that (the one you originally posted in)
For scripting cards before they are released please keep them in the thread devoted to that (the one you originally posted in)
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: Card Contributions
by moomarc » 05 Jul 2012, 16:31
@Sloth (I think): For Cathedral Membrane, will the AI attack logic look deep enough to avoidlosing its 5 toughnes attackers to it? There's one or two other small kinks I need to work out of Squee's script (such as it still remembering blocked creatures if it doesn't die during that combat or is Blinked, but I know how to get that fix right) but if it's unfair against the AI then I don't want to spend time fixing it (time is still a rare commodity at the moment).
In the meantime Squee, grab some M13 cards while there's some left
In the meantime Squee, grab some M13 cards while there's some left
-Marc
-

moomarc - Pixel Commander
- Posts: 2091
- Joined: 04 Jun 2010, 15:22
- Location: Johannesburg, South Africa
- Has thanked: 371 times
- Been thanked: 372 times
Re: Card Contributions
by moomarc » 23 Aug 2012, 15:10
I just added Circu, Dimir Lobotomist with this script:
It works without any hassle but there's one small rule issue (possibly). Circu should target a library, whereas I have him choosing a player. As far as I can tell they're functionally the same and would be how modern cards would be templated. Only issue would be if there's some card out there that stops a card from targeting anything, or if at a later date a card is printed that stops you targeting libraries. In light of the fact that Circu is the only card printed so far that targets a library I think it should be safe.
Your thoughts?
- Circu, Dimir Lobotomist | Open
- Name:Circu, Dimir Lobotomist
ManaCost:2 U B
Types:Legendary Creature Human Wizard
Text:no text
PT:2/3
T:Mode$ SpellCast | ValidCard$ Card.Blue | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigLibraryChoice | TriggerDescription$ Whenever you cast a blue spell, exile the top card of target library.
T:Mode$ SpellCast | ValidCard$ Card.Black | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigLibraryChoice | TriggerDescription$ Whenever you cast a black spell, exile the top card of target library.
SVar:TrigLibraryChoice:DB$ ChoosePlayer | Defined$ You | AILogic$ Curse | SubAbility$ ExileTop | ChoiceTitle$ Choose target library
SVar:ExileTop:DB$ Mill | NumCards$ 1 | Defined$ ChosenPlayer | Destination$ Exile | RememberMilled$ True | StackDescription$ None
S:Mode$ CantBeCast | ValidCard$ Card.nonLand+sharesNameWith Remembered | Caster$ Opponent | Description$ Your opponents can't cast nonland cards with the same name as a card exiled with CARDNAME.
# Clears remembered cards when entering the battlefield
T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Any | Destination$ Battlefield | Execute$ StaticClear | Static$ True
SVar:StaticClear:DB$ Cleanup | ClearRemembered$ True
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/circu_dimir_lobotomist.jpg
SetInfo:RAV|Rare|http://magiccards.info/scans/en/rav/196.jpg
Oracle:Whenever you cast a blue spell, exile the top card of target library.\nWhenever you cast a black spell, exile the top card of target library.\nYour opponents can't cast nonland cards with the same name as a card exiled with Circu, Dimir Lobotomist.
End
It works without any hassle but there's one small rule issue (possibly). Circu should target a library, whereas I have him choosing a player. As far as I can tell they're functionally the same and would be how modern cards would be templated. Only issue would be if there's some card out there that stops a card from targeting anything, or if at a later date a card is printed that stops you targeting libraries. In light of the fact that Circu is the only card printed so far that targets a library I think it should be safe.
Your thoughts?
-Marc
-

moomarc - Pixel Commander
- Posts: 2091
- Joined: 04 Jun 2010, 15:22
- Location: Johannesburg, South Africa
- Has thanked: 371 times
- Been thanked: 372 times
Re: Card Contributions
by friarsol » 23 Aug 2012, 16:03
Technically, if I have an Ivory Mask in play, anyone could still use Circu to target my library. It's probably good enough for now, but we should make a note somewhere that it doesn't interact properly with Player Shroud.moomarc wrote:It works without any hassle but there's one small rule issue (possibly). Circu should target a library, whereas I have him choosing a player. As far as I can tell they're functionally the same and would be how modern cards would be templated. Only issue would be if there's some card out there that stops a card from targeting anything, or if at a later date a card is printed that stops you targeting libraries. In light of the fact that Circu is the only card printed so far that targets a library I think it should be safe.
Your thoughts?
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: Card Contributions
by moomarc » 23 Aug 2012, 16:11
That's the point. Circu targets the library, not the player so Player Shroud doesn't affect it.friarsol wrote:Technically, if I have an Ivory Mask in play, anyone could still use Circu to target my library. It's probably good enough for now, but we should make a note somewhere that it doesn't interact properly with Player Shroud.moomarc wrote:It works without any hassle but there's one small rule issue (possibly). Circu should target a library, whereas I have him choosing a player. As far as I can tell they're functionally the same and would be how modern cards would be templated. Only issue would be if there's some card out there that stops a card from targeting anything, or if at a later date a card is printed that stops you targeting libraries. In light of the fact that Circu is the only card printed so far that targets a library I think it should be safe.
Your thoughts?
That's why I used ChoosePlayer instead of a targeted mill. At least that's the way I understood it. If it should be affected by player shroud then the scripts is one line shorter and even easier. I tried to find rulings on it but I'm not sure of the best places to look.Gatherer wrote:10/1/2005: The first two abilities target libraries, not players.
Or did I just miss your point completely?
-Marc
-

moomarc - Pixel Commander
- Posts: 2091
- Joined: 04 Jun 2010, 15:22
- Location: Johannesburg, South Africa
- Has thanked: 371 times
- Been thanked: 372 times
Re: Card Contributions
by friarsol » 23 Aug 2012, 16:20
Oh, I may have just misread your post. I guess the only thing that isn't covered would be Target redirection.moomarc wrote:Or did I just miss your point completely?
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: Card Contributions
by moomarc » 23 Aug 2012, 16:35
I didn't think of that.friarsol wrote:Oh, I may have just misread your post. I guess the only thing that isn't covered would be Target redirection.moomarc wrote:Or did I just miss your point completely?
So it's not affected right now (at least not until someone implements a target replacement AF) but I'd prefer not to add a card that's not actually right.It feels like there should be some easy way to do this. Maybe have the mill targeting a player, then just have a TargetsLibrary$True param in the mill. Then when targeting checks if it can target a player with shroud, it ignores it if the source ability has the TargetsLibrary param? Not sure if that's too hacky. (Also, not sure offhand where the check happens - somewhere in isValidTarget I'd guess - so I'm not sure how viable the solution is anyway. I'll look into it if it sounds alright).
-Marc
-

moomarc - Pixel Commander
- Posts: 2091
- Joined: 04 Jun 2010, 15:22
- Location: Johannesburg, South Africa
- Has thanked: 371 times
- Been thanked: 372 times
Re: Card Contributions
by friarsol » 23 Aug 2012, 16:48
It'd probably be better as a TargetsZone$ Library parameter. If we ever got more Zones being legal targets, we could just make Zones targetable (just like when we added SAs to be targetable).moomarc wrote:It feels like there should be some easy way to do this. Maybe have the mill targeting a player, then just have a TargetsLibrary$True param in the mill. Then when targeting checks if it can target a player with shroud, it ignores it if the source ability has the TargetsLibrary param? Not sure if that's too hacky. (Also, not sure offhand where the check happens - somewhere in isValidTarget I'd guess - so I'm not sure how viable the solution is anyway. I'll look into it if it sounds alright).
The check happens twice. Once in TargetSelection and once in MagicStack.hasFizzled().
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: Card Contributions
by moomarc » 23 Aug 2012, 16:53
Thanks for the help Sol. I'll try get it working. For now I'll leave the current version in because I'm fairly sure I can get a better version done before we're able to change targets.friarsol wrote:It'd probably be better as a TargetsZone$ Library parameter. If we ever got more Zones being legal targets, we could just make Zones targetable (just like when we added SAs to be targetable).moomarc wrote:It feels like there should be some easy way to do this. Maybe have the mill targeting a player, then just have a TargetsLibrary$True param in the mill. Then when targeting checks if it can target a player with shroud, it ignores it if the source ability has the TargetsLibrary param? Not sure if that's too hacky. (Also, not sure offhand where the check happens - somewhere in isValidTarget I'd guess - so I'm not sure how viable the solution is anyway. I'll look into it if it sounds alright).
The check happens twice. Once in TargetSelection and once in MagicStack.hasFizzled().
-Marc
-

moomarc - Pixel Commander
- Posts: 2091
- Joined: 04 Jun 2010, 15:22
- Location: Johannesburg, South Africa
- Has thanked: 371 times
- Been thanked: 372 times
Re: Card Contributions
by friarsol » 30 Aug 2012, 23:59
Seeing as Alliances is only a card a way from hitting 80% I went through Ice Age to see how many could be done to get our lowest set back up. Some of these seemed pretty easy with some of the recent additions (UnlessCost etc). So in case you are bored before RtR comes out, here is some cards
- Ice Age | Open
- Call to Arms
Essence Vortex
Fiery Justice
Goblin Sappers
Icy Prison
Lim-Dul's Hex
Minion of Leshrac?
Monsoon (Unfair?)
Oath of Lim-Dul
Snowblind
Spoils of Evil
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Re: Card Contributions
by Zirbert » 27 Sep 2012, 22:17
Just announcing my intention to try scripting a few more cards, in hopes of avoiding duplication of effort (although if anybody else has them done, just not committed yet, by all means feel free to beat me to the punch). Since someone was diligent enough to add in the necessary functionality for Aeon Chronicler, I'm going to take a crack at his cycle-buddies: Benalish Commander, Roiling Horror, Fungal Behemoth, and Detritivore. The Commander had been on my most-wanted list for a while, but I couldn't figure out crack the "X can't be zero" and triggering from remving a time counter issues. The Chronicler solves both.
It probably won't be tonight, or even tomorrow, but I'll post them here as soon as they're finished and tested.
Assuming, of course, I don't get stuck on any of their other issues (Roiling Horror's P/T calculation makes me nervous), but I'm hoping to be able to crib them from similar cards.
It probably won't be tonight, or even tomorrow, but I'll post them here as soon as they're finished and tested.
Assuming, of course, I don't get stuck on any of their other issues (Roiling Horror's P/T calculation makes me nervous), but I'm hoping to be able to crib them from similar cards.
Re: Card Contributions
by Zirbert » 27 Sep 2012, 22:58
Woohoo! Benalish Commander, tested and working! Much easier than I had expected. Now it's just a matter of someone else catching any careless mistakes I've overlooked (Sol, I'm looking in your direction...).
On another purely self-absorbed note, by my count, this is the 100th card script I've contributed to Forge. I know some of you guys do more than that per expansion, but I'm pretty pleased with hitting that mark. Sitting at 98, then 99 (with Gaea's Blessing) for the last few months had been bugging me.
Now for the other three in this cycle...
- Code: Select all
Name:Benalish Commander
ManaCost:3 W
Types:Creature Human Soldier
Text:X can't be 0.
PT:*/*
S:Mode$ Continuous | EffectZone$ All | CharacteristicDefining$ True | SetPower$ Y | SetToughness$ Y | References$ Y | Description$ CARDNAME's power and toughness are each equal to the number of Soldiers you control.
K:Suspend:X:XCantBe0 X W W
T:Mode$ CounterRemoved | ValidCard$ Card.Self | TriggerZones$ Exile | CounterType$ TIME | Execute$ TrigToken | TriggerDescription$ Whenever a time counter is removed from CARDNAME while it's exiled, put a 1/1 white Soldier creature token onto the battlefield.
SVar:TrigToken:AB$ Token | Cost$ 0 | TokenAmount$ 1 | TokenName$ Soldier | TokenTypes$ Creature,Soldier | TokenOwner$ You | TokenColors$ White | TokenPower$ 1 | TokenToughness$ 1
SVar:X:Count$xPaid
SVar:Y:Count$Valid Soldier.YouCtrl
SVar:RemAIDeck:True
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/benalish_commander.jpg
SetInfo:PLC|Rare|http://magiccards.info/scans/en/pc/2.jpg
Oracle:Benalish Commander's power and toughness are each equal to the number of Soldiers you control.\nSuspend X— {X}{W}{W}. X can't be 0. (Rather than cast this card from your hand, you may pay {X}{W}{W} and exile it with X time counters on it. At the beginning of your upkeep, remove a time counter. When the last is removed, cast it without paying its mana cost. It has haste.)\nWhenever a time counter is removed from Benalish Commander while it's exiled, put a 1/1 white Soldier creature token onto the battlefield.
End
On another purely self-absorbed note, by my count, this is the 100th card script I've contributed to Forge. I know some of you guys do more than that per expansion, but I'm pretty pleased with hitting that mark. Sitting at 98, then 99 (with Gaea's Blessing) for the last few months had been bugging me.
Now for the other three in this cycle...
Last edited by Zirbert on 28 Sep 2012, 01:43, edited 1 time in total.
Re: Card Contributions
by friarsol » 28 Sep 2012, 00:03
Heh, I really scripted it for Helm of Obedience, but was still in the process of figuring out how to get all the different parts working, so I wrote the Chronicler (since it was the easiest card to script with that restriction) to make sure it got added in before things changed too much.Zirbert wrote:Since someone was diligent enough to add in the necessary functionality for Aeon Chronicler
- friarsol
- Global Moderator
- Posts: 7593
- Joined: 15 May 2010, 04:20
- Has thanked: 243 times
- Been thanked: 965 times
Who is online
Users browsing this forum: Bing [Bot] and 20 guests