aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/generate_card.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/scripts/generate_card.py b/scripts/generate_card.py
index c45810b9..69af713b 100755
--- a/scripts/generate_card.py
+++ b/scripts/generate_card.py
@@ -23,7 +23,8 @@ SET_SYMBOLS = {
'nautics': 'nautics',
'misc': '',
'kraken': 'kraken',
- 'exp1': 'exp1'
+ 'exp1': 'exp1',
+ 'potions': 'potions',
}
SCRIPT_PATH = Path(__file__).parent
@@ -53,6 +54,7 @@ FORMATTED_KEYS = {
'attack': 'Angriff',
'effect': 'Effekt',
'durability': 'Haltbarkeit',
+ 'use': 'Gebrauch',
}
}
@@ -173,6 +175,12 @@ def generate_latex(card: MutableMapping, language='en'):
stats = f'{formatted_durability}: {durability}'
effect, _ = get_latex_field(card, 'effect', language)
card_content += f'\\cardsplitcontent{{{stats}}}{{{effect}}}\n'
+
+ elif card['type'] == 'potion':
+ formatted_use = get_formatted_key('use', language)
+ use, _ = get_latex_field(card, 'use', language)
+ card_content += f'\\cardcontent{{\\textit{{{formatted_use}}} - {use}}}\n'
+
else:
print(f'WARNING: unknown card type {card["type"]}!')