From 6911e5a394d803a783438866a1e12aca55ffcfc4 Mon Sep 17 00:00:00 2001 From: nlsui <37106890+nlsui@users.noreply.github.com> Date: Mon, 24 Jan 2022 12:57:40 +0100 Subject: [PATCH] Added fortify --- keywordedSchema.json | 2 +- keywords/armor.go | 2 +- keywords/effect.go | 1 + keywords/fortify.go | 26 ++++++++++++++++++++++++++ keywords/fortify_test.go | 17 +++++++++++++++++ 5 files changed, 46 insertions(+), 2 deletions(-) create mode 100644 keywords/fortify.go create mode 100644 keywords/fortify_test.go diff --git a/keywordedSchema.json b/keywordedSchema.json index b252b8d..f708ebb 100644 --- a/keywordedSchema.json +++ b/keywordedSchema.json @@ -1 +1 @@ -{"Card":{"$ref":"#/definitions/Card"},"definitions":{"AdditionalCost":{"type":"interface","name":"Additional Cost","description":"Choose a Additional Cost","children":{"SacrificeCost":{"$ref":"#/definitions/SacrificeCost"},"DiscardCost":{"$ref":"#/definitions/DiscardCost"},"VoidCost":{"$ref":"#/definitions/VoidCost"}}},"Attack":{"type":"int","name":"Attack","max":32},"BasicAmount":{"type":"int","name":"Basic Amount","max":32},"Card":{"type":"interface","name":"Card","description":"Choose a Card","children":{"Action":{"$ref":"#/definitions/action"},"Entity":{"$ref":"#/definitions/entity"},"Place":{"$ref":"#/definitions/place"},"Headquarter":{"$ref":"#/definitions/headquarter"}}},"CardMode":{"type":"enum","name":"Card Mode","enum":["ALL","THIS","RANDOM","TARGET"]},"CardName":{"type":"string","name":"Card Name","max":32,"min":1},"CardType":{"type":"enum","name":"Card Type","enum":["ACTION","ENTITY","PLACE","HQ"]},"CastingCost":{"type":"int","name":"Casting Cost","max":64},"Class":{"type":"struct","name":"Class","description":"Build a Class","children":{"Nature":{"$ref":"#/definitions/Nature"},"Mysticism":{"$ref":"#/definitions/Mysticism"},"Technology":{"$ref":"#/definitions/Technology"},"Culture":{"$ref":"#/definitions/Culture"}},"required":["Nature","Mysticism","Technology","Culture"],"interactionText":"§Nature §Mysticism §Technology §Culture"},"Culture":{"type":"bool","name":"Culture"},"Delay":{"type":"int","name":"Delay","max":32},"DiscardCost":{"type":"struct","name":"Discard Cost","description":"Build a Discard Cost","children":{"Amount":{"$ref":"#/definitions/BasicAmount"}},"required":["Amount"],"interactionText":"Discard §Amount card"},"FlavourText":{"type":"string","name":"Flavour Text","max":1000},"Health":{"type":"int","name":"Health","max":32},"IntValue":{"type":"interface","name":"Int Value","description":"Choose a Int Value","children":{"SimpleIntValue":{"$ref":"#/definitions/SimpleIntValue"},"IntVariable":{"$ref":"#/definitions/IntVariableName"}}},"IntVariableName":{"type":"enum","name":"Int Variable Name","enum":["X","Y","Z"]},"Keyword":{"type":"string","name":"Keyword","max":10000},"Keywords":{"type":"array","name":"Keywords","description":"Add some Keywords","children":{"Keyword":{"$ref":"#/definitions/Keyword"}},"max":3,"min":1},"Mysticism":{"type":"bool","name":"Mysticism"},"Nature":{"type":"bool","name":"Nature"},"PlayerMode":{"type":"enum","name":"Player Mode","enum":["YOU","OPPONENT"]},"RulesText":{"type":"string","name":"Rules Text","max":1000},"RulesTexts":{"type":"array","name":"Rules Texts","description":"Add some Rules Texts","children":{"RulesText":{"$ref":"#/definitions/RulesText"}},"max":4},"SacrificeCost":{"type":"struct","name":"Sacrifice Cost","description":"Build a Sacrifice Cost","children":{"Amount":{"$ref":"#/definitions/BasicAmount"}},"required":["Amount"],"interactionText":"Sacrifice §Amount card"},"SimpleIntValue":{"type":"int","name":"Simple Int Value","max":32},"Tag":{"type":"enum","name":"Tag","enum":["AIR","ALCHEMIST","ANIMAL","ARTIFACT","ASSASSIN","BEAST","BELIEVER","BOT","BUILDING","COLOSSUS","DISASTER","DOMESTIC","DRAGON","EARTH","EPIC","EVENT","FACTORY","FIRE","HUMAN","KNOWLEDGE","LANDSCAPE","PLANT","REINFORCEMENT","WIZARD","SHRINE","SPIRIT","TACTIC","TECHNOCRAT","UNDEAD","VEHICLE","WARRIOR","WATER","WEAPON","WORKER"]},"Tags":{"type":"array","name":"Tags","description":"Add some Tags","children":{"Tag":{"$ref":"#/definitions/Tag"}},"max":3,"min":1},"Technology":{"type":"bool","name":"Technology"},"TokenType":{"type":"enum","name":"Token Type","enum":["1/1 human Recruit","2/2 Bot","3/3 animal Beast"]},"VoidCost":{"type":"struct","name":"Void Cost","description":"Build a Void Cost","children":{"Amount":{"$ref":"#/definitions/BasicAmount"}},"required":["Amount"],"interactionText":"Void §Amount card"},"abilities":{"type":"array","name":"Abilities","description":"Add some Abilities","children":{"Ability":{"$ref":"#/definitions/ability"}},"max":3},"ability":{"type":"interface","name":"Ability","description":"Choose a Ability","children":{"Arrival":{"$ref":"#/definitions/arrival"},"Avenge":{"$ref":"#/definitions/avenge"},"Battlecry":{"$ref":"#/definitions/battlecry"},"Channel":{"$ref":"#/definitions/channel"},"DiscardPay":{"$ref":"#/definitions/discardPay"},"Dismantle":{"$ref":"#/definitions/dismantle"},"Dissolve":{"$ref":"#/definitions/dissolve"},"Furious":{"$ref":"#/definitions/furious"},"Loot":{"$ref":"#/definitions/loot"},"OnConstruction":{"$ref":"#/definitions/onConstruction"},"OnDeath":{"$ref":"#/definitions/onDeath"},"OnSpawn":{"$ref":"#/definitions/onSpawn"},"Pay":{"$ref":"#/definitions/pay"},"Periodic":{"$ref":"#/definitions/periodic"},"Tribute":{"$ref":"#/definitions/tribute"}}},"action":{"type":"struct","name":"Action","description":"Build a Action","children":{"CardName":{"$ref":"#/definitions/CardName"},"CastingCost":{"$ref":"#/definitions/CastingCost"},"AdditionalCost":{"$ref":"#/definitions/AdditionalCost"},"Class":{"$ref":"#/definitions/Class"},"Effects":{"$ref":"#/definitions/effects"},"FlavourText":{"$ref":"#/definitions/FlavourText"},"Tags":{"$ref":"#/definitions/Tags"},"Keywords":{"$ref":"#/definitions/Keywords"},"RulesTexts":{"$ref":"#/definitions/RulesTexts"}},"required":["CardName","CastingCost","Class","Effects","FlavourText","Tags","Keywords","RulesTexts"],"interactionText":"§CardName §CastingCost §AdditionalCost §Class §Effects §FlavourText §Tags §Keywords §RulesTexts"},"ambush":{"type":"struct","name":"Ambush","description":"The selected Entities deal damage equal to their attack to target opposing Entity.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["NATURE"],"required":["Target"],"interactionText":"Ambush with §Target."},"anthem":{"type":"struct","name":"Anthem","description":"Anthem gives all friendly Entities with selected tag +1/+1.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"required":["Tag"],"interactionText":"Anthem §Tag."},"arm":{"type":"struct","name":"Arm","description":"Arm gives a friendly Entity +X/+X.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","TECHNOLOGY"],"required":["Target","Amount"],"interactionText":"Arm §Target §Amount."},"armor":{"type":"struct","name":"Armor","description":"Arm gives a friendly Entity +X Health permanently.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["NATURE","TECHNOLOGY"],"required":["Target","Amount"],"interactionText":"Armor §Target §Amount."},"arrival":{"type":"struct","name":"Arrival","description":"When a friendly Entity is spawned, activate Effects","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["CULTURE","NATURE"],"required":["Effects"],"interactionText":"Arrival: §Effects."},"avenge":{"type":"struct","name":"Avenge","description":"Whenever another of your Entity dies, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Avenge: §Effects."},"battlecry":{"type":"struct","name":"Battlecry","description":"At the beginning of each Combat activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Battlecry: §Effects."},"bounce":{"type":"struct","name":"Bounce","description":"Return selected Entities to your opponent's hand.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["TECHNOLOGY"],"required":["Target"],"interactionText":"Bounce §Target."},"burn":{"type":"struct","name":"Burn","description":"Deal X damage to the opposing HQ.","children":{"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["MYSTICISM","CULTURE"],"required":["Amount"],"interactionText":"Burn §Amount."},"channel":{"type":"struct","name":"Channel","description":"Whenever you play an Action, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["MYSTICISM","TECHNOLOGY"],"required":["Effects"],"interactionText":"Channel: §Effects."},"count":{"type":"struct","name":"Count","description":"Count all cards on your board with a selected tag and save this number to X.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"required":["Tag"],"interactionText":"Count §Tag."},"countPower":{"type":"struct","name":"Count Power","description":"Count your Entities with Attack greater or equal to selected Attack.","children":{"Power":{"$ref":"#/definitions/SimpleIntValue"}},"classes":["CULTURE","NATURE"],"required":["Power"],"interactionText":"Count Power §Power."},"dice":{"type":"struct","name":"Dice","description":"Set X to a random number.","children":{"Amount":{"$ref":"#/definitions/IntValue"}},"required":["Amount"],"interactionText":"Dice §Amount."},"discard":{"type":"struct","name":"Discard","description":"You have to discard a card.","children":{},"classes":["MYSTICISM"],"interactionText":"Discard."},"discardPay":{"type":"struct","name":"Discard Pay","description":"Discard a card and pay Mana(optional) to activate Effects.","children":{"ManaAmount":{"$ref":"#/definitions/SimpleIntValue"},"Effects":{"$ref":"#/definitions/effects"}},"required":["ManaAmount","Effects"],"interactionText":"Discard, Pay §ManaAmount: §Effects."},"discount":{"type":"struct","name":"Discount","description":"Reduce Mana Cost of all cards with selected type in your hand.","children":{"Amount":{"$ref":"#/definitions/IntValue"},"Type":{"$ref":"#/definitions/CardType"}},"classes":["CULTURE","TECHNOLOGY","MYSTICISM"],"required":["Amount"],"interactionText":"Discount [§Type] §Amount."},"dismantle":{"type":"struct","name":"Dismantle","description":"Sacrifice a friendly Place to activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["CULTURE","TECHNOLOGY"],"required":["Effects"],"interactionText":"Dismantle: §Effects."},"dissolve":{"type":"struct","name":"Dissolve","description":"Put cards from your Dustpile to the Void to activate Effects.","children":{"VoidAmount":{"$ref":"#/definitions/SimpleIntValue"},"Effects":{"$ref":"#/definitions/effects"}},"classes":["MYSTICISM","NATURE"],"required":["VoidAmount","Effects"],"interactionText":"Dissolve §VoidAmount: §Effects."},"drawAction":{"type":"struct","name":"Draw Action","description":"Draw an Action from your deck.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"classes":["MYSTICISM"],"interactionText":"Draw Action §Tag."},"drawEntity":{"type":"struct","name":"Draw Entity","description":"Draw an Entity from your deck.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"classes":["NATURE"],"interactionText":"Draw Entity §Tag."},"drawPlace":{"type":"struct","name":"Draw Place","description":"Draw a Place from your deck.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"classes":["TECHNOLOGY"],"interactionText":"Draw Place §Tag."},"effect":{"type":"interface","name":"Effect","description":"Choose a Effect","children":{"Ambush":{"$ref":"#/definitions/ambush"},"Anthem":{"$ref":"#/definitions/anthem"},"Arm":{"$ref":"#/definitions/arm"},"Armor":{"$ref":"#/definitions/armor"},"Bounce":{"$ref":"#/definitions/bounce"},"Burn":{"$ref":"#/definitions/burn"},"Count":{"$ref":"#/definitions/count"},"CountPower":{"$ref":"#/definitions/countPower"},"Dice":{"$ref":"#/definitions/dice"},"Discard":{"$ref":"#/definitions/discard"},"Discount":{"$ref":"#/definitions/discount"},"DrawAction":{"$ref":"#/definitions/drawAction"},"DrawEntity":{"$ref":"#/definitions/drawEntity"},"DrawPlace":{"$ref":"#/definitions/drawPlace"},"Grow":{"$ref":"#/definitions/grow"},"Harm":{"$ref":"#/definitions/harm"},"Heal":{"$ref":"#/definitions/heal"},"Kill":{"$ref":"#/definitions/kill"},"Insight":{"$ref":"#/definitions/insight"},"Mill":{"$ref":"#/definitions/mill"},"Produce":{"$ref":"#/definitions/produce"},"Ravage":{"$ref":"#/definitions/ravage"},"Reassemble":{"$ref":"#/definitions/reassemble"},"RecoverAction":{"$ref":"#/definitions/recoverAction"},"RecoverEntity":{"$ref":"#/definitions/recoverEntity"},"RecoverPlace":{"$ref":"#/definitions/recoverPlace"},"Resurrect":{"$ref":"#/definitions/resurrect"},"Repair":{"$ref":"#/definitions/repair"},"Sacrifice":{"$ref":"#/definitions/sacrifice"},"SelfBurn":{"$ref":"#/definitions/selfBurn"},"Silence":{"$ref":"#/definitions/silence"},"Spawn":{"$ref":"#/definitions/spawn"},"Strengthen":{"$ref":"#/definitions/strengthen"},"Train":{"$ref":"#/definitions/train"},"Void":{"$ref":"#/definitions/void"},"Withdraw":{"$ref":"#/definitions/withdraw"}}},"effects":{"type":"array","name":"Effects","description":"Add some Effects","children":{"Effect":{"$ref":"#/definitions/effect"}},"max":3},"entity":{"type":"struct","name":"Entity","description":"Build a Entity","children":{"CardName":{"$ref":"#/definitions/CardName"},"CastingCost":{"$ref":"#/definitions/CastingCost"},"AdditionalCost":{"$ref":"#/definitions/AdditionalCost"},"Class":{"$ref":"#/definitions/Class"},"Abilities":{"$ref":"#/definitions/abilities"},"Attack":{"$ref":"#/definitions/Attack"},"Health":{"$ref":"#/definitions/Health"},"FlavourText":{"$ref":"#/definitions/FlavourText"},"Tags":{"$ref":"#/definitions/Tags"},"Keywords":{"$ref":"#/definitions/Keywords"},"RulesTexts":{"$ref":"#/definitions/RulesTexts"}},"required":["CardName","CastingCost","Class","Abilities","Attack","Health","FlavourText","Tags","Keywords","RulesTexts"],"interactionText":"§CardName §CastingCost §AdditionalCost §Class §Abilities §Attack §Health §FlavourText §Tags §Keywords §RulesTexts"},"furious":{"type":"struct","name":"Furious","description":"Whenever this takes damage, activate effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Furious: §Effects."},"grow":{"type":"struct","name":"Grow","description":"Grow your HQ. 4 Growth increases its size by 1.","children":{"GrowthAmount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","NATURE"],"required":["GrowthAmount"],"interactionText":"Grow §GrowthAmount."},"harm":{"type":"struct","name":"Harm","description":"Deal X damage to an opposing Entity.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"required":["Target","Amount"],"interactionText":"Harm §Target §Amount."},"headquarter":{"type":"struct","name":"Headquarter","description":"Build a Headquarter","children":{"CardName":{"$ref":"#/definitions/CardName"},"Class":{"$ref":"#/definitions/Class"},"Delay":{"$ref":"#/definitions/Delay"},"Abilities":{"$ref":"#/definitions/abilities"},"Health":{"$ref":"#/definitions/Health"},"FlavourText":{"$ref":"#/definitions/FlavourText"},"Tags":{"$ref":"#/definitions/Tags"},"Keywords":{"$ref":"#/definitions/Keywords"},"RulesTexts":{"$ref":"#/definitions/RulesTexts"}},"required":["CardName","Class","Delay","Abilities","Health","FlavourText","Tags","Keywords","RulesTexts"],"interactionText":"§CardName §Class §Delay §Abilities §Health §Growth §StartingHandSize §Wisdom §FlavourText §Tags §Keywords §RulesTexts"},"heal":{"type":"struct","name":"Heal","description":"Restore a friendly Entity's health to full life.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["MYSTICISM","NATURE"],"required":["Target"],"interactionText":"Heal §Target"},"insight":{"type":"struct","name":"Insight","description":"Gain Wisdom. 4 Wisdom draws you a card.","children":{"WisdomAmount":{"$ref":"#/definitions/IntValue"}},"required":["WisdomAmount"],"interactionText":"Insight §WisdomAmount."},"kill":{"type":"struct","name":"Kill","description":"Put an opposing Entity from the Field in the Dustpile.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["MYSTICISM"],"required":["Target"],"interactionText":"Kill §Target"},"loot":{"type":"struct","name":"Loot","description":"Whenever an opposing Place is destroyed, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["CULTURE","NATURE"],"required":["Effects"],"interactionText":"Loot: §Effects."},"mill":{"type":"struct","name":"Mill","description":"Put cards from a player's Deck in the Dustpile.","children":{"Amount":{"$ref":"#/definitions/IntValue"},"Player":{"$ref":"#/definitions/PlayerMode"}},"classes":["MYSTICISM","TECHNOLOGY"],"required":["Amount"],"interactionText":"Mill [§Player] §Amount."},"onConstruction":{"type":"struct","name":"On Construction","description":"Whenever another friendly Place is spawned, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["CULTURE","TECHNOLOGY"],"required":["Effects"],"interactionText":"OnConstruction: §Effects."},"onDeath":{"type":"struct","name":"On Death","description":"When this dies, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"OnDeath: §Effects."},"onSpawn":{"type":"struct","name":"On Spawn","description":"Build a On Spawn","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"OnSpawn: §Effects."},"pay":{"type":"struct","name":"Pay","description":"Pay Mana to activate Effects.","children":{"ManaAmount":{"$ref":"#/definitions/SimpleIntValue"},"Effects":{"$ref":"#/definitions/effects"}},"required":["ManaAmount","Effects"],"interactionText":"Pay §ManaAmount: §Effects."},"periodic":{"type":"struct","name":"Periodic","description":"At the beginning of each tick activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Periodic: §Effects."},"place":{"type":"struct","name":"Place","description":"Build a Place","children":{"CardName":{"$ref":"#/definitions/CardName"},"CastingCost":{"$ref":"#/definitions/CastingCost"},"AdditionalCost":{"$ref":"#/definitions/AdditionalCost"},"Class":{"$ref":"#/definitions/Class"},"Abilities":{"$ref":"#/definitions/abilities"},"Health":{"$ref":"#/definitions/Health"},"FlavourText":{"$ref":"#/definitions/FlavourText"},"Tags":{"$ref":"#/definitions/Tags"},"Keywords":{"$ref":"#/definitions/Keywords"},"RulesTexts":{"$ref":"#/definitions/RulesTexts"}},"required":["CardName","CastingCost","Class","Abilities","Health","FlavourText","Tags","Keywords","RulesTexts"],"interactionText":"§CardName §CastingCost §AdditionalCost §Class §Abilities §Health §FlavourText §Tags §Keywords §RulesTexts"},"produce":{"type":"struct","name":"Produce","description":"Produce Mana.","children":{"ManaAmount":{"$ref":"#/definitions/IntValue"}},"classes":["NATURE","TECHNOLOGY"],"required":["ManaAmount"],"interactionText":"Produce §ManaAmount."},"ravage":{"type":"struct","name":"Ravage","description":"Deal X damage to an opposing Place.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","NATURE"],"required":["Target","Amount"],"interactionText":"Ravage §Target §Amount."},"reassemble":{"type":"struct","name":"Reassemble","description":"Return target Place from a Dustpile to your Field.","children":{},"classes":["TECHNOLOGY"],"interactionText":"Reassemble."},"recoverAction":{"type":"struct","name":"Recover Action","description":"Return target Action from your Dustpile to your Hand.","children":{},"classes":["MYSTICISM"],"interactionText":"Recover Action."},"recoverEntity":{"type":"struct","name":"Recover Entity","description":"Return target Entity from your Dustpile to your Hand.","children":{},"classes":["NATURE"],"interactionText":"Recover Entity."},"recoverPlace":{"type":"struct","name":"Recover Place","description":"Return target Place from your Dustpile to your Hand.","children":{},"classes":["TECHNOLOGY"],"interactionText":"Recover Place."},"repair":{"type":"struct","name":"Repair","description":"Restore lost Health of a friendly Place or HQ.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","TECHNOLOGY"],"required":["Target","Amount"],"interactionText":"Repair §Target §Amount."},"resurrect":{"type":"struct","name":"Resurrect","description":"Return target Entity from a Dustpile to your Field.","children":{},"classes":["MYSTICISM"],"interactionText":"Resurrect."},"sacrifice":{"type":"struct","name":"Sacrifice","description":"Put a friendly Entity from the Field in the Dustpile.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"required":["Target"],"interactionText":"Sacrifice §Target"},"selfBurn":{"type":"struct","name":"Self Burn","description":"Deal X damage to your HQ.","children":{"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["NATURE","TECHNOLOGY","MYSTICISM"],"required":["Amount"],"interactionText":"SelfBurn §Amount."},"silence":{"type":"struct","name":"Silence","description":"Target Entity loses its abilities.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Player":{"$ref":"#/definitions/PlayerMode"}},"classes":["MYSTICISM"],"required":["Target","Player"],"interactionText":"Silence §Target §Player"},"spawn":{"type":"struct","name":"Spawn","description":"Spawns a number of selected Tokens.","children":{"TokenType":{"$ref":"#/definitions/TokenType"},"Amount":{"$ref":"#/definitions/IntValue"}},"required":["TokenType","Amount"],"interactionText":"Spawn §Amount §TokenType."},"strengthen":{"type":"struct","name":"Strengthen","description":"Strengthen gives a friendly Entity +X attack permanently.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","NATURE"],"required":["Target","Amount"],"interactionText":"Strengthen §Target §Amount."},"train":{"type":"struct","name":"Train","description":"Train gives a friendly Entity in your Hand +X/+X.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE"],"required":["Target","Amount"],"interactionText":"Train §Target §Amount."},"tribute":{"type":"struct","name":"Tribute","description":"Sacrifice a friendly Entity to activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Tribute: §Effects."},"void":{"type":"struct","name":"Void","description":"Put opposing cards from the Dustpile in the Void.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["MYSTICISM","NATURE"],"required":["Target"],"interactionText":"Void §Target"},"withdraw":{"type":"struct","name":"Withdraw","description":"Return Entities from the Field to your Hand.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["MYSTICISM","CULTURE"],"required":["Target"],"interactionText":"Withdraw §Target."}}} \ No newline at end of file +{"Card":{"$ref":"#/definitions/Card"},"definitions":{"AdditionalCost":{"type":"interface","name":"Additional Cost","description":"Choose a Additional Cost","children":{"SacrificeCost":{"$ref":"#/definitions/SacrificeCost"},"DiscardCost":{"$ref":"#/definitions/DiscardCost"},"VoidCost":{"$ref":"#/definitions/VoidCost"}}},"Attack":{"type":"int","name":"Attack","max":32},"BasicAmount":{"type":"int","name":"Basic Amount","max":32},"Card":{"type":"interface","name":"Card","description":"Choose a Card","children":{"Action":{"$ref":"#/definitions/action"},"Entity":{"$ref":"#/definitions/entity"},"Place":{"$ref":"#/definitions/place"},"Headquarter":{"$ref":"#/definitions/headquarter"}}},"CardMode":{"type":"enum","name":"Card Mode","enum":["ALL","THIS","RANDOM","TARGET"]},"CardName":{"type":"string","name":"Card Name","max":32,"min":1},"CardType":{"type":"enum","name":"Card Type","enum":["ACTION","ENTITY","PLACE","HQ"]},"CastingCost":{"type":"int","name":"Casting Cost","max":64},"Class":{"type":"struct","name":"Class","description":"Build a Class","children":{"Nature":{"$ref":"#/definitions/Nature"},"Mysticism":{"$ref":"#/definitions/Mysticism"},"Technology":{"$ref":"#/definitions/Technology"},"Culture":{"$ref":"#/definitions/Culture"}},"required":["Nature","Mysticism","Technology","Culture"],"interactionText":"§Nature §Mysticism §Technology §Culture"},"Culture":{"type":"bool","name":"Culture"},"Delay":{"type":"int","name":"Delay","max":32},"DiscardCost":{"type":"struct","name":"Discard Cost","description":"Build a Discard Cost","children":{"Amount":{"$ref":"#/definitions/BasicAmount"}},"required":["Amount"],"interactionText":"Discard §Amount card"},"FlavourText":{"type":"string","name":"Flavour Text","max":1000},"Health":{"type":"int","name":"Health","max":32},"IntValue":{"type":"interface","name":"Int Value","description":"Choose a Int Value","children":{"SimpleIntValue":{"$ref":"#/definitions/SimpleIntValue"},"IntVariable":{"$ref":"#/definitions/IntVariableName"}}},"IntVariableName":{"type":"enum","name":"Int Variable Name","enum":["X","Y","Z"]},"Keyword":{"type":"string","name":"Keyword","max":10000},"Keywords":{"type":"array","name":"Keywords","description":"Add some Keywords","children":{"Keyword":{"$ref":"#/definitions/Keyword"}},"max":3,"min":1},"Mysticism":{"type":"bool","name":"Mysticism"},"Nature":{"type":"bool","name":"Nature"},"PlayerMode":{"type":"enum","name":"Player Mode","enum":["YOU","OPPONENT"]},"RulesText":{"type":"string","name":"Rules Text","max":1000},"RulesTexts":{"type":"array","name":"Rules Texts","description":"Add some Rules Texts","children":{"RulesText":{"$ref":"#/definitions/RulesText"}},"max":4},"SacrificeCost":{"type":"struct","name":"Sacrifice Cost","description":"Build a Sacrifice Cost","children":{"Amount":{"$ref":"#/definitions/BasicAmount"}},"required":["Amount"],"interactionText":"Sacrifice §Amount card"},"SimpleIntValue":{"type":"int","name":"Simple Int Value","max":32},"Tag":{"type":"enum","name":"Tag","enum":["AIR","ALCHEMIST","ANIMAL","ARTIFACT","ASSASSIN","BEAST","BELIEVER","BOT","BUILDING","COLOSSUS","DISASTER","DOMESTIC","DRAGON","EARTH","EPIC","EVENT","FACTORY","FIRE","HUMAN","KNOWLEDGE","LANDSCAPE","PLANT","REINFORCEMENT","WIZARD","SHRINE","SPIRIT","TACTIC","TECHNOCRAT","UNDEAD","VEHICLE","WARRIOR","WATER","WEAPON","WORKER"]},"Tags":{"type":"array","name":"Tags","description":"Add some Tags","children":{"Tag":{"$ref":"#/definitions/Tag"}},"max":3,"min":1},"Technology":{"type":"bool","name":"Technology"},"TokenType":{"type":"enum","name":"Token Type","enum":["1/1 human Recruit","2/2 Bot","3/3 animal Beast"]},"VoidCost":{"type":"struct","name":"Void Cost","description":"Build a Void Cost","children":{"Amount":{"$ref":"#/definitions/BasicAmount"}},"required":["Amount"],"interactionText":"Void §Amount card"},"abilities":{"type":"array","name":"Abilities","description":"Add some Abilities","children":{"Ability":{"$ref":"#/definitions/ability"}},"max":3},"ability":{"type":"interface","name":"Ability","description":"Choose a Ability","children":{"Arrival":{"$ref":"#/definitions/arrival"},"Avenge":{"$ref":"#/definitions/avenge"},"Battlecry":{"$ref":"#/definitions/battlecry"},"Channel":{"$ref":"#/definitions/channel"},"DiscardPay":{"$ref":"#/definitions/discardPay"},"Dismantle":{"$ref":"#/definitions/dismantle"},"Dissolve":{"$ref":"#/definitions/dissolve"},"Furious":{"$ref":"#/definitions/furious"},"Loot":{"$ref":"#/definitions/loot"},"OnConstruction":{"$ref":"#/definitions/onConstruction"},"OnDeath":{"$ref":"#/definitions/onDeath"},"OnSpawn":{"$ref":"#/definitions/onSpawn"},"Pay":{"$ref":"#/definitions/pay"},"Periodic":{"$ref":"#/definitions/periodic"},"Tribute":{"$ref":"#/definitions/tribute"}}},"action":{"type":"struct","name":"Action","description":"Build a Action","children":{"CardName":{"$ref":"#/definitions/CardName"},"CastingCost":{"$ref":"#/definitions/CastingCost"},"AdditionalCost":{"$ref":"#/definitions/AdditionalCost"},"Class":{"$ref":"#/definitions/Class"},"Effects":{"$ref":"#/definitions/effects"},"FlavourText":{"$ref":"#/definitions/FlavourText"},"Tags":{"$ref":"#/definitions/Tags"},"Keywords":{"$ref":"#/definitions/Keywords"},"RulesTexts":{"$ref":"#/definitions/RulesTexts"}},"required":["CardName","CastingCost","Class","Effects","FlavourText","Tags","Keywords","RulesTexts"],"interactionText":"§CardName §CastingCost §AdditionalCost §Class §Effects §FlavourText §Tags §Keywords §RulesTexts"},"ambush":{"type":"struct","name":"Ambush","description":"The selected Entities deal damage equal to their attack to target opposing Entity.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["NATURE"],"required":["Target"],"interactionText":"Ambush with §Target."},"anthem":{"type":"struct","name":"Anthem","description":"Anthem gives all friendly Entities with selected tag +1/+1.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"required":["Tag"],"interactionText":"Anthem §Tag."},"arm":{"type":"struct","name":"Arm","description":"Arm gives a friendly Entity +X/+X.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","TECHNOLOGY"],"required":["Target","Amount"],"interactionText":"Arm §Target §Amount."},"armor":{"type":"struct","name":"Armor","description":"Armor gives a friendly Entity +X Health permanently.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["NATURE","TECHNOLOGY"],"required":["Target","Amount"],"interactionText":"Armor §Target §Amount."},"arrival":{"type":"struct","name":"Arrival","description":"When a friendly Entity is spawned, activate Effects","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["CULTURE","NATURE"],"required":["Effects"],"interactionText":"Arrival: §Effects."},"avenge":{"type":"struct","name":"Avenge","description":"Whenever another of your Entity dies, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Avenge: §Effects."},"battlecry":{"type":"struct","name":"Battlecry","description":"At the beginning of each Combat activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Battlecry: §Effects."},"bounce":{"type":"struct","name":"Bounce","description":"Return selected Entities to your opponent's hand.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["TECHNOLOGY"],"required":["Target"],"interactionText":"Bounce §Target."},"burn":{"type":"struct","name":"Burn","description":"Deal X damage to the opposing HQ.","children":{"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["MYSTICISM","CULTURE"],"required":["Amount"],"interactionText":"Burn §Amount."},"channel":{"type":"struct","name":"Channel","description":"Whenever you play an Action, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["MYSTICISM","TECHNOLOGY"],"required":["Effects"],"interactionText":"Channel: §Effects."},"count":{"type":"struct","name":"Count","description":"Count all cards on your board with a selected tag and save this number to X.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"required":["Tag"],"interactionText":"Count §Tag."},"countPower":{"type":"struct","name":"Count Power","description":"Count your Entities with Attack greater or equal to selected Attack.","children":{"Power":{"$ref":"#/definitions/SimpleIntValue"}},"classes":["CULTURE","NATURE"],"required":["Power"],"interactionText":"Count Power §Power."},"dice":{"type":"struct","name":"Dice","description":"Set X to a random number.","children":{"Amount":{"$ref":"#/definitions/IntValue"}},"required":["Amount"],"interactionText":"Dice §Amount."},"discard":{"type":"struct","name":"Discard","description":"You have to discard a card.","children":{},"classes":["MYSTICISM"],"interactionText":"Discard."},"discardPay":{"type":"struct","name":"Discard Pay","description":"Discard a card and pay Mana(optional) to activate Effects.","children":{"ManaAmount":{"$ref":"#/definitions/SimpleIntValue"},"Effects":{"$ref":"#/definitions/effects"}},"required":["ManaAmount","Effects"],"interactionText":"Discard, Pay §ManaAmount: §Effects."},"discount":{"type":"struct","name":"Discount","description":"Reduce Mana Cost of all cards with selected type in your hand.","children":{"Amount":{"$ref":"#/definitions/IntValue"},"Type":{"$ref":"#/definitions/CardType"}},"classes":["CULTURE","TECHNOLOGY","MYSTICISM"],"required":["Amount"],"interactionText":"Discount [§Type] §Amount."},"dismantle":{"type":"struct","name":"Dismantle","description":"Sacrifice a friendly Place to activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["CULTURE","TECHNOLOGY"],"required":["Effects"],"interactionText":"Dismantle: §Effects."},"dissolve":{"type":"struct","name":"Dissolve","description":"Put cards from your Dustpile to the Void to activate Effects.","children":{"VoidAmount":{"$ref":"#/definitions/SimpleIntValue"},"Effects":{"$ref":"#/definitions/effects"}},"classes":["MYSTICISM","NATURE"],"required":["VoidAmount","Effects"],"interactionText":"Dissolve §VoidAmount: §Effects."},"drawAction":{"type":"struct","name":"Draw Action","description":"Draw an Action from your deck.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"classes":["MYSTICISM"],"interactionText":"Draw Action §Tag."},"drawEntity":{"type":"struct","name":"Draw Entity","description":"Draw an Entity from your deck.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"classes":["NATURE"],"interactionText":"Draw Entity §Tag."},"drawPlace":{"type":"struct","name":"Draw Place","description":"Draw a Place from your deck.","children":{"Tag":{"$ref":"#/definitions/Tag"}},"classes":["TECHNOLOGY"],"interactionText":"Draw Place §Tag."},"effect":{"type":"interface","name":"Effect","description":"Choose a Effect","children":{"Ambush":{"$ref":"#/definitions/ambush"},"Anthem":{"$ref":"#/definitions/anthem"},"Arm":{"$ref":"#/definitions/arm"},"Armor":{"$ref":"#/definitions/armor"},"Bounce":{"$ref":"#/definitions/bounce"},"Burn":{"$ref":"#/definitions/burn"},"Count":{"$ref":"#/definitions/count"},"CountPower":{"$ref":"#/definitions/countPower"},"Dice":{"$ref":"#/definitions/dice"},"Discard":{"$ref":"#/definitions/discard"},"Discount":{"$ref":"#/definitions/discount"},"DrawAction":{"$ref":"#/definitions/drawAction"},"DrawEntity":{"$ref":"#/definitions/drawEntity"},"DrawPlace":{"$ref":"#/definitions/drawPlace"},"Fortify":{"$ref":"#/definitions/fortify"},"Grow":{"$ref":"#/definitions/grow"},"Harm":{"$ref":"#/definitions/harm"},"Heal":{"$ref":"#/definitions/heal"},"Kill":{"$ref":"#/definitions/kill"},"Insight":{"$ref":"#/definitions/insight"},"Mill":{"$ref":"#/definitions/mill"},"Produce":{"$ref":"#/definitions/produce"},"Ravage":{"$ref":"#/definitions/ravage"},"Reassemble":{"$ref":"#/definitions/reassemble"},"RecoverAction":{"$ref":"#/definitions/recoverAction"},"RecoverEntity":{"$ref":"#/definitions/recoverEntity"},"RecoverPlace":{"$ref":"#/definitions/recoverPlace"},"Resurrect":{"$ref":"#/definitions/resurrect"},"Repair":{"$ref":"#/definitions/repair"},"Sacrifice":{"$ref":"#/definitions/sacrifice"},"SelfBurn":{"$ref":"#/definitions/selfBurn"},"Silence":{"$ref":"#/definitions/silence"},"Spawn":{"$ref":"#/definitions/spawn"},"Strengthen":{"$ref":"#/definitions/strengthen"},"Train":{"$ref":"#/definitions/train"},"Void":{"$ref":"#/definitions/void"},"Withdraw":{"$ref":"#/definitions/withdraw"}}},"effects":{"type":"array","name":"Effects","description":"Add some Effects","children":{"Effect":{"$ref":"#/definitions/effect"}},"max":3},"entity":{"type":"struct","name":"Entity","description":"Build a Entity","children":{"CardName":{"$ref":"#/definitions/CardName"},"CastingCost":{"$ref":"#/definitions/CastingCost"},"AdditionalCost":{"$ref":"#/definitions/AdditionalCost"},"Class":{"$ref":"#/definitions/Class"},"Abilities":{"$ref":"#/definitions/abilities"},"Attack":{"$ref":"#/definitions/Attack"},"Health":{"$ref":"#/definitions/Health"},"FlavourText":{"$ref":"#/definitions/FlavourText"},"Tags":{"$ref":"#/definitions/Tags"},"Keywords":{"$ref":"#/definitions/Keywords"},"RulesTexts":{"$ref":"#/definitions/RulesTexts"}},"required":["CardName","CastingCost","Class","Abilities","Attack","Health","FlavourText","Tags","Keywords","RulesTexts"],"interactionText":"§CardName §CastingCost §AdditionalCost §Class §Abilities §Attack §Health §FlavourText §Tags §Keywords §RulesTexts"},"fortify":{"type":"struct","name":"Fortify","description":"Armor gives the friendly HQ +X Health permanently.","children":{"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["TECHNOLOGY","CULTURE"],"required":["Amount"],"interactionText":"Fortify §Amount."},"furious":{"type":"struct","name":"Furious","description":"Whenever this takes damage, activate effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Furious: §Effects."},"grow":{"type":"struct","name":"Grow","description":"Grow your HQ. 4 Growth increases its size by 1.","children":{"GrowthAmount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","NATURE"],"required":["GrowthAmount"],"interactionText":"Grow §GrowthAmount."},"harm":{"type":"struct","name":"Harm","description":"Deal X damage to an opposing Entity.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"required":["Target","Amount"],"interactionText":"Harm §Target §Amount."},"headquarter":{"type":"struct","name":"Headquarter","description":"Build a Headquarter","children":{"CardName":{"$ref":"#/definitions/CardName"},"Class":{"$ref":"#/definitions/Class"},"Delay":{"$ref":"#/definitions/Delay"},"Abilities":{"$ref":"#/definitions/abilities"},"Health":{"$ref":"#/definitions/Health"},"FlavourText":{"$ref":"#/definitions/FlavourText"},"Tags":{"$ref":"#/definitions/Tags"},"Keywords":{"$ref":"#/definitions/Keywords"},"RulesTexts":{"$ref":"#/definitions/RulesTexts"}},"required":["CardName","Class","Delay","Abilities","Health","FlavourText","Tags","Keywords","RulesTexts"],"interactionText":"§CardName §Class §Delay §Abilities §Health §Growth §StartingHandSize §Wisdom §FlavourText §Tags §Keywords §RulesTexts"},"heal":{"type":"struct","name":"Heal","description":"Restore a friendly Entity's health to full life.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["MYSTICISM","NATURE"],"required":["Target"],"interactionText":"Heal §Target"},"insight":{"type":"struct","name":"Insight","description":"Gain Wisdom. 4 Wisdom draws you a card.","children":{"WisdomAmount":{"$ref":"#/definitions/IntValue"}},"required":["WisdomAmount"],"interactionText":"Insight §WisdomAmount."},"kill":{"type":"struct","name":"Kill","description":"Put an opposing Entity from the Field in the Dustpile.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["MYSTICISM"],"required":["Target"],"interactionText":"Kill §Target"},"loot":{"type":"struct","name":"Loot","description":"Whenever an opposing Place is destroyed, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["CULTURE","NATURE"],"required":["Effects"],"interactionText":"Loot: §Effects."},"mill":{"type":"struct","name":"Mill","description":"Put cards from a player's Deck in the Dustpile.","children":{"Amount":{"$ref":"#/definitions/IntValue"},"Player":{"$ref":"#/definitions/PlayerMode"}},"classes":["MYSTICISM","TECHNOLOGY"],"required":["Amount"],"interactionText":"Mill [§Player] §Amount."},"onConstruction":{"type":"struct","name":"On Construction","description":"Whenever another friendly Place is spawned, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"classes":["CULTURE","TECHNOLOGY"],"required":["Effects"],"interactionText":"OnConstruction: §Effects."},"onDeath":{"type":"struct","name":"On Death","description":"When this dies, activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"OnDeath: §Effects."},"onSpawn":{"type":"struct","name":"On Spawn","description":"Build a On Spawn","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"OnSpawn: §Effects."},"pay":{"type":"struct","name":"Pay","description":"Pay Mana to activate Effects.","children":{"ManaAmount":{"$ref":"#/definitions/SimpleIntValue"},"Effects":{"$ref":"#/definitions/effects"}},"required":["ManaAmount","Effects"],"interactionText":"Pay §ManaAmount: §Effects."},"periodic":{"type":"struct","name":"Periodic","description":"At the beginning of each tick activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Periodic: §Effects."},"place":{"type":"struct","name":"Place","description":"Build a Place","children":{"CardName":{"$ref":"#/definitions/CardName"},"CastingCost":{"$ref":"#/definitions/CastingCost"},"AdditionalCost":{"$ref":"#/definitions/AdditionalCost"},"Class":{"$ref":"#/definitions/Class"},"Abilities":{"$ref":"#/definitions/abilities"},"Health":{"$ref":"#/definitions/Health"},"FlavourText":{"$ref":"#/definitions/FlavourText"},"Tags":{"$ref":"#/definitions/Tags"},"Keywords":{"$ref":"#/definitions/Keywords"},"RulesTexts":{"$ref":"#/definitions/RulesTexts"}},"required":["CardName","CastingCost","Class","Abilities","Health","FlavourText","Tags","Keywords","RulesTexts"],"interactionText":"§CardName §CastingCost §AdditionalCost §Class §Abilities §Health §FlavourText §Tags §Keywords §RulesTexts"},"produce":{"type":"struct","name":"Produce","description":"Produce Mana.","children":{"ManaAmount":{"$ref":"#/definitions/IntValue"}},"classes":["NATURE","TECHNOLOGY"],"required":["ManaAmount"],"interactionText":"Produce §ManaAmount."},"ravage":{"type":"struct","name":"Ravage","description":"Deal X damage to an opposing Place.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","NATURE"],"required":["Target","Amount"],"interactionText":"Ravage §Target §Amount."},"reassemble":{"type":"struct","name":"Reassemble","description":"Return target Place from a Dustpile to your Field.","children":{},"classes":["TECHNOLOGY"],"interactionText":"Reassemble."},"recoverAction":{"type":"struct","name":"Recover Action","description":"Return target Action from your Dustpile to your Hand.","children":{},"classes":["MYSTICISM"],"interactionText":"Recover Action."},"recoverEntity":{"type":"struct","name":"Recover Entity","description":"Return target Entity from your Dustpile to your Hand.","children":{},"classes":["NATURE"],"interactionText":"Recover Entity."},"recoverPlace":{"type":"struct","name":"Recover Place","description":"Return target Place from your Dustpile to your Hand.","children":{},"classes":["TECHNOLOGY"],"interactionText":"Recover Place."},"repair":{"type":"struct","name":"Repair","description":"Restore lost Health of a friendly Place or HQ.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","TECHNOLOGY"],"required":["Target","Amount"],"interactionText":"Repair §Target §Amount."},"resurrect":{"type":"struct","name":"Resurrect","description":"Return target Entity from a Dustpile to your Field.","children":{},"classes":["MYSTICISM"],"interactionText":"Resurrect."},"sacrifice":{"type":"struct","name":"Sacrifice","description":"Put a friendly Entity from the Field in the Dustpile.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"required":["Target"],"interactionText":"Sacrifice §Target"},"selfBurn":{"type":"struct","name":"Self Burn","description":"Deal X damage to your HQ.","children":{"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["NATURE","TECHNOLOGY","MYSTICISM"],"required":["Amount"],"interactionText":"SelfBurn §Amount."},"silence":{"type":"struct","name":"Silence","description":"Target Entity loses its abilities.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Player":{"$ref":"#/definitions/PlayerMode"}},"classes":["MYSTICISM"],"required":["Target","Player"],"interactionText":"Silence §Target §Player"},"spawn":{"type":"struct","name":"Spawn","description":"Spawns a number of selected Tokens.","children":{"TokenType":{"$ref":"#/definitions/TokenType"},"Amount":{"$ref":"#/definitions/IntValue"}},"required":["TokenType","Amount"],"interactionText":"Spawn §Amount §TokenType."},"strengthen":{"type":"struct","name":"Strengthen","description":"Strengthen gives a friendly Entity +X attack permanently.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE","NATURE"],"required":["Target","Amount"],"interactionText":"Strengthen §Target §Amount."},"train":{"type":"struct","name":"Train","description":"Train gives a friendly Entity in your Hand +X/+X.","children":{"Target":{"$ref":"#/definitions/CardMode"},"Amount":{"$ref":"#/definitions/IntValue"}},"classes":["CULTURE"],"required":["Target","Amount"],"interactionText":"Train §Target §Amount."},"tribute":{"type":"struct","name":"Tribute","description":"Sacrifice a friendly Entity to activate Effects.","children":{"Effects":{"$ref":"#/definitions/effects"}},"required":["Effects"],"interactionText":"Tribute: §Effects."},"void":{"type":"struct","name":"Void","description":"Put opposing cards from the Dustpile in the Void.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["MYSTICISM","NATURE"],"required":["Target"],"interactionText":"Void §Target"},"withdraw":{"type":"struct","name":"Withdraw","description":"Return Entities from the Field to your Hand.","children":{"Target":{"$ref":"#/definitions/CardMode"}},"classes":["MYSTICISM","CULTURE"],"required":["Target"],"interactionText":"Withdraw §Target."}}} \ No newline at end of file diff --git a/keywords/armor.go b/keywords/armor.go index 3718d06..4aeeb48 100644 --- a/keywords/armor.go +++ b/keywords/armor.go @@ -19,7 +19,7 @@ func (a armor) InteractionText() string { } func (a armor) Description() string { - return "Arm gives a friendly Entity +X Health permanently." + return "Armor gives a friendly Entity +X Health permanently." } func (a armor) Classes() []jsonschema.Class { diff --git a/keywords/effect.go b/keywords/effect.go index c248b20..261df26 100644 --- a/keywords/effect.go +++ b/keywords/effect.go @@ -40,6 +40,7 @@ type effect struct { DrawAction *drawAction `json:",omitempty"` DrawEntity *drawEntity `json:",omitempty"` DrawPlace *drawPlace `json:",omitempty"` + Fortify *fortify `json:",omitempty"` Grow *grow `json:",omitempty"` Harm *harm `json:",omitempty"` Heal *heal `json:",omitempty"` diff --git a/keywords/fortify.go b/keywords/fortify.go new file mode 100644 index 0000000..d9286a2 --- /dev/null +++ b/keywords/fortify.go @@ -0,0 +1,26 @@ +package keywords + +import ( + "github.com/DecentralCardGame/cardobject/cardobject" + "github.com/DecentralCardGame/cardobject/jsonschema" +) + +type fortify struct { + Amount cardobject.IntValue +} + +func (f fortify) ValidateType(r jsonschema.RootElement) error { + return jsonschema.ValidateStruct(f, r) +} + +func (f fortify) InteractionText() string { + return "Fortify §Amount." +} + +func (f fortify) Description() string { + return "Armor gives the friendly HQ +X Health permanently." +} + +func (f fortify) Classes() []jsonschema.Class { + return []jsonschema.Class{cardobject.TECHNOLOGY, cardobject.CULTURE} +} diff --git a/keywords/fortify_test.go b/keywords/fortify_test.go new file mode 100644 index 0000000..04f6c3f --- /dev/null +++ b/keywords/fortify_test.go @@ -0,0 +1,17 @@ +package keywords + +import ( + "testing" + + "github.com/DecentralCardGame/cardobject/cardobject" +) + +func TestFortify(t *testing.T) { + simpleIntValue := cardobject.SimpleIntValue(3) + intValue := cardobject.IntValue{SimpleIntValue: &simpleIntValue, IntVariable: nil} + fortify := fortify{intValue} + err := fortify.ValidateType(allClassesTestCard()) + if err != nil { + t.Error(err) + } +}