Class CardCostModifier

All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Comparable<Entity>, HasDesc<CardCostModifierDesc>, HasCard, Trigger
Direct Known Subclasses:
OneTurnCostModifier, ToggleCostModifier

public class CardCostModifier
extends Enchantment
implements HasDesc<CardCostModifierDesc>
A card cost modifier.

In this example, the specified modifier reduces the hosting entity's cost by one.

     {
         "class": "CardCostModifier",
         "target": "SELF",
         "operation": "SUBTRACT",
         "value": 1
     }
 

When a target isn't specified, the card cost modification applies to the hand of the owner of this card cost modifier (i.e. EntityReference.FRIENDLY_HAND.

To make a card cost modifier apply to both player's hands during both player's turns, CardCostModifierArg.TARGET_PLAYER must be TargetPlayer.BOTH and the target should be EntityReference.BOTH_HANDS.

See Also:
for a spell that can put effects into play., for a list of arguments for card cost modification., Serialized Form