diff options
| author | Florian Fischer <florian.fl.fischer@fau.de> | 2021-02-28 17:01:38 +0100 |
|---|---|---|
| committer | Florian Fischer <florian.fl.fischer@fau.de> | 2021-02-28 17:01:38 +0100 |
| commit | 0692ccd33afc4fdd80550e9979b824c1c25e973b (patch) | |
| tree | 8cf46b780af060d9fd6cf5a089729a9491eaa1c7 | |
| parent | 5074205584de432892de5b0543b64efde4ddd6e3 (diff) | |
| download | muhqs-game-0692ccd33afc4fdd80550e9979b824c1c25e973b.tar.gz muhqs-game-0692ccd33afc4fdd80550e9979b824c1c25e973b.zip | |
rework how cards are defined and generated
Card definitions are now stored in data/cards/ in a subdirectory for each
set as YAML files.
YAML is still human readable but stricter and better to handle in code
than ini.
The latex filesystem layout resembles the card definition layout and
is created by the Makefile from the YAML card definitions and must not
be regenerated each time by hand.
190 files changed, 1136 insertions, 1780 deletions
diff --git a/data/base.ini b/data/base.ini deleted file mode 100644 index 2ab76973..00000000 --- a/data/base.ini +++ /dev/null @@ -1,148 +0,0 @@ -[Sword] -type = equipment -buy = 5 -play = 2 -durability = 3 -effect = Equipped unit gains +1 Melee Damage - -[Great Sword] -type = equipment -buy = 10 -play = 4 -durability = 3 -effect = Equipped unit gains +2 Melee Damage - -[Shield] -type = equipment -buy = 5 -play = 1 -durability = 3 -effect = Equipped unit gains +1 Health - -[Tower Shield] -type = equipment -buy = 7 -play = 2 -durability = 3 -effect = Equipped unit has +2 Health - -[Archer] -type = unit -attack = 1 Range 2 -health = 2 -movement = 2 -buy = 5 -upkeep = 1 - -[Knight] -type = unit -attack = 2 -health = 2 -movement = 2 -buy = 7 -upkeep = 2 -effect = + 1 Armor - -[Fighter] -type = unit -attack = 1 -health = 2 -movement = 2 -buy = 7 -upkeep = 1 -effect = One additional attack action - -[Pikeman] -type = unit -attack = 1 -health = 2 -movement = 1 -buy = 5 -upkeep = 1 -effect = Range 2 against Units with Movement >= 3 - -[Cavalry] -type = unit -attack = 2 -health = 1 -movement = 3 -buy = 5 -upkeep = 2 - -[Tax Collector] -type = unit -health = 1 -movement = 2 -buy = 5 -upkeep = 1 -full_action = Get 2 additional Ressource - -[Pioneer] -type = unit -health = 5 -movement = 2 -buy = 7 -upkeep = 1 -full_action = Neutralize adjacent tile or Artifact - -[Recruiter] -type = unit -attack = 1 -health = 2 -movement = 2 -buy = 10 -upkeep = 1 -effect = Allow Units to be played in Range 1 -full_action = Create Recruit token on adjacent tile - -[Recruit] -type = unit -token = true -attack = 1 -health = 1 -movement = 1 -upkeep = 0 - -[Missionary] -type = unit -health = 1 -movement = 2 -buy = 10 -upkeep = 2 -full_action = Put two faith counters on target Unit. If there are more faith counters than the units buying cost you control target unit - -[Advisor] -type = unit -health = 1 -movement = 2 -buy = 10 -upkeep = 2 -full_action = Draw 1 card. You may exile 1 card from your hand - -[Wormtongue] -type = unit -health = 1 -movement = 2 -buy = 10 -upkeep = 2 -full_action = 3: Add a Misinformation token to an opponents pile - -[Misinformation] -token = true -type = spell -effect = Exile this card -play = 5 - -[Cavl. Archer] -type = unit -attack = 1 Range 2 -health = 1 -movement = 3 -buy = 10 -upkeep = 2 - -[Palisade] -type = artifact -buy = 7 -play = 3 -effect = Solid 6 diff --git a/data/cards/base/advisor.yml b/data/cards/base/advisor.yml new file mode 100644 index 00000000..b22f6781 --- /dev/null +++ b/data/cards/base/advisor.yml @@ -0,0 +1,7 @@ +type: unit +name: Advisor +health: 1 +movement: 2 +buy: 10 +upkeep: 2 +full_action: Draw 1 card. You may exile 1 card from your hand diff --git a/data/cards/base/archer.yml b/data/cards/base/archer.yml new file mode 100644 index 00000000..eb7553c5 --- /dev/null +++ b/data/cards/base/archer.yml @@ -0,0 +1,7 @@ +type: unit +name: Archer +attack: 1 Range 2 +health: 2 +movement: 2 +buy: 5 +upkeep: 1 diff --git a/data/cards/base/cavalry.yml b/data/cards/base/cavalry.yml new file mode 100644 index 00000000..574026e3 --- /dev/null +++ b/data/cards/base/cavalry.yml @@ -0,0 +1,7 @@ +type: unit +name: Cavalry +attack: 2 +health: 1 +movement: 3 +buy: 5 +upkeep: 2 diff --git a/data/cards/base/cavalry_archer.yml b/data/cards/base/cavalry_archer.yml new file mode 100644 index 00000000..f5da0265 --- /dev/null +++ b/data/cards/base/cavalry_archer.yml @@ -0,0 +1,7 @@ +type: unit +name: Cavalry Archer +attack: 1 Range 2 +health: 1 +movement: 3 +buy: 10 +upkeep: 2 diff --git a/data/cards/base/fighter.yml b/data/cards/base/fighter.yml new file mode 100644 index 00000000..113f69ff --- /dev/null +++ b/data/cards/base/fighter.yml @@ -0,0 +1,8 @@ +type: unit +name: Fighter +attack: 1 +health: 2 +movement: 2 +buy: 7 +upkeep: 1 +effect: One additional attack action diff --git a/data/cards/base/great_sword.yml b/data/cards/base/great_sword.yml new file mode 100644 index 00000000..40542ed2 --- /dev/null +++ b/data/cards/base/great_sword.yml @@ -0,0 +1,6 @@ +type: equipment +name: Great Sword +buy: 10 +play: 4 +durability: 3 +effect: Equipped unit gains +2 Melee Damage diff --git a/data/cards/base/knight.yml b/data/cards/base/knight.yml new file mode 100644 index 00000000..f8d7bdd1 --- /dev/null +++ b/data/cards/base/knight.yml @@ -0,0 +1,8 @@ +type: unit +name: Knight +attack: 2 +health: 2 +movement: 2 +buy: 7 +upkeep: 2 +effect: + 1 Armor diff --git a/data/cards/base/misinformation.yml b/data/cards/base/misinformation.yml new file mode 100644 index 00000000..08e22fe3 --- /dev/null +++ b/data/cards/base/misinformation.yml @@ -0,0 +1,5 @@ +type: spell +name: Misinformation +token: true +effect: Exile this card +play: 5 diff --git a/data/cards/base/missionary.yml b/data/cards/base/missionary.yml new file mode 100644 index 00000000..77fbb694 --- /dev/null +++ b/data/cards/base/missionary.yml @@ -0,0 +1,7 @@ +type: unit +name: Missionary +health: 1 +movement: 2 +buy: 10 +upkeep: 2 +full_action: Put two faith counters on target Unit. If there are more faith counters than the units buying cost you control target unit diff --git a/data/cards/base/palisade.yml b/data/cards/base/palisade.yml new file mode 100644 index 00000000..de0d8c2c --- /dev/null +++ b/data/cards/base/palisade.yml @@ -0,0 +1,5 @@ +type: artifact +name: Palisade +buy: 7 +play: 3 +effect: Solid 6 diff --git a/data/cards/base/pikeman.yml b/data/cards/base/pikeman.yml new file mode 100644 index 00000000..766a8ff4 --- /dev/null +++ b/data/cards/base/pikeman.yml @@ -0,0 +1,8 @@ +type: unit +name: Pikeman +attack: 1 +health: 2 +movement: 1 +buy: 5 +upkeep: 1 +effect: Range 2 against Units with Movement >= 3 diff --git a/data/cards/base/pioneer.yml b/data/cards/base/pioneer.yml new file mode 100644 index 00000000..3e1315a1 --- /dev/null +++ b/data/cards/base/pioneer.yml @@ -0,0 +1,7 @@ +type: unit +name: Pioneer +health: 5 +movement: 2 +buy: 7 +upkeep: 1 +full_action: Neutralize adjacent tile or Artifact diff --git a/data/cards/base/recruit.yml b/data/cards/base/recruit.yml new file mode 100644 index 00000000..99ab85fa --- /dev/null +++ b/data/cards/base/recruit.yml @@ -0,0 +1,7 @@ +type: unit +name: Recruit +token: true +attack: 1 +health: 1 +movement: 1 +upkeep: 0 diff --git a/data/cards/base/recruiter.yml b/data/cards/base/recruiter.yml new file mode 100644 index 00000000..3dc62fbb --- /dev/null +++ b/data/cards/base/recruiter.yml @@ -0,0 +1,9 @@ +type: unit +name: Recruiter +attack: 1 +health: 2 +movement: 2 +buy: 10 +upkeep: 1 +effect: Allow Units to be played in Range 1 +full_action: Create Recruit token on adjacent tile diff --git a/data/cards/base/shield.yml b/data/cards/base/shield.yml new file mode 100644 index 00000000..3ca09d6b --- /dev/null +++ b/data/cards/base/shield.yml @@ -0,0 +1,6 @@ +type: equipment +name: Shield +buy: 5 +play: 1 +durability: 3 +effect: Equipped unit gains +1 Health diff --git a/data/cards/base/sword.yml b/data/cards/base/sword.yml new file mode 100644 index 00000000..b5875ec7 --- /dev/null +++ b/data/cards/base/sword.yml @@ -0,0 +1,6 @@ +type: equipment +name: Sword +buy: 5 +play: 2 +durability: 3 +effect: Equipped unit gains +1 Melee Damage diff --git a/data/cards/base/tax_collector.yml b/data/cards/base/tax_collector.yml new file mode 100644 index 00000000..47e46c27 --- /dev/null +++ b/data/cards/base/tax_collector.yml @@ -0,0 +1,7 @@ +type: unit +name: Tax Collector +health: 1 +movement: 2 +buy: 5 +upkeep: 1 +full_action: Get 2 additional Ressource diff --git a/data/cards/base/tower_shield.yml b/data/cards/base/tower_shield.yml new file mode 100644 index 00000000..d5d31ffa --- /dev/null +++ b/data/cards/base/tower_shield.yml @@ -0,0 +1,6 @@ +type: equipment +name: Tower Shield +buy: 7 +play: 2 +durability: 3 +effect: Equipped unit has +2 Health diff --git a/data/cards/base/wormtongue.yml b/data/cards/base/wormtongue.yml new file mode 100644 index 00000000..73207ec5 --- /dev/null +++ b/data/cards/base/wormtongue.yml @@ -0,0 +1,10 @@ +type: unit +name: Wormtongue +health: 1 +movement: 2 +buy: 10 +upkeep: 2 +full_action: + cost: 3 + effect: Add a Misinformation token to an opponents pile +latex_full_action: "\\faRedo, 3: Add a Misinformation token to an opponents pile" diff --git a/data/cards/equipments/armor.yml b/data/cards/equipments/armor.yml new file mode 100644 index 00000000..c7ebb3c2 --- /dev/null +++ b/data/cards/equipments/armor.yml @@ -0,0 +1,6 @@ +name: Armor +type: equipment +buy: 7 +play: 2 +durability: 3 +effect: Equipped unit gains + 1 Armor diff --git a/data/cards/equipments/banner.yml b/data/cards/equipments/banner.yml new file mode 100644 index 00000000..57a6c976 --- /dev/null +++ b/data/cards/equipments/banner.yml @@ -0,0 +1,5 @@ +name: Banner +type: artifact +play: 7 +buy: 2 +effect: Units you control in range 1 gain +1 attack damage and +1 movement diff --git a/data/cards/equipments/cloak.yml b/data/cards/equipments/cloak.yml new file mode 100644 index 00000000..df3f605f --- /dev/null +++ b/data/cards/equipments/cloak.yml @@ -0,0 +1,6 @@ +name: Cloak +type: equipment +play: 7 +buy: 3 +durability: 2 +effect: Equipped unit gains shroud (can't be targeted) diff --git a/data/cards/equipments/gear.yml b/data/cards/equipments/gear.yml new file mode 100644 index 00000000..e344779b --- /dev/null +++ b/data/cards/equipments/gear.yml @@ -0,0 +1,6 @@ +name: Gear +type: equipment +play: 3 +buy: 2 +durability: 3 +effect: Equipped unit gain +1 movement diff --git a/data/cards/equipments/mace.yml b/data/cards/equipments/mace.yml new file mode 100644 index 00000000..1d52190e --- /dev/null +++ b/data/cards/equipments/mace.yml @@ -0,0 +1,6 @@ +name: Mace +type: equipment +play: 6 +buy: 2 +durability: 3 +effect: Equipped unit afflicts Paralysis when dealing damage in melee combat diff --git a/data/cards/equipments/plate_armor.yml b/data/cards/equipments/plate_armor.yml new file mode 100644 index 00000000..df37de72 --- /dev/null +++ b/data/cards/equipments/plate_armor.yml @@ -0,0 +1,6 @@ +name: Plate Armor +type: equipment +buy: 8 +play: 3 +durability: 1 +effect: Equipped unit has +2 Armor and -2 Movement diff --git a/data/cards/equipments/poisoned_dagger.yml b/data/cards/equipments/poisoned_dagger.yml new file mode 100644 index 00000000..03ea2ee5 --- /dev/null +++ b/data/cards/equipments/poisoned_dagger.yml @@ -0,0 +1,6 @@ +name: Poisoned Dagger +type: equipment +play: 7 +buy: 3 +durability: 2 +effect: Equipped unit deals damage as poison counters in melee combat diff --git a/data/cards/equipments/reclaim!.yml b/data/cards/equipments/reclaim!.yml new file mode 100644 index 00000000..d264c7ad --- /dev/null +++ b/data/cards/equipments/reclaim!.yml @@ -0,0 +1,5 @@ +name: Reclaim! +type: spell +buy: 5 +play: X +effect: Teleport target Artifact you own with Playcost X to a free spawn tile of yours. diff --git a/data/cards/equipments/relic.yml b/data/cards/equipments/relic.yml new file mode 100644 index 00000000..8adfa12a --- /dev/null +++ b/data/cards/equipments/relic.yml @@ -0,0 +1,5 @@ +name: Relic +type: artifact +play: 7 +buy: 3 +effect: In your upkeep the player controlling the most units in range 1 gains 1 resource. On ties all tied players gain 1 resource. diff --git a/data/cards/equipments/shatter!.yml b/data/cards/equipments/shatter!.yml new file mode 100644 index 00000000..90e7f570 --- /dev/null +++ b/data/cards/equipments/shatter!.yml @@ -0,0 +1,5 @@ +name: Shatter! +type: spell +buy: 5 +play: X +effect: Destroy target artifact with buy = X diff --git a/data/cards/equipments/smith.yml b/data/cards/equipments/smith.yml new file mode 100644 index 00000000..1d3d55cf --- /dev/null +++ b/data/cards/equipments/smith.yml @@ -0,0 +1,11 @@ +name: Smith +type: unit +buy: 10 +upkeep: 2 +health: 1 +movement: 2 +full_action: + cost: X + effect: Create Copy of artifact with buy cost = X in range 1 on empty tile in range 1 + +latex_full_action: "\\faRedo, X: Create Copy of artifact with buy cost = X in range 1 on empty tile in range 1" diff --git a/data/cards/equipments/spear.yml b/data/cards/equipments/spear.yml new file mode 100644 index 00000000..4a7bc13c --- /dev/null +++ b/data/cards/equipments/spear.yml @@ -0,0 +1,6 @@ +name: Spear +type: equipment +play: 7 +buy: 2 +durability: 3 +effect: Equipped unit gains +1 Attack and Range 2 against unit with M >= 3 diff --git a/data/cards/kraken/angry_squid.yml b/data/cards/kraken/angry_squid.yml new file mode 100644 index 00000000..ac948323 --- /dev/null +++ b/data/cards/kraken/angry_squid.yml @@ -0,0 +1,8 @@ +name: Angry Squid +type: unit +ai: Aggressive +attack: 1 Range 2 +health: 1 +movement: 2 swimming +buy: 7 +upkeep: 2 diff --git a/data/cards/kraken/chachalot.yml b/data/cards/kraken/chachalot.yml new file mode 100644 index 00000000..ed45f7d2 --- /dev/null +++ b/data/cards/kraken/chachalot.yml @@ -0,0 +1,9 @@ +name: Chachalot +type: unit +ai: Wandering +attack: 2 +health: 2 +movement: 2 swimming +buy: 10 +upkeep: 2 +effect: + 1 Armor diff --git a/data/cards/kraken/clownfish.yml b/data/cards/kraken/clownfish.yml new file mode 100644 index 00000000..1762a848 --- /dev/null +++ b/data/cards/kraken/clownfish.yml @@ -0,0 +1,8 @@ +name: Clownfish +type: unit +ai: Shy +health: 1 +movement: 2 swimming +buy: 10 +upkeep: 2 +full_action: Get 4 additional Ressource diff --git a/data/cards/kraken/dolphin.yml b/data/cards/kraken/dolphin.yml new file mode 100644 index 00000000..f9a0c26c --- /dev/null +++ b/data/cards/kraken/dolphin.yml @@ -0,0 +1,8 @@ +name: Dolphin +type: unit +ai: Supportive +health: 2 +movement: 2 +buy: 7 +upkeep: 1 +full_action: Give random Unit in range 1 random buff diff --git a/data/cards/kraken/frost_pylon.yml b/data/cards/kraken/frost_pylon.yml new file mode 100644 index 00000000..70ba8d0f --- /dev/null +++ b/data/cards/kraken/frost_pylon.yml @@ -0,0 +1,5 @@ +name: Frost Pylon +type: artifact +buy: 5 +effect: Enemy units in range 1 can't activate abilities except full_Action(put a crack counter on Frost Pylon). If there are three or more crack counter on Frost Pylon destroy it. Frost Pylon can be played next to a random enemy unit +latex_effect: "Enemy units in range 1 can't activate abilities except: \\enquote{~\\faRedo: put a crack counter on Frost Pylon}. \\\\ \\vspace{0.3cm} If there are three or more crack counter on Frost Pylon destroy it. Frost Pylon can be played next to a random enemy unit" diff --git a/data/cards/kraken/gigantic_hail.yml b/data/cards/kraken/gigantic_hail.yml new file mode 100644 index 00000000..d25433f2 --- /dev/null +++ b/data/cards/kraken/gigantic_hail.yml @@ -0,0 +1,4 @@ +name: Gigantic Hail +type: spell +play: 3 +effect: Place an Ice Berg token on a random empty tile diff --git a/data/cards/kraken/ice_berg.yml b/data/cards/kraken/ice_berg.yml new file mode 100644 index 00000000..02f9e53e --- /dev/null +++ b/data/cards/kraken/ice_berg.yml @@ -0,0 +1,4 @@ +name: Ice Berg +type: artifact +token: true +effect: Solid 3 diff --git a/data/cards/kraken/sailfish.yml b/data/cards/kraken/sailfish.yml new file mode 100644 index 00000000..baf03f16 --- /dev/null +++ b/data/cards/kraken/sailfish.yml @@ -0,0 +1,8 @@ +name: Sailfish +type: unit +ai: Aggressive +attack: 1 +health: 1 +movement: 3 +buy: 7 +upkeep: 1 diff --git a/data/cards/kraken/suprise.yml b/data/cards/kraken/suprise.yml new file mode 100644 index 00000000..68701310 --- /dev/null +++ b/data/cards/kraken/suprise.yml @@ -0,0 +1,4 @@ +name: Suprise +type: spell +play: 1 +effect: Place the next Unit played this turn next to a random enemy Unit diff --git a/data/cards/kraken/tentacle_slap.yml b/data/cards/kraken/tentacle_slap.yml new file mode 100644 index 00000000..c4a7d5f4 --- /dev/null +++ b/data/cards/kraken/tentacle_slap.yml @@ -0,0 +1,4 @@ +name: Tentacle Slap +type: spell +play: 3 +effect: Each player discards their hand diff --git a/data/cards/kraken/the_kraken.yml b/data/cards/kraken/the_kraken.yml new file mode 100644 index 00000000..096446ba --- /dev/null +++ b/data/cards/kraken/the_kraken.yml @@ -0,0 +1,4 @@ +name: The Kraken +type: unit +health: 5 +attack: 1 diff --git a/data/cards/kraken/tides_change.yml b/data/cards/kraken/tides_change.yml new file mode 100644 index 00000000..1da2aa38 --- /dev/null +++ b/data/cards/kraken/tides_change.yml @@ -0,0 +1,4 @@ +name: Tides Change +type: spell +play: 5 +effect: Redistribute all store cards diff --git a/data/cards/kraken/unholy_cannonball.yml b/data/cards/kraken/unholy_cannonball.yml new file mode 100644 index 00000000..39618ebe --- /dev/null +++ b/data/cards/kraken/unholy_cannonball.yml @@ -0,0 +1,6 @@ +name: Unholy Cannonball +type: spell +play: 5 +effect: If no enemy Units are in range 2 of The Kraken gain 5 ressource and draw a card. Otherwise put a fear counter on all enemy Units in range 2 of The Kraken + +effect: If no enemy Units are in range~2 of The Kraken gain 5~ressource and draw a card. \\ \vspace{0.3cm} Otherwise put a fear counter on all enemy Units in range~2 of The Kraken diff --git a/data/cards/magic/action!.yml b/data/cards/magic/action!.yml new file mode 100644 index 00000000..940e4553 --- /dev/null +++ b/data/cards/magic/action!.yml @@ -0,0 +1,5 @@ +name: Action! +type: spell +buy: 5 +play: 2 +effect: Move or attack with one unit diff --git a/data/cards/magic/appear!.yml b/data/cards/magic/appear!.yml new file mode 100644 index 00000000..4a23d982 --- /dev/null +++ b/data/cards/magic/appear!.yml @@ -0,0 +1,5 @@ +name: Appear! +type: spell +buy: 7 +play: 3X +effect: Play one unit costing X on any free tile diff --git a/data/cards/magic/attack!.yml b/data/cards/magic/attack!.yml new file mode 100644 index 00000000..044bb1f9 --- /dev/null +++ b/data/cards/magic/attack!.yml @@ -0,0 +1,5 @@ +name: Attack! +type: spell +buy: 5 +play: 2 +effect: Distribute 2 times "+1 Attack this turn" on up to two units diff --git a/data/cards/magic/catalyst.yml b/data/cards/magic/catalyst.yml new file mode 100644 index 00000000..7a038280 --- /dev/null +++ b/data/cards/magic/catalyst.yml @@ -0,0 +1,5 @@ +name: catalyst +type: artifact +buy: 3 +play: 5 +effect: Spells any player controlling the most units in range 1 playes cost one less resource diff --git a/data/cards/magic/clone!.yml b/data/cards/magic/clone!.yml new file mode 100644 index 00000000..f5da8f1f --- /dev/null +++ b/data/cards/magic/clone!.yml @@ -0,0 +1,5 @@ +name: Clone! +type: spell +buy: 7 +play: 3 +effect: Copy the next card you play. You may choose new targets. If you copy a permanent place a token copy of the parmanent in range 1 of the original diff --git a/data/cards/magic/defense!.yml b/data/cards/magic/defense!.yml new file mode 100644 index 00000000..38fae437 --- /dev/null +++ b/data/cards/magic/defense!.yml @@ -0,0 +1,5 @@ +name: Defense! +type: spell +buy: 5 +play: 3 +effect: Two units gain +1 Armor until end of turn diff --git a/data/cards/magic/die!.yml b/data/cards/magic/die!.yml new file mode 100644 index 00000000..f8b13155 --- /dev/null +++ b/data/cards/magic/die!.yml @@ -0,0 +1,5 @@ +name: Die! +type: spell +buy: 10 +play: 6 +effect: Destroy target Unit diff --git a/data/cards/magic/heal!.yml b/data/cards/magic/heal!.yml new file mode 100644 index 00000000..cd8af15d --- /dev/null +++ b/data/cards/magic/heal!.yml @@ -0,0 +1,5 @@ +name: Heal! +type: spell +buy: 5 +play: 2 +effect: Target unit gains 1 Health or remove all Poison counters from it diff --git a/data/cards/magic/isolate!.yml b/data/cards/magic/isolate!.yml new file mode 100644 index 00000000..6c969c2c --- /dev/null +++ b/data/cards/magic/isolate!.yml @@ -0,0 +1,5 @@ +name: Isolate! +type: spell +buy: 5 +play: 2 +effect: Target unit can not receive or deal damage this turn diff --git a/data/cards/magic/mine!.yml b/data/cards/magic/mine!.yml new file mode 100644 index 00000000..17571785 --- /dev/null +++ b/data/cards/magic/mine!.yml @@ -0,0 +1,5 @@ +name: Mine! +type: spell +buy: 5 +play: 2 +effect: Steal 2 resource from opponent diff --git a/data/cards/magic/more!.yml b/data/cards/magic/more!.yml new file mode 100644 index 00000000..d2bcfbe8 --- /dev/null +++ b/data/cards/magic/more!.yml @@ -0,0 +1,5 @@ +name: More! +type: spell +buy: 5 +play: 2 +effect: Draw two cards diff --git a/data/cards/magic/no!.yml b/data/cards/magic/no!.yml new file mode 100644 index 00000000..f5485b70 --- /dev/null +++ b/data/cards/magic/no!.yml @@ -0,0 +1,5 @@ +name: No! +type: spell +buy: 5 +play: 2 +effect: Counter target spell diff --git a/data/cards/magic/pierce!.yml b/data/cards/magic/pierce!.yml new file mode 100644 index 00000000..8dfd4628 --- /dev/null +++ b/data/cards/magic/pierce!.yml @@ -0,0 +1,5 @@ +name: Pierce! +type: spell +buy: 5 +play: 1X +effect: Ignore X Armor of target unit this turn diff --git a/data/cards/magic/ritual!.yml b/data/cards/magic/ritual!.yml new file mode 100644 index 00000000..e317faab --- /dev/null +++ b/data/cards/magic/ritual!.yml @@ -0,0 +1,5 @@ +name: Ritual! +type: spell +buy: 7 +play: 1 +effect: Gain 3 Ressource diff --git a/data/cards/magic/rush!.yml b/data/cards/magic/rush!.yml new file mode 100644 index 00000000..84439b30 --- /dev/null +++ b/data/cards/magic/rush!.yml @@ -0,0 +1,5 @@ +name: Rush! +type: spell +buy: 5 +play: 2 +effect: Distribute 2 times "+ 2 Movement this turn" on up to two units diff --git a/data/cards/magic/select!.yml b/data/cards/magic/select!.yml new file mode 100644 index 00000000..154f840a --- /dev/null +++ b/data/cards/magic/select!.yml @@ -0,0 +1,5 @@ +name: Select! +type: spell +buy: 7 +play: 1 +effect: Draw 1. You may exile a card from your hand diff --git a/data/cards/magic/shroud!.yml b/data/cards/magic/shroud!.yml new file mode 100644 index 00000000..1a1309fa --- /dev/null +++ b/data/cards/magic/shroud!.yml @@ -0,0 +1,5 @@ +name: Shroud! +type: spell +buy: 5 +play: 2 +effect: Target unit can not be targeted this turn diff --git a/data/cards/magic/stumble!.yml b/data/cards/magic/stumble!.yml new file mode 100644 index 00000000..b384854a --- /dev/null +++ b/data/cards/magic/stumble!.yml @@ -0,0 +1,5 @@ +name: Stumble! +type: spell +buy: 5 +play: 2 +effect: Target unit can not move or attack this turn diff --git a/data/cards/magic/switch!.yml b/data/cards/magic/switch!.yml new file mode 100644 index 00000000..a93f29f1 --- /dev/null +++ b/data/cards/magic/switch!.yml @@ -0,0 +1,5 @@ +name: Switch! +type: spell +buy: 5 +play: 2 +effect: Switch the positions of two permanents you control diff --git a/data/cards/magic/transmute!.yml b/data/cards/magic/transmute!.yml new file mode 100644 index 00000000..6686b091 --- /dev/null +++ b/data/cards/magic/transmute!.yml @@ -0,0 +1,5 @@ +name: Transmute! +type: spell +buy: 5 +play: 5 +effect: Put one card from your store into your hand. Exile this card diff --git a/data/cards/misc/farmer.yml b/data/cards/misc/farmer.yml new file mode 100644 index 00000000..18c0a372 --- /dev/null +++ b/data/cards/misc/farmer.yml @@ -0,0 +1,6 @@ +name: Farmer +type: unit +attack: 1 +health: 1 +movement: 1 +upkeep: 1 diff --git a/data/cards/misc/king.yml b/data/cards/misc/king.yml new file mode 100644 index 00000000..a4e7632e --- /dev/null +++ b/data/cards/misc/king.yml @@ -0,0 +1,8 @@ +name: King +token: true +type: unit +effect: "5 Resource: +shroud until end of turn. \\ Protection from Die!" +upkeep: 0 +attack: 1 +health: 5 +movement: 1 diff --git a/data/cards/misc/stick_of_victory.yml b/data/cards/misc/stick_of_victory.yml new file mode 100644 index 00000000..629b4b42 --- /dev/null +++ b/data/cards/misc/stick_of_victory.yml @@ -0,0 +1,5 @@ +name: Stick of Victory +type: equipment +token: true +durability: infinite +effect: The controller of the equipped unit increases its victory count by 1 in their upkeep diff --git a/data/cards/nautics/barge.yml b/data/cards/nautics/barge.yml new file mode 100644 index 00000000..20e26015 --- /dev/null +++ b/data/cards/nautics/barge.yml @@ -0,0 +1,7 @@ +name: Barge +type: unit +health: 3 +movement: 3 swimming +buy: 5 +upkeep: 1 +effect: Crew 6 diff --git a/data/cards/nautics/captain.yml b/data/cards/nautics/captain.yml new file mode 100644 index 00000000..fbab764f --- /dev/null +++ b/data/cards/nautics/captain.yml @@ -0,0 +1,8 @@ +name: Captain +type: unit +health: 1 +movement: 1 +attack: 1 +buy: 7 +upkeep: 2 +effect: Other units in the same pile have no upkeep cost diff --git a/data/cards/nautics/fish_trap.yml b/data/cards/nautics/fish_trap.yml new file mode 100644 index 00000000..c7082093 --- /dev/null +++ b/data/cards/nautics/fish_trap.yml @@ -0,0 +1,5 @@ +name: Fish Trap +type: artifact +token: true +effect: Adjacent Fisher have full_action(Gain 2 Resource) +latex_effect: "Adjacent Fisher have \\\\ \\enquote{~\\faRedo: Gain 2 Resource}" diff --git a/data/cards/nautics/fisher.yml b/data/cards/nautics/fisher.yml new file mode 100644 index 00000000..9708fc67 --- /dev/null +++ b/data/cards/nautics/fisher.yml @@ -0,0 +1,8 @@ +name: Fisher +type: unit +health: 2 +movement: 2 swimming +buy: 5 +upkeep: 1 +effect: Crew 2 +full_action: Create fish trap token on adjacent water tile diff --git a/data/cards/nautics/galley.yml b/data/cards/nautics/galley.yml new file mode 100644 index 00000000..c7da7c63 --- /dev/null +++ b/data/cards/nautics/galley.yml @@ -0,0 +1,8 @@ +name: Galley +type: unit +health: 4 +attack: 1 range 2 +movement: 3 swimming +buy: 7 +upkeep: 1 +effect: Crew 3 diff --git a/data/cards/nautics/sailor.yml b/data/cards/nautics/sailor.yml new file mode 100644 index 00000000..96c95b03 --- /dev/null +++ b/data/cards/nautics/sailor.yml @@ -0,0 +1,7 @@ +name: Sailor +type: unit +health: 1 +movement: 1 +attack: 1 +upkeep: 1 +effect: A crewed unit gets +1 movement while swimming diff --git a/data/equipments.ini b/data/equipments.ini deleted file mode 100644 index 81599d01..00000000 --- a/data/equipments.ini +++ /dev/null @@ -1,80 +0,0 @@ -[Armor] -type = equipment -buy = 7 -play = 2 -durability = 3 -effect = Equipped unit gains + 1 Armor - -[Relic] -type = artifact -play = 7 -buy = 3 -effect = In your upkeep the player controlling the most units in range 1 gains 1 resource. On ties all tied players gain 1 resource. - -[Banner] -type = artifact -play = 7 -buy = 2 -effect = Units you control in range 1 gain +1 attack damage and +1 movement - -[Gear] -type = equipment -play = 3 -buy = 2 -durability = 3 -effect = Equipped unit gain +1 movement - -[Poisoned Dagger] -type = equipment -play = 7 -buy = 3 -durability = 2 -effect = Equipped unit deals damage as poison counters in melee combat - -[Mace] -type = equipment -play = 6 -buy = 2 -durability = 3 -effect = Equipped unit afflicts Paralysis when dealing damage in melee combat - -[Plate Armor] -type = equipment -buy = 8 -play = 3 -durability = 1 -effect = Equipped unit has +2 Armor and -2 Movement - -[Cloak] -type = equipment -play = 7 -buy = 3 -durability = 2 -effect = Equipped unit gains shroud (can't be targeted) - -[Spear] -type = equipment -play = 7 -buy = 2 -durability = 3 -effect = Equipped unit gains +1 Attack and Range 2 against unit with M >= 3 - -[Smith] -type = unit -buy = 10 -upkeep = 2 -health = 1 -movement = 2 -full_action = Pay X: Create Copy of artifact with buy cost = X in range 1 on empty tile in range 1 - -[Shatter!] -type = spell -buy = 5 -play = X -effect = Destroy target artifact with buy = X - -[Reclaim!] -type = spell -buy = 5 -play = X -effect = Teleport target Artifact you own with Playcost X to a free spawn tile of yours. diff --git a/data/kraken.ini b/data/kraken.ini deleted file mode 100644 index 4fdf6ab4..00000000 --- a/data/kraken.ini +++ /dev/null @@ -1,80 +0,0 @@ -[The Kraken] -type = unit -health = 5 -attack = 1 - -[Frost Pylon] -type = artifact -buy = 5 -effect = Enemy units in range 1 can't activate abilities except: "\\faRedo: put a crack counter on Frost Pylon". If there are three or more crack counter on Frost Pylon destroy it. Frots Pylon can be played next to a random enemy unit. - -[Ice Berg] -type = artifact -play = 3 -effect = Solid 3 - -[Clownfish] -type = unit -ai = Shy -health = 1 -movement = 2 swimming -buy = 10 -upkeep = 2 -full_action = Get 4 additional Ressource - -[Angry Squid] -type = unit -ai = Aggressive -attack = 1 Range 2 -health = 1 -movement = 2 swimming -buy = 7 -upkeep = 2 - -[Chachalot] -type = unit -ai = Wandering -attack = 2 -health = 2 -movement = 2 swimming -buy = 10 -upkeep = 2 -effect = + 1 Armor - -[Sailfish] -type = unit -ai = Aggressive -attack = 1 -health = 1 -movement = 3 -buy = 7 -upkeep = 1 - -[Dolphin] -type = unit -ai = Supportive -health = 2 -movement = 2 -buy = 7 -upkeep = 1 -full_action = Give random Unit in range 1 random buff - -[Tentacle Slap] -type = spell -play = 3 -effect = Each player discards their hand - -[Tides Change] -type = spell -play = 5 -effect = Redistribute all store cards - -[Suprise] -type = spell -play = 1 -effect = Place the next Unit played this turn next to a random enemy Unit - -[Unholy Cannonball] -type = spell -play = 5 -effect = If no enemy Units are in range 2 of The Kraken gains 5 ressource and draws a card. \\ Otherwise put a fear counter on all enemy Units in range 2 diff --git a/data/magic.ini b/data/magic.ini deleted file mode 100644 index 0d569601..00000000 --- a/data/magic.ini +++ /dev/null @@ -1,119 +0,0 @@ -[Defense!] -type = spell -buy = 5 -play = 3 -effect = Two units gain +1 Armor until end of turn - -[Heal!] -type = spell -buy = 5 -play = 2 -effect = Target unit gains 1 Health or remove all Poison counters from it - -[Rush!] -type = spell -buy = 5 -play = 2 -effect = Distribute 2 times "+ 2 Movement this turn" on up to two units - -[Attack!] -type = spell -buy = 5 -play = 2 -effect = Distribute 2 times "+1 Attack this turn" on up to two units - -[Action!] -type = spell -buy = 5 -play = 2 -effect = Move or attack with one unit - -[Stumble!] -type = spell -buy = 5 -play = 2 -effect = Target unit can not move or attack this turn - -[More!] -type = spell -buy = 5 -play = 2 -effect = Draw two cards - -[Select!] -type = spell -buy = 7 -play = 1 -effect = Draw 1. You may exile a card from your hand - -[Die!] -type = spell -buy = 10 -play = 6 -effect = Destroy target Unit - -[Clone!] -type = spell -buy = 7 -play = 3 -effect = Copy the next card you play. You may choose new targets. If you copy a permanent place a token copy of the parmanent in range 1 of the original - -[No!] -type = spell -buy = 5 -play = 2 -effect = Counter target spell - -[Mine!] -type = spell -buy = 5 -play = 2 -effect = Steal 2 resource from opponent - -[Isolate!] -type = spell -buy = 5 -play = 2 -effect = Target unit can not receive or deal damage this turn - -[Shroud!] -type = spell -buy = 5 -play = 2 -effect = Target unit can not be targeted this turn - -[Pierce!] -type = spell -buy = 5 -play = 1X -effect = Ignore X Armor of target unit this turn - -[Ritual!] -type = spell -buy = 7 -play = 1 -effect = Gain 3 Ressource - -[Switch!] -type = spell -buy = 5 -play = 2 -effect = Switch the positions of two permanents you control - -[Transmute!] -type = spell -buy = 5 -play = 5 -effect = Put one card from your store into your hand. Exile this card - -[Appear!] -type = spell -buy = 7 -play = 3X -effect = Play one unit costing X on any free tile - -[catalyst] -type = artifact -buy = 3 -play = 5 -effect = Spells any player controlling the most units in range 1 playes cost one less resource diff --git a/data/misc.ini b/data/misc.ini deleted file mode 100644 index a1ab9e19..00000000 --- a/data/misc.ini +++ /dev/null @@ -1,21 +0,0 @@ -[King] -token = true -type = unit -effect = 5 Resource: +shroud until end of turn. \\ Protection from Die! -upkeep = 0 -attack = 1 -health = 5 -movement = 1 - -[Farmer] -type = unit -attack = 1 -health = 1 -movement = 1 -upkeep = 1 - -[Stick of Victory] -type = equipment -token = true -durability = infinite -effect = The controller of the equipped unit increases its victory count by 1 in their upkeep diff --git a/data/nautics.ini b/data/nautics.ini deleted file mode 100644 index 48865938..00000000 --- a/data/nautics.ini +++ /dev/null @@ -1,47 +0,0 @@ -[Fisher] -type = unit -health = 2 -movement = 2 swimming -buy = 5 -upkeep = 1 -effect = Crew 2 -full_action = Create fish trap token on adjacent water tile - -[Fish Trap] -type = artifact -token = true -effect = Adjacent Fisher have \\ \faRedo: Gain 2 Resource - -[Sailor] -type = unit -health = 1 -movement = 1 -attack = 1 -upkeep = 1 -effect = A crewed unit gets +1 movement while swimming - -[Captain] -type = unit -health = 1 -movement = 1 -attack = 1 -buy = 7 -upkeep = 2 -effect = Other units in the same pile have no upkeep cost - -[Barge] -type = unit -health = 3 -movement = 3 swimming -buy = 5 -upkeep = 1 -effect = Crew 6 - -[Galley] -type = unit -health = 4 -attack = 1 range 2 -movement = 3 swimming -buy = 7 -upkeep = 1 -effect = Crew 3 diff --git a/latex/Makefile b/latex/Makefile index 5eedeb05..ce98c59d 100644 --- a/latex/Makefile +++ b/latex/Makefile @@ -1,4 +1,4 @@ -.PHONY: all clean +.PHONY: all clean clean-all cards-tex cards-pdf cards-png .DEFAULT_GOAL = all @@ -6,57 +6,83 @@ PDFLATEX = lualatex PDFTOPPM = pdftoppm PDFUNITE = pdfunite -PDFTOPPM_FLAGS = -singlefile -png -r 300 +GENERATE_CARD = $(GAME_ROOT)scripts/generate_card.py -COMMON_TEX_FILES = libs.tex colors.tex tikzcards.tex +PDFTOPPM_FLAGS = -singlefile -png -r 300 -CARDS_DIR = cards -CARD_SOURCES = $(shell find $(CARDS_DIR) -name "*.tex") +COMMON_TEX_FILES = common.tex libs.tex colors.tex tikzcards.tex -SETS_DIR = sets -SETS_SOURCES = $(shell find $(SETS_DIR) -name "*.tex") +# The full path to the Makefile +MAKEFILE_PATH := $(abspath $(lastword $(MAKEFILE_LIST))) +# The path to the directory of the Makefile +MAKEFILE_DIR := $(dir $(MAKEFILE_PATH)) -VERBOSE = @ -PDF_DIR = ./build +LATEX_ROOT := $(MAKEFILE_DIR) +GAME_ROOT := $(MAKEFILE_DIR)/../ +DATA_ROOT := $(GAME_ROOT)/data +CARDS_YML_DIR := $(DATA_ROOT)/cards +CARDS_TEX_DIR := $(LATEX_ROOT)/cards +BUILDDIR := $(LATEX_ROOT)/build -ALL_SOURCES = $(CARD_SOURCES) $(SETS_SOURCES) -PDFS = $(notdir $(ALL_SOURCES:.tex=.pdf)) -PDFS_PREFIXED = $(addprefix $(PDF_DIR)/,$(PDFS)) +ASSETS_PATH = $(GAME_ROOT)/assets +PDFLATEX_ENV := TEXINPUTS=".:$(ASSETS_PATH):" -CARD_PNGS = $(notdir $(CARD_SOURCES:.tex=.png)) -CARD_PNGS_PREFIXED = $(addprefix $(PDF_DIR)/,$(CARD_PNGS)) +SETS := $(shell find $(CARDS_YML_DIR) -mindepth 1 -type d -printf "%f\n") +SETS_SOURCEDIRS := $(foreach set, $(SETS), $(addprefix $(CARDS_YML_DIR)/, $(set))) +SETS_TEXDIRS := $(foreach set, $(SETS), $(addprefix $(CARDS_TEX_DIR)/, $(set))) +SETS_BUILDDIRS := $(foreach set, $(SETS), $(addprefix $(BUILDDIR)/, $(set))) -MAKEFILE_LIST = Makefile +# Add yml dirs to VPATH, the place make will look for the source files +VPATH = $(SETS_SOURCEDIRS) $(SETS_TEXDIRS) -ASSETS_PATH = ../assets -PDFLATEX_ENV := TEXINPUTS=".:$(ASSETS_PATH):" +# Create a list of yaml card definitions +CARDS_YAML := $(foreach dir,$(SETS_SOURCEDIRS),$(wildcard $(dir)/*.yml)) +CARDS_TEX := $(subst $(CARDS_YML_DIR),$(CARDS_TEX_DIR),$(CARDS_YAML:.yml=.tex)) +CARDS_PDF := $(subst $(CARDS_YML_DIR),$(BUILDDIR),$(CARDS_YAML:.yml=.pdf)) +CARDS_PNG = $(CARDS_PDF:.pdf=.png) -all: $(PDF_DIR)/print.pdf $(PDFS_PREFIXED) $(CARD_PNGS_PREFIXED) +VERBOSE = @ -$(PDF_DIR)/print.pdf: print.tex $(CARD_SOURCES) $(COMMON_TEX_FILES) $(MAKEFILE_LIST) - @echo "building › › $@" - @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi - $(VERBOSE) $(PDFLATEX_ENV) $(PDFLATEX) --output-directory $(PDF_DIR) print.tex +MAKEFILE_LIST = Makefile -$(PDF_DIR)/cards.pdf: $(PDFS_PREFIXED) $(MAKEFILE_LIST) +# Define the functions that will generate each rule +define generatePdfRules +$(1)/%.pdf: %.tex $(COMMON_TEX_FILES) $(MAKEFILE_LIST) + @echo building $$@ + @if test \( ! \( -d $$(@D) \) \) ;then mkdir -p $$(@D);fi + $(VERBOSE)$(PDFLATEX_ENV) $(PDFLATEX) --output-directory $$(@D) $$< +endef + +define generateTexRules +$(1)/%.tex: %.yml + @echo building $$@ + @if test \( ! \( -d $$(@D) \) \) ;then mkdir -p $$(@D);fi + $(VERBOSE)$(GENERATE_CARD) --latex-root $(LATEX_ROOT) $$< +endef + +# Generate tex rules +$(foreach texdir, $(SETS_TEXDIRS), $(eval $(call generateTexRules, $(texdir)))) + +# Generate pdf rules +$(foreach pdfdir, $(SETS_BUILDDIRS), $(eval $(call generatePdfRules, $(pdfdir)))) + +all: cards-tex cards-pdf cards-png +cards-tex: $(CARDS_TEX) +cards-pdf: $(CARDS_PDF) +cards-png: $(CARDS_PNG) + +$(BUILDDIR)/cards.pdf: $(CARDS_PDF) $(MAKEFILE_LIST) @echo "building › › $@" @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi - $(VERBOSE) $(PDFUNITE) $(PDFS_PREFIXED) $@ - -$(PDF_DIR)/%.pdf : $(CARDS_DIR)/%.tex $(COMMON_TEX_FILES) $(MAKEFILE_LIST) - @echo "card › $@" - @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi - $(VERBOSE) $(PDFLATEX_ENV) $(PDFLATEX) --output-directory $(PDF_DIR) $(CARDS_DIR)/$*.tex + $(VERBOSE)$(PDFUNITE) $(CARDS_PDF) $@ -$(PDF_DIR)/%.pdf : $(SETS_DIR)/%.tex $(CARD_SOURCES) $(COMMON_TEX_FILES) $(MAKEFILE_LIST) - @echo "card › $@" - @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi - $(VERBOSE) $(PDFLATEX_ENV) $(PDFLATEX) --output-directory $(PDF_DIR) $^ - -$(PDF_DIR)/%.png : $(PDF_DIR)/%.pdf $(MAKEFILE_LIST) +%.png: %.pdf $(MAKEFILE_LIST) @echo "png › $@" @if test \( ! \( -d $(@D) \) \) ;then mkdir -p $(@D);fi - $(VERBOSE) $(PDFTOPPM) $(PDFTOPPM_FLAGS) $(PDF_DIR)/$*.pdf $(PDF_DIR)/$* + $(VERBOSE)$(PDFTOPPM) $(PDFTOPPM_FLAGS) $< $* clean: - rm -rf build/ + rm -rf $(BUILDDIR) + +clean-all: clean + rm -rf $(CARDS_TEX_DIR) diff --git a/latex/cards/advisor.tex b/latex/cards/advisor.tex deleted file mode 100644 index d2fe6354..00000000 --- a/latex/cards/advisor.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Advisor} -\cardbuycost{10} -\cardsplitcontent{Health: 1\\ Movement: 2}{\faRedo: Draw 1 card. You may exile 1 card from your hand} -\cardplaycost{2}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/angry_squid.tex b/latex/cards/angry_squid.tex deleted file mode 100644 index 4eb74177..00000000 --- a/latex/cards/angry_squid.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Angry Squid} -\cardbuycost{7} -\cardcontent{AI: Aggressive\\ Health: 1\\ Movement: 2 swimming\\ Attack: 1 Range 2} -\cardplaycost{2}\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/archer.tex b/latex/cards/archer.tex deleted file mode 100644 index d5acae5a..00000000 --- a/latex/cards/archer.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Archer} -\cardbuycost{5} -\cardcontent{Health: 2\\ Movement: 2\\ Attack: 1 Range 2} -\cardplaycost{1}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/barge.tex b/latex/cards/barge.tex deleted file mode 100644 index eb82ae5c..00000000 --- a/latex/cards/barge.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Barge} -\cardbuycost{5} -\cardsplitcontent{Health: 3\\ Movement: 3 swimming}{Crew 6} -\cardplaycost{1}\cardmodule{nautics} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/base.tex b/latex/cards/base.tex deleted file mode 100644 index c7231e76..00000000 --- a/latex/cards/base.tex +++ /dev/null @@ -1,50 +0,0 @@ -\documentclass[a4paper,landscape]{article} - -% Ränder des Dokuments anpassen -\usepackage[margin=6mm,top=5mm]{geometry} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\usepackage{standalone} - -\begin{document} -\begin{center} -\pagestyle{empty} -\input{cards/sword.tex} -\hspace{5mm} -\input{cards/great_sword.tex} -\hspace{5mm} -\input{cards/shield.tex} -\hspace{5mm} -\input{cards/tower_shield.tex} -\vspace{5mm} - -\input{cards/archer.tex} -\hspace{5mm} -\input{cards/knight.tex} -\hspace{5mm} -\input{cards/pikeman.tex} -\hspace{5mm} -\input{cards/cavalry.tex} -\vspace{5mm} - -\input{cards/tax_collector.tex} -\hspace{5mm} -\input{cards/pioneer.tex} -\hspace{5mm} -\input{cards/recruiter.tex} -\hspace{5mm} -\input{cards/missionary.tex} -\vspace{5mm} - -\input{cards/cavl._archer.tex} -\hspace{5mm} - -\end{center} -\end{document} - diff --git a/latex/cards/base/advisor.tex b/latex/cards/base/advisor.tex new file mode 100644 index 00000000..73b40ed9 --- /dev/null +++ b/latex/cards/base/advisor.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Advisor} +\cardbuycost{10} +\cardsplitcontent{Health: 1\\Movement: 2}{\faRedo: Draw 1 card. You may exile 1 card from your hand} +\cardplaycost{2}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/base/archer.tex b/latex/cards/base/archer.tex new file mode 100644 index 00000000..a558454a --- /dev/null +++ b/latex/cards/base/archer.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Archer} +\cardbuycost{5} +\cardcontent{Health: 2\\Movement: 2\\Attack: 1 Range 2} +\cardplaycost{1}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/base/cavalry.tex b/latex/cards/base/cavalry.tex new file mode 100644 index 00000000..ead57ad0 --- /dev/null +++ b/latex/cards/base/cavalry.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Cavalry} +\cardbuycost{5} +\cardcontent{Health: 1\\Movement: 3\\Attack: 2} +\cardplaycost{2}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/base/cavalry_archer.tex b/latex/cards/base/cavalry_archer.tex new file mode 100644 index 00000000..12dc9629 --- /dev/null +++ b/latex/cards/base/cavalry_archer.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Cavalry Archer} +\cardbuycost{10} +\cardcontent{Health: 1\\Movement: 3\\Attack: 1 Range 2} +\cardplaycost{2}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/base/fighter.tex b/latex/cards/base/fighter.tex new file mode 100644 index 00000000..e92ce314 --- /dev/null +++ b/latex/cards/base/fighter.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Fighter} +\cardbuycost{7} +\cardsplitcontent{Health: 2\\Movement: 2\\Attack: 1}{One additional attack action} +\cardplaycost{1}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/great_sword.tex b/latex/cards/base/great_sword.tex index 1f4fcfca..a791203e 100644 --- a/latex/cards/great_sword.tex +++ b/latex/cards/base/great_sword.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/base/knight.tex b/latex/cards/base/knight.tex new file mode 100644 index 00000000..8bce19de --- /dev/null +++ b/latex/cards/base/knight.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Knight} +\cardbuycost{7} +\cardsplitcontent{Health: 2\\Movement: 2\\Attack: 2}{+ 1 Armor} +\cardplaycost{2}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/misinformation.tex b/latex/cards/base/misinformation.tex index e624df15..718b73ac 100644 --- a/latex/cards/misinformation.tex +++ b/latex/cards/base/misinformation.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -16,4 +10,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/base/missionary.tex b/latex/cards/base/missionary.tex new file mode 100644 index 00000000..d3f43f09 --- /dev/null +++ b/latex/cards/base/missionary.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Missionary} +\cardbuycost{10} +\cardsplitcontent{Health: 1\\Movement: 2}{\faRedo: Put two faith counters on target Unit. If there are more faith counters than the units buying cost you control target unit} +\cardplaycost{2}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/palisade.tex b/latex/cards/base/palisade.tex index 049c3f85..2c6c9c35 100644 --- a/latex/cards/palisade.tex +++ b/latex/cards/base/palisade.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/base/pikeman.tex b/latex/cards/base/pikeman.tex new file mode 100644 index 00000000..bb17dc7a --- /dev/null +++ b/latex/cards/base/pikeman.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Pikeman} +\cardbuycost{5} +\cardsplitcontent{Health: 2\\Movement: 1\\Attack: 1}{Range 2 against Units with Movement >= 3} +\cardplaycost{1}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/base/pioneer.tex b/latex/cards/base/pioneer.tex new file mode 100644 index 00000000..0964af43 --- /dev/null +++ b/latex/cards/base/pioneer.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Pioneer} +\cardbuycost{7} +\cardsplitcontent{Health: 5\\Movement: 2}{\faRedo: Neutralize adjacent tile or Artifact} +\cardplaycost{1}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/base/recruit.tex b/latex/cards/base/recruit.tex new file mode 100644 index 00000000..8b88a6c6 --- /dev/null +++ b/latex/cards/base/recruit.tex @@ -0,0 +1,11 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnitToken{Recruit} +\cardcontent{Health: 1\\Movement: 1\\Attack: 1} +\cardplaycost{0}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/base/recruiter.tex b/latex/cards/base/recruiter.tex new file mode 100644 index 00000000..d5f53693 --- /dev/null +++ b/latex/cards/base/recruiter.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Recruiter} +\cardbuycost{10} +\cardsplitcontent{Health: 2\\Movement: 2\\Attack: 1}{Allow Units to be played in Range 1\\ \vspace{0.2cm} \faRedo: Create Recruit token on adjacent tile} +\cardplaycost{1}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/shield.tex b/latex/cards/base/shield.tex index 015f695f..3d51c1bc 100644 --- a/latex/cards/shield.tex +++ b/latex/cards/base/shield.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/sword.tex b/latex/cards/base/sword.tex index 7773df30..f4b34e62 100644 --- a/latex/cards/sword.tex +++ b/latex/cards/base/sword.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/base/tax_collector.tex b/latex/cards/base/tax_collector.tex new file mode 100644 index 00000000..0989fecf --- /dev/null +++ b/latex/cards/base/tax_collector.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Tax Collector} +\cardbuycost{5} +\cardsplitcontent{Health: 1\\Movement: 2}{\faRedo: Get 2 additional Ressource} +\cardplaycost{1}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/tower_shield.tex b/latex/cards/base/tower_shield.tex index fdaf1be7..b1e1d401 100644 --- a/latex/cards/tower_shield.tex +++ b/latex/cards/base/tower_shield.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/base/wormtongue.tex b/latex/cards/base/wormtongue.tex new file mode 100644 index 00000000..73a7ed36 --- /dev/null +++ b/latex/cards/base/wormtongue.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Wormtongue} +\cardbuycost{10} +\cardsplitcontent{Health: 1\\Movement: 2}{\faRedo, 3: Add a Misinformation token to an opponents pile} +\cardplaycost{2}\cardmodule{base} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/captain.tex b/latex/cards/captain.tex deleted file mode 100644 index b7d9b0e6..00000000 --- a/latex/cards/captain.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Captain} -\cardbuycost{7} -\cardsplitcontent{Health: 1\\ Movement: 1\\ Attack: 1}{Other units in the same pile have no upkeep cost} -\cardplaycost{2}\cardmodule{nautics} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/cavalry.tex b/latex/cards/cavalry.tex deleted file mode 100644 index 729fcc77..00000000 --- a/latex/cards/cavalry.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Cavalry} -\cardbuycost{5} -\cardcontent{Health: 1\\ Movement: 3\\ Attack: 2} -\cardplaycost{2}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/cavl._archer.tex b/latex/cards/cavl._archer.tex deleted file mode 100644 index e004d367..00000000 --- a/latex/cards/cavl._archer.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Cavl. Archer} -\cardbuycost{10} -\cardcontent{Health: 1\\ Movement: 3\\ Attack: 1 Range 2} -\cardplaycost{2}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/chachalot.tex b/latex/cards/chachalot.tex deleted file mode 100644 index ae94e946..00000000 --- a/latex/cards/chachalot.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Chachalot} -\cardbuycost{10} -\cardsplitcontent{AI: Wandering\\ Health: 2\\ Movement: 2 swimming\\ Attack: 2}{+ 1 Armor} -\cardplaycost{2}\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/clownfish.tex b/latex/cards/clownfish.tex deleted file mode 100644 index dcb82f1e..00000000 --- a/latex/cards/clownfish.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Clownfish} -\cardbuycost{10} -\cardsplitcontent{AI: Shy\\ Health: 1\\ Movement: 2 swimming}{\faRedo: Get 4 additional Ressource} -\cardplaycost{2}\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/dolphin.tex b/latex/cards/dolphin.tex deleted file mode 100644 index e687d623..00000000 --- a/latex/cards/dolphin.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Dolphin} -\cardbuycost{7} -\cardsplitcontent{AI: Supportive\\ Health: 2\\ Movement: 2}{\faRedo: Give random Unit in range 1 random buff} -\cardplaycost{1}\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/armor.tex b/latex/cards/equipments/armor.tex index 5cb37056..0a32f9ca 100644 --- a/latex/cards/armor.tex +++ b/latex/cards/equipments/armor.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/banner.tex b/latex/cards/equipments/banner.tex index 677c82ef..8baa86a1 100644 --- a/latex/cards/banner.tex +++ b/latex/cards/equipments/banner.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/cloak.tex b/latex/cards/equipments/cloak.tex index 77d72ee2..329b6e56 100644 --- a/latex/cards/cloak.tex +++ b/latex/cards/equipments/cloak.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/gear.tex b/latex/cards/equipments/gear.tex index 36e4ae8e..be937384 100644 --- a/latex/cards/gear.tex +++ b/latex/cards/equipments/gear.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/mace.tex b/latex/cards/equipments/mace.tex index e400ca34..41859143 100644 --- a/latex/cards/mace.tex +++ b/latex/cards/equipments/mace.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/plate_armor.tex b/latex/cards/equipments/plate_armor.tex index b8252f41..284c7592 100644 --- a/latex/cards/plate_armor.tex +++ b/latex/cards/equipments/plate_armor.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/poisoned_dagger.tex b/latex/cards/equipments/poisoned_dagger.tex index 1e39fcd6..c584dd27 100644 --- a/latex/cards/poisoned_dagger.tex +++ b/latex/cards/equipments/poisoned_dagger.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/reclaim!.tex b/latex/cards/equipments/reclaim!.tex index 628b3309..3708183b 100644 --- a/latex/cards/reclaim!.tex +++ b/latex/cards/equipments/reclaim!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/relic.tex b/latex/cards/equipments/relic.tex index 7c3dd250..68f1342c 100644 --- a/latex/cards/relic.tex +++ b/latex/cards/equipments/relic.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/shatter!.tex b/latex/cards/equipments/shatter!.tex index fd3c58b6..87a9de27 100644 --- a/latex/cards/shatter!.tex +++ b/latex/cards/equipments/shatter!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/equipments/smith.tex b/latex/cards/equipments/smith.tex new file mode 100644 index 00000000..92b7cb12 --- /dev/null +++ b/latex/cards/equipments/smith.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Smith} +\cardbuycost{10} +\cardsplitcontent{Health: 1\\Movement: 2}{\faRedo, X: Create Copy of artifact with buy cost = X in range 1 on empty tile in range 1} +\cardplaycost{2}\cardmodule{equipments} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/spear.tex b/latex/cards/equipments/spear.tex index cda86b4c..cc2f81bc 100644 --- a/latex/cards/spear.tex +++ b/latex/cards/equipments/spear.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/farmer.tex b/latex/cards/farmer.tex deleted file mode 100644 index e9a33023..00000000 --- a/latex/cards/farmer.tex +++ /dev/null @@ -1,18 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Farmer} -\cardcontent{Health: 1\\ Movement: 1\\ Attack: 1} -\cardplaycost{1}\cardmodule{} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/fighter.tex b/latex/cards/fighter.tex deleted file mode 100644 index 855cdd0a..00000000 --- a/latex/cards/fighter.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Fighter} -\cardbuycost{7} -\cardsplitcontent{Health: 2\\ Movement: 2\\ Attack: 1}{One additional attack action} -\cardplaycost{1}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/fish_trap.tex b/latex/cards/fish_trap.tex deleted file mode 100644 index 2c8231b8..00000000 --- a/latex/cards/fish_trap.tex +++ /dev/null @@ -1,18 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeArtifactToken{Fish Trap} -\cardcontent{Adjacent Fisher have \\ \faRedo: Gain 2 Resource} -\cardmodule{nautics} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/fisher.tex b/latex/cards/fisher.tex deleted file mode 100644 index ead0fb27..00000000 --- a/latex/cards/fisher.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Fisher} -\cardbuycost{5} -\cardsplitcontent{Health: 2\\ Movement: 2 swimming}{Crew 2\\ \vspace{0.2cm} \faRedo: Create fish trap token on adjacent water tile} -\cardplaycost{1}\cardmodule{nautics} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/frost_pylon.tex b/latex/cards/frost_pylon.tex deleted file mode 100644 index 54422837..00000000 --- a/latex/cards/frost_pylon.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeArtifact{Frost Pylon} -\cardbuycost{5} -\cardcontent{Enemy units in range 1 can't activate abilities except: "\\faRedo: put a crack counter on Frost Pylon". If there are three or more crack counter on Frost Pylon destroy it. Frots Pylon can be played next to a random enemy unit.} -\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/galley.tex b/latex/cards/galley.tex deleted file mode 100644 index 55e26948..00000000 --- a/latex/cards/galley.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Galley} -\cardbuycost{7} -\cardsplitcontent{Health: 4\\ Movement: 3 swimming\\ Attack: 1 range 2}{Crew 3} -\cardplaycost{1}\cardmodule{nautics} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/ice_berg.tex b/latex/cards/ice_berg.tex deleted file mode 100644 index dedb8303..00000000 --- a/latex/cards/ice_berg.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeArtifact{Ice Berg} -\cardcontent{Solid 3} -\cardplaycost{3} -\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/king.tex b/latex/cards/king.tex deleted file mode 100644 index ddc379d5..00000000 --- a/latex/cards/king.tex +++ /dev/null @@ -1,18 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnitToken{King} -\cardsplitcontent{Health: 5\\ Movement: 1\\ Attack: 1}{5 Resource: +shroud until end of turn. \\ Protection from Die!} -\cardplaycost{0}\cardmodule{} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/knight.tex b/latex/cards/knight.tex deleted file mode 100644 index 20ad1601..00000000 --- a/latex/cards/knight.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Knight} -\cardbuycost{7} -\cardsplitcontent{Health: 2\\ Movement: 2\\ Attack: 2}{+ 1 Armor} -\cardplaycost{2}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/kraken/angry_squid.tex b/latex/cards/kraken/angry_squid.tex new file mode 100644 index 00000000..4b79bd2f --- /dev/null +++ b/latex/cards/kraken/angry_squid.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Angry Squid} +\cardbuycost{7} +\cardcontent{AI: Aggressive\\Health: 1\\Movement: 2 swimming\\Attack: 1 Range 2} +\cardplaycost{2}\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/kraken/chachalot.tex b/latex/cards/kraken/chachalot.tex new file mode 100644 index 00000000..8f980846 --- /dev/null +++ b/latex/cards/kraken/chachalot.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Chachalot} +\cardbuycost{10} +\cardsplitcontent{AI: Wandering\\Health: 2\\Movement: 2 swimming\\Attack: 2}{+ 1 Armor} +\cardplaycost{2}\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/kraken/clownfish.tex b/latex/cards/kraken/clownfish.tex new file mode 100644 index 00000000..913a430e --- /dev/null +++ b/latex/cards/kraken/clownfish.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Clownfish} +\cardbuycost{10} +\cardsplitcontent{AI: Shy\\Health: 1\\Movement: 2 swimming}{\faRedo: Get 4 additional Ressource} +\cardplaycost{2}\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/kraken/dolphin.tex b/latex/cards/kraken/dolphin.tex new file mode 100644 index 00000000..ef8e5de0 --- /dev/null +++ b/latex/cards/kraken/dolphin.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Dolphin} +\cardbuycost{7} +\cardsplitcontent{AI: Supportive\\Health: 2\\Movement: 2}{\faRedo: Give random Unit in range 1 random buff} +\cardplaycost{1}\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/kraken/frost_pylon.tex b/latex/cards/kraken/frost_pylon.tex new file mode 100644 index 00000000..0f25ac79 --- /dev/null +++ b/latex/cards/kraken/frost_pylon.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeArtifact{Frost Pylon} +\cardbuycost{5} +\cardcontent{Enemy units in range 1 can't activate abilities except: \enquote{~\faRedo: put a crack counter on Frost Pylon}. \\ \vspace{0.3cm} If there are three or more crack counter on Frost Pylon destroy it. Frost Pylon can be played next to a random enemy unit} +\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/kraken/gigantic_hail.tex b/latex/cards/kraken/gigantic_hail.tex new file mode 100644 index 00000000..433d264d --- /dev/null +++ b/latex/cards/kraken/gigantic_hail.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeSpell{Gigantic Hail} +\cardcontent{Place an Ice Berg token on a random empty tile} +\cardplaycost{3} +\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/kraken/ice_berg.tex b/latex/cards/kraken/ice_berg.tex new file mode 100644 index 00000000..b9aff050 --- /dev/null +++ b/latex/cards/kraken/ice_berg.tex @@ -0,0 +1,11 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeArtifactToken{Ice Berg} +\cardcontent{Solid 3} +\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/kraken/sailfish.tex b/latex/cards/kraken/sailfish.tex new file mode 100644 index 00000000..4dfd1fab --- /dev/null +++ b/latex/cards/kraken/sailfish.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Sailfish} +\cardbuycost{7} +\cardcontent{AI: Aggressive\\Health: 1\\Movement: 3\\Attack: 1} +\cardplaycost{1}\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/suprise.tex b/latex/cards/kraken/suprise.tex index ff8dc5e5..bced6c08 100644 --- a/latex/cards/suprise.tex +++ b/latex/cards/kraken/suprise.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -16,4 +10,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/tentacle_slap.tex b/latex/cards/kraken/tentacle_slap.tex index 24292cb9..cb4b9463 100644 --- a/latex/cards/tentacle_slap.tex +++ b/latex/cards/kraken/tentacle_slap.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -16,4 +10,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/kraken/the_kraken.tex b/latex/cards/kraken/the_kraken.tex new file mode 100644 index 00000000..ab6d5dc3 --- /dev/null +++ b/latex/cards/kraken/the_kraken.tex @@ -0,0 +1,11 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{The Kraken} +\cardcontent{Health: 5\\Attack: 1} +\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/tides_change.tex b/latex/cards/kraken/tides_change.tex index 4a82d49e..9d44f674 100644 --- a/latex/cards/tides_change.tex +++ b/latex/cards/kraken/tides_change.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -16,4 +10,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/kraken/unholy_cannonball.tex b/latex/cards/kraken/unholy_cannonball.tex new file mode 100644 index 00000000..07cb51cb --- /dev/null +++ b/latex/cards/kraken/unholy_cannonball.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeSpell{Unholy Cannonball} +\cardcontent{If no enemy Units are in range~2 of The Kraken gain 5~ressource and draw a card. \\ \vspace{0.3cm} Otherwise put a fear counter on all enemy Units in range~2 of The Kraken} +\cardplaycost{5} +\cardmodule{kraken} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/action!.tex b/latex/cards/magic/action!.tex index 7f855587..53cc73c7 100644 --- a/latex/cards/action!.tex +++ b/latex/cards/magic/action!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/appear!.tex b/latex/cards/magic/appear!.tex index 4d4a41f7..994d9ec4 100644 --- a/latex/cards/appear!.tex +++ b/latex/cards/magic/appear!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/attack!.tex b/latex/cards/magic/attack!.tex index d0f44924..20707bcc 100644 --- a/latex/cards/attack!.tex +++ b/latex/cards/magic/attack!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/catalyst.tex b/latex/cards/magic/catalyst.tex index b9037954..36fb937e 100644 --- a/latex/cards/catalyst.tex +++ b/latex/cards/magic/catalyst.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/clone!.tex b/latex/cards/magic/clone!.tex index 5f03c662..139147b6 100644 --- a/latex/cards/clone!.tex +++ b/latex/cards/magic/clone!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/defense!.tex b/latex/cards/magic/defense!.tex index e242c9f4..c0619ca9 100644 --- a/latex/cards/defense!.tex +++ b/latex/cards/magic/defense!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/die!.tex b/latex/cards/magic/die!.tex index fab8c909..8674a709 100644 --- a/latex/cards/die!.tex +++ b/latex/cards/magic/die!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/heal!.tex b/latex/cards/magic/heal!.tex index 4b7fab6a..65d46a3d 100644 --- a/latex/cards/heal!.tex +++ b/latex/cards/magic/heal!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/isolate!.tex b/latex/cards/magic/isolate!.tex index ac7ffcf5..88468866 100644 --- a/latex/cards/isolate!.tex +++ b/latex/cards/magic/isolate!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/mine!.tex b/latex/cards/magic/mine!.tex index 7485ea53..e585603c 100644 --- a/latex/cards/mine!.tex +++ b/latex/cards/magic/mine!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/more!.tex b/latex/cards/magic/more!.tex index 77b6559a..1168aac6 100644 --- a/latex/cards/more!.tex +++ b/latex/cards/magic/more!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/no!.tex b/latex/cards/magic/no!.tex index a887d472..3719eab3 100644 --- a/latex/cards/no!.tex +++ b/latex/cards/magic/no!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/pierce!.tex b/latex/cards/magic/pierce!.tex index bed00ace..6d3a8f93 100644 --- a/latex/cards/pierce!.tex +++ b/latex/cards/magic/pierce!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/ritual!.tex b/latex/cards/magic/ritual!.tex index 434c658e..217386fb 100644 --- a/latex/cards/ritual!.tex +++ b/latex/cards/magic/ritual!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/rush!.tex b/latex/cards/magic/rush!.tex index cf143c58..b5eb53f3 100644 --- a/latex/cards/rush!.tex +++ b/latex/cards/magic/rush!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/select!.tex b/latex/cards/magic/select!.tex index 5cfbad25..37d8ffad 100644 --- a/latex/cards/select!.tex +++ b/latex/cards/magic/select!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/shroud!.tex b/latex/cards/magic/shroud!.tex index c6b2ca7c..e1e9eade 100644 --- a/latex/cards/shroud!.tex +++ b/latex/cards/magic/shroud!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/stumble!.tex b/latex/cards/magic/stumble!.tex index ad62b63a..9a8766df 100644 --- a/latex/cards/stumble!.tex +++ b/latex/cards/magic/stumble!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/switch!.tex b/latex/cards/magic/switch!.tex index d2dfefb5..491a5115 100644 --- a/latex/cards/switch!.tex +++ b/latex/cards/magic/switch!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/transmute!.tex b/latex/cards/magic/transmute!.tex index 38c05db7..b18d00c5 100644 --- a/latex/cards/transmute!.tex +++ b/latex/cards/magic/transmute!.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -17,4 +11,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/misc/farmer.tex b/latex/cards/misc/farmer.tex new file mode 100644 index 00000000..7e9ac9c2 --- /dev/null +++ b/latex/cards/misc/farmer.tex @@ -0,0 +1,11 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Farmer} +\cardcontent{Health: 1\\Movement: 1\\Attack: 1} +\cardplaycost{1}\cardmodule{} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/misc/king.tex b/latex/cards/misc/king.tex new file mode 100644 index 00000000..7e95025a --- /dev/null +++ b/latex/cards/misc/king.tex @@ -0,0 +1,11 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnitToken{King} +\cardsplitcontent{Health: 5\\Movement: 1\\Attack: 1}{5 Resource: +shroud until end of turn. \ Protection from Die!} +\cardplaycost{0}\cardmodule{} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/stick_of_victory.tex b/latex/cards/misc/stick_of_victory.tex index 6586d237..5bd28a96 100644 --- a/latex/cards/stick_of_victory.tex +++ b/latex/cards/misc/stick_of_victory.tex @@ -1,11 +1,5 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} +\documentclass{standalone} +\input{common.tex} \begin{document} \begin{tikzpicture} @@ -15,4 +9,3 @@ \cardborder \end{tikzpicture} \end{document} - diff --git a/latex/cards/missionary.tex b/latex/cards/missionary.tex deleted file mode 100644 index 98b8a708..00000000 --- a/latex/cards/missionary.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Missionary} -\cardbuycost{10} -\cardsplitcontent{Health: 1\\ Movement: 2}{\faRedo: Put two faith counters on target Unit. If there are more faith counters than the units buying cost you control target unit} -\cardplaycost{2}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/nautics/barge.tex b/latex/cards/nautics/barge.tex new file mode 100644 index 00000000..fd00b98a --- /dev/null +++ b/latex/cards/nautics/barge.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Barge} +\cardbuycost{5} +\cardsplitcontent{Health: 3\\Movement: 3 swimming}{Crew 6} +\cardplaycost{1}\cardmodule{nautics} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/nautics/captain.tex b/latex/cards/nautics/captain.tex new file mode 100644 index 00000000..802e7d99 --- /dev/null +++ b/latex/cards/nautics/captain.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Captain} +\cardbuycost{7} +\cardsplitcontent{Health: 1\\Movement: 1\\Attack: 1}{Other units in the same pile have no upkeep cost} +\cardplaycost{2}\cardmodule{nautics} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/nautics/fish_trap.tex b/latex/cards/nautics/fish_trap.tex new file mode 100644 index 00000000..7e616a7a --- /dev/null +++ b/latex/cards/nautics/fish_trap.tex @@ -0,0 +1,11 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeArtifactToken{Fish Trap} +\cardcontent{Adjacent Fisher have \\ \enquote{~\faRedo: Gain 2 Resource}} +\cardmodule{nautics} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/nautics/fisher.tex b/latex/cards/nautics/fisher.tex new file mode 100644 index 00000000..01a389df --- /dev/null +++ b/latex/cards/nautics/fisher.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Fisher} +\cardbuycost{5} +\cardsplitcontent{Health: 2\\Movement: 2 swimming}{Crew 2\\ \vspace{0.2cm} \faRedo: Create fish trap token on adjacent water tile} +\cardplaycost{1}\cardmodule{nautics} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/nautics/galley.tex b/latex/cards/nautics/galley.tex new file mode 100644 index 00000000..c58ad617 --- /dev/null +++ b/latex/cards/nautics/galley.tex @@ -0,0 +1,12 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Galley} +\cardbuycost{7} +\cardsplitcontent{Health: 4\\Movement: 3 swimming\\Attack: 1 range 2}{Crew 3} +\cardplaycost{1}\cardmodule{nautics} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/nautics/sailor.tex b/latex/cards/nautics/sailor.tex new file mode 100644 index 00000000..dc83a664 --- /dev/null +++ b/latex/cards/nautics/sailor.tex @@ -0,0 +1,11 @@ +\documentclass{standalone} +\input{common.tex} + +\begin{document} +\begin{tikzpicture} +\cardtypeUnit{Sailor} +\cardsplitcontent{Health: 1\\Movement: 1\\Attack: 1}{A crewed unit gets +1 movement while swimming} +\cardplaycost{1}\cardmodule{nautics} +\cardborder +\end{tikzpicture} +\end{document} diff --git a/latex/cards/pikeman.tex b/latex/cards/pikeman.tex deleted file mode 100644 index 01159416..00000000 --- a/latex/cards/pikeman.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Pikeman} -\cardbuycost{5} -\cardsplitcontent{Health: 2\\ Movement: 1\\ Attack: 1}{Range 2 against Units with Movement >= 3} -\cardplaycost{1}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/pioneer.tex b/latex/cards/pioneer.tex deleted file mode 100644 index e455c5c2..00000000 --- a/latex/cards/pioneer.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Pioneer} -\cardbuycost{7} -\cardsplitcontent{Health: 5\\ Movement: 2}{\faRedo: Neutralize adjacent tile or Artifact} -\cardplaycost{1}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/players_turn.tex b/latex/cards/players_turn.tex deleted file mode 100644 index fb822c3b..00000000 --- a/latex/cards/players_turn.tex +++ /dev/null @@ -1,52 +0,0 @@ -\documentclass[]{standalone} - -\usepackage{enumitem} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - - -\begin{document} -\begin{tikzpicture} - -\pgfmathsetmacro{\textWidth}{(\cardwidth-\strippadding-\textpadding-0.5)*1cm} -\pgfmathsetmacro{\textLeft}{(\contentLeft-\stripwidth)} - -\begin{scope}[even odd rule] -% Define a clipping path. All paths outside shapeCard will -% be cut because the even odd rule is set. - \clip[cardcorners] \shapeCard; -% Fill shapeLeftStripLong and shapeLeftStripShort. -% Since the even odd rule is set, only the card will be filled. - \fill[strip, tokenbg] \shapeLeftStripShort; -\end{scope} - -\node at (\strippadding+0.5*\stripwidth,\cardheight-\strippadding-\strippadding-0.37) {\color{white}\Large{?}}; -\cardtitle{Player's Turn} - -\node(content)[above right, text width=\textWidth] at (\textLeft, \contentBottom) { - {\small - \begin{enumerate}[leftmargin=5pt] - \setlength{\itemsep}{-1pt} - \item Mix discard pile into empty deck - \item Draw till you have three cards - \item Upkeep - \begin{enumerate}[leftmargin=5pt] - \setlength{\itemsep}{-1pt} - \item Gain Ressource - \item Pay units upkeep cost - \end{enumerate} - \item Actions - \item Buy a card - \end{enumerate} - } -}; - -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/recruit.tex b/latex/cards/recruit.tex deleted file mode 100644 index 14eaa349..00000000 --- a/latex/cards/recruit.tex +++ /dev/null @@ -1,18 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnitToken{Recruit} -\cardcontent{Health: 1\\ Movement: 1\\ Attack: 1} -\cardplaycost{0}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/recruiter.tex b/latex/cards/recruiter.tex deleted file mode 100644 index 1a183f63..00000000 --- a/latex/cards/recruiter.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Recruiter} -\cardbuycost{10} -\cardsplitcontent{Health: 2\\ Movement: 2\\ Attack: 1}{Allow Units to be played in Range 1\\ \vspace{0.2cm} \faRedo: Create Recruit token on adjacent tile} -\cardplaycost{1}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/sailfish.tex b/latex/cards/sailfish.tex deleted file mode 100644 index e174c7c6..00000000 --- a/latex/cards/sailfish.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Sailfish} -\cardbuycost{7} -\cardcontent{AI: Aggressive\\ Health: 1\\ Movement: 3\\ Attack: 1} -\cardplaycost{1}\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/sailor.tex b/latex/cards/sailor.tex deleted file mode 100644 index 5c4b0a0f..00000000 --- a/latex/cards/sailor.tex +++ /dev/null @@ -1,18 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Sailor} -\cardsplitcontent{Health: 1\\ Movement: 1\\ Attack: 1}{A crewed unit gets +1 movement while swimming} -\cardplaycost{1}\cardmodule{nautics} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/smith.tex b/latex/cards/smith.tex deleted file mode 100644 index 5af8b486..00000000 --- a/latex/cards/smith.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Smith} -\cardbuycost{10} -\cardsplitcontent{Health: 1\\ Movement: 2}{\faRedo: Pay X: Create Copy of artifact with buy cost = X in range 1 on empty tile in range 1} -\cardplaycost{2}\cardmodule{equipments} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/tax_collector.tex b/latex/cards/tax_collector.tex deleted file mode 100644 index 4b8f9414..00000000 --- a/latex/cards/tax_collector.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Tax Collector} -\cardbuycost{5} -\cardsplitcontent{Health: 1\\ Movement: 2}{\faRedo: Get 2 additional Ressource} -\cardplaycost{1}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/the_kraken.tex b/latex/cards/the_kraken.tex deleted file mode 100644 index 21467fe7..00000000 --- a/latex/cards/the_kraken.tex +++ /dev/null @@ -1,18 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{The Kraken} -\cardcontent{Health: 5\\ Attack: 1} -\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/unholy_cannonball.tex b/latex/cards/unholy_cannonball.tex deleted file mode 100644 index eb30a1c6..00000000 --- a/latex/cards/unholy_cannonball.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeSpell{Unholy Cannonball} -\cardcontent{If no enemy Units are in range 2 of The Kraken gains 5 ressource and draws a card. \\ Otherwise put a fear counter on all enemy Units in range 2} -\cardplaycost{5} -\cardmodule{kraken} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/cards/wormtongue.tex b/latex/cards/wormtongue.tex deleted file mode 100644 index 0c011b70..00000000 --- a/latex/cards/wormtongue.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass[]{standalone} - -% Pakete dazuladen -\input{libs.tex} -% Farbdefinitionen laden -\input{colors.tex} -% \card-Commands laden -\input{tikzcards.tex} - -\begin{document} -\begin{tikzpicture} -\cardtypeUnit{Wormtongue} -\cardbuycost{10} -\cardsplitcontent{Health: 1\\ Movement: 2}{\faRedo: 3: Add a Misinformation token to an opponents pile} -\cardplaycost{2}\cardmodule{base} -\cardborder -\end{tikzpicture} -\end{document} - diff --git a/latex/common.tex b/latex/common.tex new file mode 100644 index 00000000..552c0686 --- /dev/null +++ b/latex/common.tex @@ -0,0 +1,3 @@ +\input{libs.tex} +\input{colors.tex} +\input{tikzcards.tex} diff --git a/latex/libs.tex b/latex/libs.tex index 41529443..43ad3456 100644 --- a/latex/libs.tex +++ b/latex/libs.tex @@ -20,6 +20,8 @@ \usepackage{xparse} % for getnodedim macro +\usepackage{csquotes} + % symbols \usepackage{fourier-orns} % \usepackage{amssymb} % Rsh diff --git a/scripts/generate_card.py b/scripts/generate_card.py new file mode 100755 index 00000000..c11c039b --- /dev/null +++ b/scripts/generate_card.py @@ -0,0 +1,165 @@ +#!/usr/bin/env python3 +import argparse +import pathlib +import os +from typing import MutableMapping +import yaml + +CARD_TEMPLATE = \ +"""\\documentclass{{standalone}} +\\input{{common.tex}} + +\\begin{{document}} +\\begin{{tikzpicture}} +{0} +\\cardborder +\\end{{tikzpicture}} +\\end{{document}}""" + +SET_SYMBOLS = { + 'base': 'base', + 'magic': 'magic', + 'equipments': 'equipments', + 'nautics': 'nautics', + 'misc': '', + 'kraken': 'kraken' +} + +LATEX_ROOT = pathlib.Path(os.getcwd()) +ASSETS_DIR = LATEX_ROOT / '../assets' +CARDS_DIR = LATEX_ROOT / 'cards' + +def file_for_card(card_name: str) -> pathlib.Path: + """Return the corresponding latex file name for a card""" + return pathlib.Path(f'{card_name.lower().replace(" ", "_")}.tex') + +def get_latex_field(card: MutableMapping, field: str) -> str: + """Return the latex_ prefixed field from card or the field itself""" + latex_field = f'latex_{field}' + if latex_field in card: + return card[latex_field] + else: + return card[field] + +def generate_card(card: MutableMapping): + """Generate a standalone tikz picture with the card data""" + card_content = "" + + card_file = file_for_card(card['name']) + + for ext in ['.jpg', '.png']: + image_file = ASSETS_DIR / card_file.with_suffix(ext) + if image_file.exists(): + card_content += f'\\cardbackground{{{image_file.name}}}\n' + break + + card_content += f'\cardtype{card["type"].capitalize()}{"Token" if "token" in card else ""}{{{card["name"]}}}\n' + + if 'buy' in card: + card_content += f'\cardbuycost{{{card["buy"]}}}\n' + + if card['type'] == 'unit': + stats = [] + abilities = [] + if 'ai' in card: + stats.append(f'AI: {card["ai"]}') + + if 'health' in card: + stats.append(f'Health: {card["health"]}') + + if 'movement' in card: + stats.append(f'Movement: {card["movement"]}') + + attack = card.get('attack', None) + if attack: + # attack_sym = '\\faFistRaised' + # if "Range" in attack: + # attack_sym = '\\ding{246}' + stats.append(f'Attack: {attack}') + + if 'effect' in card: + abilities.append(get_latex_field(card, 'effect')) + + if 'full_action' in card: + if 'latex_full_action' in card: + abilities.append(f'{card["latex_full_action"]}') + else: + abilities.append(f'\\faRedo: {card["full_action"]}') + + stats_str = '\\\\'.join(stats) + ability_block = '\\\\ \\vspace{0.2cm} '.join(abilities) + if stats and abilities: + card_content += f'\cardsplitcontent{{{stats_str}}}{{{ability_block}}}' + elif stats: + card_content += f'\cardcontent{{{stats_str}}}' + + card_content += '\n' + + if 'upkeep' in card: + card_content += f'\cardplaycost{{{card["upkeep"]}}}' + + elif card['type'] in ['spell', 'artifact']: + effect = get_latex_field(card, 'effect') + print(card['effect']) + assert effect is not None + card_content += f'\cardcontent{{{effect}}}\n' + + elif card['type'] == 'equipment': + stats = f'Durability: {card["durability"]}' + effect = get_latex_field(card, 'effect') + card_content += f'\cardsplitcontent{{{stats}}}{{{effect}}}\n' + else: + print(f'WARNING: unknown card type {card["type"]}!') + + if 'play' in card: + card_content += f'\cardplaycost{{{card["play"]}}}\n' + + if card['set'] in SET_SYMBOLS: + card_content += f'\cardmodule{{{SET_SYMBOLS[card["set"]]}}}' + else: + print(f'WARNING unknown set: {card["set"]}') + + set_dir = CARDS_DIR / card['set'] + if not set_dir.exists(): + set_dir.mkdir(parents=True) + + with open(set_dir / card_file, 'w') as tex_file: + print(CARD_TEMPLATE.format(card_content), file=tex_file) + + +def main(): + """Generate one standalone tikz picture for each card in the input data""" + + parser = argparse.ArgumentParser(description='generate latex standalone cards') + parser.add_argument('data', help='yaml file or directory containing yaml files defining the cards to generate') + parser.add_argument('--latex-root', help='path to the latex root directory') + + args = parser.parse_args() + + if args.latex_root: + global LATEX_ROOT + LATEX_ROOT = pathlib.Path(args.latex_root) + global CARDS_DIR + CARDS_DIR = LATEX_ROOT / 'cards' + global ASSETS_DIR + ASSETS_DIR = LATEX_ROOT / '../assets' + + + data_files = [args.data] + data_path = pathlib.Path(args.data) + if data_path.is_dir(): + data_files = data_path.glob('*.yml') + card_set = data_path.stem + else: + card_set = data_path.parent.stem + + for f in data_files: + with open(f, 'r') as yaml_file: + card = yaml.full_load(yaml_file) + + card['set'] = card_set + generate_card(card) + + +if __name__ == '__main__': + main() diff --git a/scripts/generate_latex.py b/scripts/generate_latex.py deleted file mode 100755 index 71a99915..00000000 --- a/scripts/generate_latex.py +++ /dev/null @@ -1,194 +0,0 @@ -#!/usr/bin/env python3 -import argparse -import configparser -import pathlib -import os -from typing import MutableMapping - -COLLECTION_TEMPLATE = \ -"""\\documentclass[a4paper,landscape]{{article}} - -% Ränder des Dokuments anpassen -\\usepackage[margin=6mm,top=5mm]{{geometry}} - -% Pakete dazuladen -\\input{{libs.tex}} -% Farbdefinitionen laden -\\input{{colors.tex}} -% \card-Commands laden -\\input{{tikzcards.tex}} - -\\usepackage{{standalone}} - -\\begin{{document}} -\\begin{{center}} -\\pagestyle{{empty}} -{0} -\\end{{center}} -\\end{{document}} -""" - -CARD_TEMPLATE = \ -"""\\documentclass[]{{standalone}} - -% Pakete dazuladen -\\input{{libs.tex}} -% Farbdefinitionen laden -\\input{{colors.tex}} -% \card-Commands laden -\\input{{tikzcards.tex}} - -\\begin{{document}} -\\begin{{tikzpicture}} -{0} -\\cardborder -\\end{{tikzpicture}} -\\end{{document}} -""" - -SET_SYMBOLS = {'base': 'base', 'magic': 'magic', 'equipments': 'equipments', 'nautics': 'nautics', 'misc': '', 'kraken': 'kraken'} - -LATEX_ROOT = pathlib.Path(os.getcwd()) -ASSETS_DIR = LATEX_ROOT / '../assets' -CARDS_DIR = LATEX_ROOT / 'cards' - -def file_for_card(card_name: str) -> pathlib.Path: - """Return the corresponding latex file name for a card""" - return pathlib.Path(f'{card_name.lower().replace(" ", "_")}.tex') - -def generate_card(card_name: str, card: MutableMapping): - """Generate a standalone tikz picture with the card data""" - card_content = "" - - card_file = file_for_card(card_name) - - for ext in ['.jpg', '.png']: - image_file = ASSETS_DIR / card_file.with_suffix(ext) - if image_file.exists(): - card_content += f'\\cardbackground{{{image_file.name}}}\n' - break - - card_content += f'\cardtype{card["type"].capitalize()}{"Token" if "token" in card else ""}{{{card_name}}}\n' - # card_content += f'\cardtitle{{{card_name}}}\n' - - if 'buy' in card: - card_content += f'\cardbuycost{{{card["buy"]}}}\n' - - if card['type'] == 'unit': - stats = '' - if 'ai' in card: - stats += f'AI: {card["ai"]}' - - if 'health' in card: - if stats: - stats += '\\\\ ' - stats += f'Health: {card["health"]}' - - if 'movement' in card: - if stats: - stats += '\\\\ ' - stats += f'Movement: {card["movement"]}' - - attack = card.get('attack', None) - if attack: - attack_sym = '\\faFistRaised' - if "Range" in attack: - attack_sym = '\\ding{246}' - # stats += f'\\\\ {attack_sym}: {attack}' - if stats: - stats += '\\\\ ' - stats += f'Attack: {attack}' - - if 'effect' in card or 'full_action' in card: - ability_block = "" - - effect = card.get('effect', None) - if effect: - ability_block += f'{effect}' - - full_action = card.get('full_action', None) - if full_action: - if ability_block: - ability_block += '\\\\ \\vspace{0.2cm} ' - ability_block += f'\\faRedo: {full_action}' - - card_content += f'\cardsplitcontent{{{stats}}}{{{ability_block}}}' - elif stats: - card_content += f'\cardcontent{{{stats}}}' - - - card_content += '\n' - - if 'upkeep' in card: - card_content += f'\cardplaycost{{{card["upkeep"]}}}' - - elif card['type'] == 'spell': - card_content += f'\cardcontent{{{card["effect"]}}}\n' - - elif card['type'] == 'artifact': - card_content += f'\cardcontent{{{card["effect"]}}}\n' - - elif card['type'] == 'equipment': - # card_content += f'\cardsplitcontent{{\\faRecycle: {card["durability"]}}}{{{card["effect"]}}}' - card_content += f'\cardsplitcontent{{Durability: {card["durability"]}}}{{{card["effect"]}}}\n' - else: - print(f'WARNING: unknown card type {card["type"]}!') - - if 'play' in card: - card_content += f'\cardplaycost{{{card["play"]}}}\n' - - if card['set'] in SET_SYMBOLS: - card_content += f'\cardmodule{{{SET_SYMBOLS[card["set"]]}}}' - else: - print(f'WARNING unknown set: {card["set"]}') - - with open(CARDS_DIR / card_file, 'w') as tex_file: - print(CARD_TEMPLATE.format(card_content), file=tex_file) - - -def main(): - """Generate one standalone tikz picture for each card in the input data""" - - parser = argparse.ArgumentParser(description='generate latex standalone cards') - parser.add_argument('data', help='ini file or directory containing ini files defining the cards to generate') - parser.add_argument('--latex-root', help='path to the latex root directory') - - args = parser.parse_args() - - if args.latex_root: - global LATEX_ROOT - LATEX_ROOT = pathlib.Path(args.latex_root) - global CARDS_DIR - CARDS_DIR = LATEX_ROOT / 'cards' - global ASSETS_DIR - ASSETS_DIR = LATEX_ROOT / '../assets' - - - data_files = [args.data] - data_path = pathlib.Path(args.data) - if data_path.is_dir(): - data_files = data_path.glob('*.ini') - - for f in data_files: - data = configparser.ConfigParser() - data.read(f) - - collection_inputs = "" - cards = [card for card in data if card != 'DEFAULT'] - for i, card in enumerate(cards): - card_content = data[card] - card_content = dict(card_content) - card_content['set'] = pathlib.Path(f).stem - generate_card(card, card_content) - collection_inputs += f'\\input{{cards/{file_for_card(card)}}}\n' - if i == 0 or i % 4 < 3: - collection_inputs += f'\\hspace{{5mm}}\n' - else: - collection_inputs += f'\\vspace{{5mm}}\n\n' - - collection_path = pathlib.Path(f) - with open(LATEX_ROOT / 'sets' / f'{collection_path.stem}.tex', 'w') as collection_file: - print(COLLECTION_TEMPLATE.format(collection_inputs), file=collection_file) - -if __name__ == '__main__': - main() |
