Page 93 of 141

Re: Card Development Questions

PostPosted: 03 Feb 2012, 20:19
by squee1968
I looked at that script, but such is beyond my fledgling scripting abilities. Perhaps jeff or someone would care to correct my script and add it to Forge.

Re: Card Development Questions

PostPosted: 04 Feb 2012, 19:07
by jeffwadsworth
Testing Graceful Antelope and noticed that the remembered lands would not work correctly all the time. Here is the script:

| Open
Name:Graceful Antelope
ManaCost:2 W W
Types:Creature Antelope
Text:no text
PT:1/4
K:Plainswalk
T:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | CombatDamage$ True | Execute$ TrigAnimate | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME deals combat damage to a player, you may have target land become a Plains until CARDNAME leaves the battlefield.
SVar:TrigAnimate:AB$ Animate | Cost$ 0 | ValidTgts$ Land | TgtPrompt$ Select target land | RememberTargets$ True
S:Mode$ Continuous | Affected$ Card.IsRemembered | AddType$ Plains | RemoveSubTypes$ True | RemoveAllAbilities$ True
T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Any | Execute$ TrigCleanup | Secondary$ True | TriggerDescription$ CARDNAME leaves play.
SVar:TrigCleanup:DB$ Cleanup | ClearRemembered$ True
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/graceful_antelope.jpg
End


Does anyone see the issue? Perhaps the Animate ability which essentially adds the targeted land to the remembered list. Like noted though, it works some of the time.

Re: Card Development Questions

PostPosted: 04 Feb 2012, 19:13
by Sloth
jeffwadsworth wrote:Testing Graceful Antelope and noticed that the remembered lands would not work correctly all the time. Here is the script:

| Open
Name:Graceful Antelope
ManaCost:2 W W
Types:Creature Antelope
Text:no text
PT:1/4
K:Plainswalk
T:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | CombatDamage$ True | Execute$ TrigAnimate | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME deals combat damage to a player, you may have target land become a Plains until CARDNAME leaves the battlefield.
SVar:TrigAnimate:AB$ Animate | Cost$ 0 | ValidTgts$ Land | TgtPrompt$ Select target land | RememberTargets$ True
S:Mode$ Continuous | Affected$ Card.IsRemembered | AddType$ Plains | RemoveSubTypes$ True | RemoveAllAbilities$ True
T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Any | Execute$ TrigCleanup | Secondary$ True | TriggerDescription$ CARDNAME leaves play.
SVar:TrigCleanup:DB$ Cleanup | ClearRemembered$ True
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/graceful_antelope.jpg
End


Does anyone see the issue? Perhaps the Animate ability which essentially adds the targeted land to the remembered list. Like noted though, it works some of the time.
I think AF Animate can handle all of this ability alone (use the parameter "UntilHostLeavesPlay$ True"). There should be no continuous static ability.

Re: Card Development Questions

PostPosted: 04 Feb 2012, 19:16
by jeffwadsworth
squee1968 wrote:I looked at that script, but such is beyond my fledgling scripting abilities. Perhaps jeff or someone would care to correct my script and add it to Forge.
Try this script:

| Open
Name:Demoralize
ManaCost:2 R
Types:Instant
Text:no text
A:SP$ Effect | Cost$ 2 R | Name$ Demoralize Effect | StaticAbilities$ KWPump,KWPump2
SVar:KWPump:Mode$ Continuous | Affected$ Creature | AddKeyword$ CARDNAME can't be blocked except by two or more creatures. | Description$ Each creature can't be blocked this turn except by two or more creatures.
SVar:KWPump2:Mode$ Continuous | Affected$ Creature | AddKeyword$ CARDNAME can't block. | Threshold$ True | Description$ Threshold — If seven or more cards are in your graveyard, creatures can't block this turn.
SVar:RemAIDeck:True
SVar:Rarity:Common
SVar:Picture:http://www.wizards.com/global/images/magic/general/demoralize.jpg
End

Re: Card Development Questions

PostPosted: 05 Feb 2012, 16:18
by jeffwadsworth
Looking at Shifting Sky. Is there a reason why "SetColor$" within Continuous doesn't recognize "ChosenColor"?

| Open
Name:Shifting Sky
ManaCost:2 U
Types:Enchantment
Text:no text
T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Any | Destination$ Battlefield | Execute$ ChooseColor | Static$ True | TriggerDescription$ As CARDNAME enters the battlefield, choose a color.
SVar:ChooseColor:AB$ ChooseColor | Cost$ 0 | Defined$ You
S:Mode$ Continuous| Affected$ Permanent.nonLand | SetColor$ ChosenColor | Description$ All nonland permanents are the chosen color.
SVar:RemAIDeck:True
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/shifting_sky.jpg
End

Re: Card Development Questions

PostPosted: 05 Feb 2012, 17:04
by lugaru
I've got a fairly odd question: what would I have to do to add cards from a set that does not exist?

I was realizing the other day that while I'm ignorant at coding, there are 10,000+ examples of cards out there so if I wanted to make a custom card, there is probably an expertly coded example to point me in the right direction.

Well a friend of mine made a custom set in 2000 or 2001 or something, which we really enjoy and play with from time to time in MTG workstation. The cards should be easy to code, since they are mostly oldschool and straightforward.

So that said... how much trouble would it be for me to set up a custom set (to enable drafting and sorting) in FORGE? Coding that set sounds like a really fun (and educational) hobby for me and we would have a lot of fun with it.

And yeah, if successful I'll ask him if he wants to share the set as a side mod for forge.

Re: Card Development Questions

PostPosted: 05 Feb 2012, 17:05
by Sloth
jeffwadsworth wrote:Looking at Shifting Sky. Is there a reason why "SetColor$" within Continuous doesn't recognize "ChosenColor"?

| Open
Name:Shifting Sky
ManaCost:2 U
Types:Enchantment
Text:no text
T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Any | Destination$ Battlefield | Execute$ ChooseColor | Static$ True | TriggerDescription$ As CARDNAME enters the battlefield, choose a color.
SVar:ChooseColor:AB$ ChooseColor | Cost$ 0 | Defined$ You
S:Mode$ Continuous| Affected$ Permanent.nonLand | SetColor$ ChosenColor | Description$ All nonland permanents are the chosen color.
SVar:RemAIDeck:True
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/shifting_sky.jpg
End
No.

Re: Card Development Questions

PostPosted: 05 Feb 2012, 19:02
by jeffwadsworth
Testing Immortal Coil. The replacement effect does not work here. Does anyone see the issue?

| Open
Name:Immortal Coil
ManaCost:2 B B
Types:Artifact
Text:no text
A:AB$ Draw | Cost$ T ExileFromGrave<2/Card> | CostDesc$ T, Exile two cards from your graveyard | NumCards$ 1 | SpellDescription$ Draw a card.
R:Event$ DamageDone | ValidTarget$ You | ReplaceWith$ Exile | Description$ If damage would be dealt to you, prevent that damage. Exile a card from your graveyard for each 1 damage prevented this way.
SVar:Exile:AB$ ChangeZone | Cost$ 0 | ChangeType$ Card | ChangeNum$ X | Origin$ Graveyard | Destination$ Exile | DefinedPlayer$ You
T:Mode$ Always | TriggerZones$ Battlefield | IsPresent$ Card.YouCtrl | PresentZone$ Graveyard | PresentCompare$ EQ0 | Execute$ TrigLoseGame | TriggerDescription$ When there are no cards in your graveyard, you lose the game.
SVar:TrigLoseGame:AB$ LosesGame | Cost$ 0 | Defined$ You
SVar:X:ReplaceCount$DamageAmount
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/immortal_coil.jpg
End

Re: Card Development Questions

PostPosted: 05 Feb 2012, 20:32
by Sloth
jeffwadsworth wrote:Testing Immortal Coil. The replacement effect does not work here. Does anyone see the issue?

| Open
Name:Immortal Coil
ManaCost:2 B B
Types:Artifact
Text:no text
A:AB$ Draw | Cost$ T ExileFromGrave<2/Card> | CostDesc$ T, Exile two cards from your graveyard | NumCards$ 1 | SpellDescription$ Draw a card.
R:Event$ DamageDone | ValidTarget$ You | ReplaceWith$ Exile | Description$ If damage would be dealt to you, prevent that damage. Exile a card from your graveyard for each 1 damage prevented this way.
SVar:Exile:AB$ ChangeZone | Cost$ 0 | ChangeType$ Card | ChangeNum$ X | Origin$ Graveyard | Destination$ Exile | DefinedPlayer$ You
T:Mode$ Always | TriggerZones$ Battlefield | IsPresent$ Card.YouCtrl | PresentZone$ Graveyard | PresentCompare$ EQ0 | Execute$ TrigLoseGame | TriggerDescription$ When there are no cards in your graveyard, you lose the game.
SVar:TrigLoseGame:AB$ LosesGame | Cost$ 0 | Defined$ You
SVar:X:ReplaceCount$DamageAmount
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/immortal_coil.jpg
End
Damage prevention is a special kind of replacement effect, it can't be scripted at the moment.

Re: Card Development Questions

PostPosted: 06 Feb 2012, 17:02
by jeffwadsworth
Sloth wrote:
jeffwadsworth wrote:Testing Immortal Coil. The replacement effect does not work here. Does anyone see the issue?

| Open
Name:Immortal Coil
ManaCost:2 B B
Types:Artifact
Text:no text
A:AB$ Draw | Cost$ T ExileFromGrave<2/Card> | CostDesc$ T, Exile two cards from your graveyard | NumCards$ 1 | SpellDescription$ Draw a card.
R:Event$ DamageDone | ValidTarget$ You | ReplaceWith$ Exile | Description$ If damage would be dealt to you, prevent that damage. Exile a card from your graveyard for each 1 damage prevented this way.
SVar:Exile:AB$ ChangeZone | Cost$ 0 | ChangeType$ Card | ChangeNum$ X | Origin$ Graveyard | Destination$ Exile | DefinedPlayer$ You
T:Mode$ Always | TriggerZones$ Battlefield | IsPresent$ Card.YouCtrl | PresentZone$ Graveyard | PresentCompare$ EQ0 | Execute$ TrigLoseGame | TriggerDescription$ When there are no cards in your graveyard, you lose the game.
SVar:TrigLoseGame:AB$ LosesGame | Cost$ 0 | Defined$ You
SVar:X:ReplaceCount$DamageAmount
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/immortal_coil.jpg
End
Damage prevention is a special kind of replacement effect, it can't be scripted at the moment.
Ok. I was confused by it being used in:
.Weathered Bodyguards
.Vigor
etc. Thanks.

| Open
Name:Weathered Bodyguards
ManaCost:5 W
Types:Creature Human Soldier
Text:no text
PT:2/5
K:Morph:3 W
R:Event$ DamageDone | ValidSource$ Creature.unblocked | ValidTarget$ You | ReplaceWith$ DmgSelf | IsCombat$ True | IsPresent$ Card.Self+untapped | Description$ As long as CARDNAME is untapped, all combat damage that would be dealt to you by unblocked creatures is dealt to CARDNAME instead.
SVar:DmgSelf:AB$DealDamage | Cost$ 0 | CombatDamage$ True | Defined$ Self | DamageSource$ ReplacedSource | NumDmg$ X
SVar:X:ReplaceCount$DamageAmount
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/weathered_bodyguards.jpg
SetInfo:TSP|Rare|http://magiccards.info/scans/en/ts/46.jpg
Oracle:As long as Weathered Bodyguards is untapped, all combat damage that would be dealt to you by unblocked creatures is dealt to Weathered Bodyguards instead.\nMorph {3}{W} (You may cast this face down as a 2/2 creature for {3}. Turn it face up any time for its morph cost.)
End



| Open
Name:Vigor
ManaCost:3 G G G
Types:Creature Elemental Incarnation
Text:no text
PT:6/6
K:Trample
R:Event$ DamageDone | ValidTarget$ Creature.YouCtrl+Other | ReplaceWith$ Counters | Description$ If damage would be dealt to a creature you control other than Vigor, prevent that damage. Put a +1/+1 counter on that creature for each 1 damage prevented this way.
SVar:Counters:AB$PutCounter | Cost$ 0 | Defined$ ReplacedTarget | CounterType$ P1P1 | CounterNum$ X
SVar:X:ReplaceCount$DamageAmount
T:Mode$ ChangesZone | Origin$ Any | Destination$ Graveyard | ValidCard$ Creature.Self | Execute$ TrigShuffle | TriggerDescription$ When CARDNAME is put into a graveyard from anywhere, shuffle it into its owner's library.
SVar:TrigShuffle:AB$ChangeZone | Cost$ 0 | Origin$ Graveyard | Destination$ Library | Shuffle$ True | Defined$ Self
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/vigor.jpg
SetInfo:LRW|Rare|http://magiccards.info/scans/en/lw/240.jpg
Oracle:Trample\nIf damage would be dealt to a creature you control other than Vigor, prevent that damage. Put a +1/+1 counter on that creature for each 1 damage prevented this way.\nWhen Vigor is put into a graveyard from anywhere, shuffle it into its owner's library.
End

Re: Card Development Questions

PostPosted: 06 Feb 2012, 17:12
by Sloth
jeffwadsworth wrote:Ok. I was confused by it being used in:
.Weathered Bodyguards
.Vigor
etc. Thanks.

| Open
Name:Weathered Bodyguards
ManaCost:5 W
Types:Creature Human Soldier
Text:no text
PT:2/5
K:Morph:3 W
R:Event$ DamageDone | ValidSource$ Creature.unblocked | ValidTarget$ You | ReplaceWith$ DmgSelf | IsCombat$ True | IsPresent$ Card.Self+untapped | Description$ As long as CARDNAME is untapped, all combat damage that would be dealt to you by unblocked creatures is dealt to CARDNAME instead.
SVar:DmgSelf:AB$DealDamage | Cost$ 0 | CombatDamage$ True | Defined$ Self | DamageSource$ ReplacedSource | NumDmg$ X
SVar:X:ReplaceCount$DamageAmount
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/weathered_bodyguards.jpg
SetInfo:TSP|Rare|http://magiccards.info/scans/en/ts/46.jpg
Oracle:As long as Weathered Bodyguards is untapped, all combat damage that would be dealt to you by unblocked creatures is dealt to Weathered Bodyguards instead.\nMorph {3}{W} (You may cast this face down as a 2/2 creature for {3}. Turn it face up any time for its morph cost.)
End



| Open
Name:Vigor
ManaCost:3 G G G
Types:Creature Elemental Incarnation
Text:no text
PT:6/6
K:Trample
R:Event$ DamageDone | ValidTarget$ Creature.YouCtrl+Other | ReplaceWith$ Counters | Description$ If damage would be dealt to a creature you control other than Vigor, prevent that damage. Put a +1/+1 counter on that creature for each 1 damage prevented this way.
SVar:Counters:AB$PutCounter | Cost$ 0 | Defined$ ReplacedTarget | CounterType$ P1P1 | CounterNum$ X
SVar:X:ReplaceCount$DamageAmount
T:Mode$ ChangesZone | Origin$ Any | Destination$ Graveyard | ValidCard$ Creature.Self | Execute$ TrigShuffle | TriggerDescription$ When CARDNAME is put into a graveyard from anywhere, shuffle it into its owner's library.
SVar:TrigShuffle:AB$ChangeZone | Cost$ 0 | Origin$ Graveyard | Destination$ Library | Shuffle$ True | Defined$ Self
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/vigor.jpg
SetInfo:LRW|Rare|http://magiccards.info/scans/en/lw/240.jpg
Oracle:Trample\nIf damage would be dealt to a creature you control other than Vigor, prevent that damage. Put a +1/+1 counter on that creature for each 1 damage prevented this way.\nWhen Vigor is put into a graveyard from anywhere, shuffle it into its owner's library.
End
Weathered Bodyguards is correct, because it does not use the word prevent. Vigor has to be fixed. Maybe it's enough to add the parameter "Prevention" to these replacement effects.

EDIT: Use "PreventionEffect$ True" in the script.

Re: Card Development Questions

PostPosted: 06 Feb 2012, 17:49
by jeffwadsworth
.Curse of Echoes attempted script that does not work.

| Open
Name:Curse of Echoes
ManaCost:4 U
Types:Enchantment Aura Curse
Text:no text
K:Enchant player
A:SP$ Attach | Cost$ 4 U | ValidTgts$ Player | AILogic$ Curse
T:Mode$ SpellCast | ValidCard$ Instant,Sorcery | ValidActivatingPlayer$ Player.EnchantedBy | Execute$ TrigCopy | TriggerZones$ Battlefield | OptionalDecider$ Opponent | TriggerDescription$ Whenever enchanted player casts an instant or sorcery spell, each other player may copy that spell and may choose new targets for the copy he or she controls.
SVar:TrigCopy:AB$ CopySpell | Cost$ 0 | Defined$ TriggeredSpellAbility | Controller$ Opponent
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/curse_of_echoes.jpg
End


Does anyone see the issue?

Re: Card Development Questions

PostPosted: 06 Feb 2012, 19:33
by Sloth
jeffwadsworth wrote:.Curse of Echoes attempted script that does not work.

| Open
Name:Curse of Echoes
ManaCost:4 U
Types:Enchantment Aura Curse
Text:no text
K:Enchant player
A:SP$ Attach | Cost$ 4 U | ValidTgts$ Player | AILogic$ Curse
T:Mode$ SpellCast | ValidCard$ Instant,Sorcery | ValidActivatingPlayer$ Player.EnchantedBy | Execute$ TrigCopy | TriggerZones$ Battlefield | OptionalDecider$ Opponent | TriggerDescription$ Whenever enchanted player casts an instant or sorcery spell, each other player may copy that spell and may choose new targets for the copy he or she controls.
SVar:TrigCopy:AB$ CopySpell | Cost$ 0 | Defined$ TriggeredSpellAbility | Controller$ Opponent
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/curse_of_echoes.jpg
End


Does anyone see the issue?
The OptionalDecider is the opponent of Curse of Echoes and the AI decides not to copy. I will fix it.

EDIT: It was TriggeredCardOpponent

Re: Card Development Questions

PostPosted: 06 Feb 2012, 21:24
by jeffwadsworth
Well, that ChangeZone refuses to work with the DamageDone Event. It works perfectly fine with something like Draw AB, though.

| Open
Name:Immortal Coil
ManaCost:2 B B
Types:Artifact
Text:no text
A:AB$ Draw | Cost$ T ExileFromGrave<2/Card> | CostDesc$ T, Exile two cards from your graveyard | NumCards$ 1 | SpellDescription$ Draw a card.
R:Event$ DamageDone | ValidTarget$ You | ReplaceWith$ ChangeZone | PreventionEffect$ True | Description$ If damage would be dealt to you, prevent that damage. Exile a card from your graveyard for each 1 damage prevented this way.
SVar:ChangeZone:AB$ ChangeZone | Cost$ 0 | ChangeType$ Card | ChangeNum$ X | DefinedPlayer$ ReplacedTarget | Origin$ Graveyard | Destination$ Exile
T:Mode$ Always | TriggerZones$ Battlefield | IsPresent$ Card.YouCtrl | PresentZone$ Graveyard | PresentCompare$ EQ0 | Execute$ TrigLoseGame | TriggerDescription$ When there are no cards in your graveyard, you lose the game.
SVar:TrigLoseGame:AB$ LosesGame | Cost$ 0 | Defined$ You
SVar:X:ReplaceCount$DamageAmount
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/immortal_coil.jpg
End

Re: Card Development Questions

PostPosted: 06 Feb 2012, 22:16
by ArsenalNut
jeffwadsworth wrote:Well, that ChangeZone refuses to work with the DamageDone Event. It works perfectly fine with something like Draw AB, though.

| Open
Name:Immortal Coil
ManaCost:2 B B
Types:Artifact
Text:no text
A:AB$ Draw | Cost$ T ExileFromGrave<2/Card> | CostDesc$ T, Exile two cards from your graveyard | NumCards$ 1 | SpellDescription$ Draw a card.
R:Event$ DamageDone | ValidTarget$ You | ReplaceWith$ ChangeZone | PreventionEffect$ True | Description$ If damage would be dealt to you, prevent that damage. Exile a card from your graveyard for each 1 damage prevented this way.
SVar:ChangeZone:AB$ ChangeZone | Cost$ 0 | ChangeType$ Card | ChangeNum$ X | DefinedPlayer$ ReplacedTarget | Origin$ Graveyard | Destination$ Exile
T:Mode$ Always | TriggerZones$ Battlefield | IsPresent$ Card.YouCtrl | PresentZone$ Graveyard | PresentCompare$ EQ0 | Execute$ TrigLoseGame | TriggerDescription$ When there are no cards in your graveyard, you lose the game.
SVar:TrigLoseGame:AB$ LosesGame | Cost$ 0 | Defined$ You
SVar:X:ReplaceCount$DamageAmount
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/immortal_coil.jpg
End
ChangeZone is funky because of hidden and known origins. Since the graveyard is known origin by default, you have to use targets or defined to tell it what to move. In your case, you want to force it use the hidden origin logic by adding "Hidden$ True". Check out Cruel Ultimatum or Curse of Oblivion for an examples.