mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-13 17:27:46 +00:00
2.9 KiB
2.9 KiB
What follows is a rough start of an API document for cardscripts.
| Property | Description |
|---|---|
A |
Ability |
Colors |
Color(s) of the card When a card's color is determined by a color indicator rather than shards in a mana cost, this property must be defined. If no identifier is needed, this property should be omitted. Colors:red - This is used on Kobolds of Kher Keep, which has a casting cost of {0} and requires a red indicator to make it red.Colors:red,green - Since Arlinn, Embraced by the Moon has no casting cost (it's the back of a double-faced card), the red and green indicator must be included. |
DeckHints |
AI-related hints for a deck including this card |
K |
Keyword |
Loyalty |
Number of starting loyalty counters |
ManaCost |
Cost to cast the card shown in mana shards This property is required. It has a single parameter that is a mana cost. * ManaCost:no cost for cards that cannot be cast* ManaCost:1 W W sets the casting cost to {1}{W}{W} |
Name |
Name of the card A string of text that serves as the name of the card. Note that the registered trademark symbol cannot be included, and this property must have at least one character. Example: * Name:A Display of My Dark Power sets the card's name to "A Display of My Dark Power" |
Oracle |
Oracle text |
PT |
Power and toughness |
R |
Replacement effect |
S |
Static ability |
SVar |
String variable. Used throughout scripting in a handful of different ways. |
T |
Triggered ability |
Text |
Text on card |
Types |
Card types and subtypes Include all card types and subtypes, separated by spaces. Example: * Types:Enchantment Artifact Creature Golem for a card that reads Enchantment Artifact Creature -- Golem |
** Parameters for abilities and variables and known accepted values **
(incomplete list):
AB$: AbilityAbility$: AbilityActiveZones$: ZoneAffected$: CardAffectedZone$: ZoneChangeNum$: IntegerChangeValid$: CardTypeColorOrType$:TypeCost$: CostCount$:xPaidDB$: DBDefined$: Player, CardDescription$: TextDestination$: ZoneDestinationZone$: ZoneDigNum$: IntegerDuration$: UntilYourNextTurnEvent$: EventExecute$: DBHidden$: booleanKW$: KeywordLifeAmount$: Integer- `MayPlay$: boolean
Mode$: ModeName$: TextNotCause$: AbilityNumAtt$:+1NumCards$: IntegerOptional$: booleanOrigin$: ZoneProduced$: ManaTypeReferences$: SVarReflectProperty$: PropertyReplaceWith$: TextSP$: SpellSpellDescription$: TextStackDescription$: TextStatic$: booleanSVars$: SVarTargetMax$: IntegerTargetMin$: IntegerTargetPrompt$: TextTriggerDescription$: TextTriggeredCard$: PropertyTriggers$: ModeTriggerZones$: ZoneValid$:TriggeredValidCard$: CardValidTgts$: Player, CardType