Thanks for the tips on finding trigger examples! Confession time - until last night, I had no idea there were docs on coding in the wiki, and didn't know about the Committed Changes page until Sloth pointed me toward it. I'm getting a lot better idea how to write up a card or three.
I *think* this will work. Those who already know what you're doing, please feel free to correct my errors. And don't worry about being gentle, I want to learn. My first (finished) card attempt:
- Code: Select all
Name: Merrow Commerce
ManaCost:1 U
Types: Tribal Enchantment Merfolk
Text: At the beginning of your end step, untap all Merfolk you control.
T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | Execute$ UntapMerfolk | TriggerDescription$ At the beginning of your end step, untap all Merfolk you control.
SVar:UntapMerfolk:A:SP$UntapAll|Cost$0|ValidCards$Merfolk.YouCtrl|SpellDescription$Untap all Merfolk you control.
SVar:RemAIDeck:True
SVar:Rarity:Uncommon
#SVar:Picture:http://www.wizards.com/global/images/magic/general/merrow_commerce.jpg
SVar:Picture:http://gatherer.wizards.com/Handlers/Image.ashx?multiverseid=139663&type=card
SetInfo:LRW|Uncommon|http://magiccards.info/scans/en/lw/72.jpg
I'm running the 1-14 beta, and it really doesn't like this card being added to /res/cardsfolder - it makes my Forge throw up on attempted boot with this error:
- Code: Select all
null
Version:
Forge -- official beta: $Date: 2011-01-06 11:34:48 -0500 (Thu, 06 Jan 2011) $, SVN revision: $Revision: 4891 $
OS: Linux Version: 2.6.31-9-rt Architecture: amd64
Java Version: 1.6.0_18 Vendor: Sun Microsystems Inc.
Detailed error trace:
java.lang.NullPointerException
at forge.ReadCard.loadCard(ReadCard.java:154)
at forge.ReadCard.run(ReadCard.java:118)
at forge.CardFactory.readCards(CardFactory.java:92)
at forge.CardFactory.<init>(CardFactory.java:66)
at forge.AllZone.<clinit>(AllZone.java:29)
at forge.Gui_NewGame$2.run(Gui_NewGame.java:185)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:602)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:138)
I'm going to assume (hope) that this is because I'm running an "old" version that can't handle the new trigger coding. I'm not quite ready to try running SVN just yet. Or it could be because I've coded something completely nonsensical and heinous.
Feedback is welcome...
-Zirbert