diff options
author | Tor Andersson <tor@ccxvii.net> | 2023-11-20 02:58:24 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2024-01-08 16:36:47 +0100 |
commit | 95b90a9b4c21d6fd0805177d5193a8a62fa217ad (patch) | |
tree | cbbe969cf9b3e392da9ee80e4e67192885a33192 /tools | |
parent | ea85d06093090d417d60a01e3bbe637931c4544d (diff) | |
download | table-battles-95b90a9b4c21d6fd0805177d5193a8a62fa217ad.tar.gz |
data processing
Diffstat (limited to 'tools')
-rw-r--r-- | tools/cards.csv | 333 | ||||
-rw-r--r-- | tools/download.sh | 3 | ||||
-rw-r--r-- | tools/gendata.js | 86 | ||||
-rw-r--r-- | tools/scenarios.csv | 28 |
4 files changed, 450 insertions, 0 deletions
diff --git a/tools/cards.csv b/tools/cards.csv new file mode 100644 index 0000000..d2107c5 --- /dev/null +++ b/tools/cards.csv @@ -0,0 +1,333 @@ +scenario,number,wing,name,strength,dice,reserve,action1_type,action1_req,action1_target,action1_effect,action2_type,action2_req,action2_target,action2_effect,flavor
+BASE GAME,,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+WHITE MOUNTAIN,,,,,,,,,,,,,,,
+1,1A,red,The Twelve Apostles,III,Straight 4,,Bombard,,,,Screen,,Any enemy attack,,These were a dozen heavy guns fielded by the Catholic League.
+1,2A,red,Catholic League Cavalry,4,3/4,,Attack,Triplet,Schlick,1 hit.,Screen,Pair,Hohenlohe,,
+1,3A,red,Catholic League Foot,6,(6),,Attack,,"Hohenlohe, Schlick",1 hit per die. 1 self per action.,,,,,
+1,4A,pink,Imperial Cavalry,4,1/2,PURSUIT,Attack,Triplet,Protestant Cavalry,1 hit.,Screen,Pair,Thurn,,
+1,5A,pink,Liechtenstein,6,(5),RETIRE,Attack,,"Thurn, Hohenlohe",1 hit per die. 1 self per action.,,,,,
+1,6A,pink,Tiefenbach,4*,(4),Liechtenstein,Attack,,"Thurn, Hohenlohe",1 hit per die. 1 self per action.,,,,,
+1,7A,blue,Thurn,6,6,,Attack,,"Liechtenstein, Tiefenbach",1 hit per die. 1 self per action.,,,,,
+1,8A,blue,Protestant Cavalry,4,5/6,PURSUIT,Attack,Triplet,Imperial Cavalry,1 hit.,Screen,Pair,"Liechtenstein, Tiefenbach",,
+1,9A,blue,Hohenlohe,6*,5,,Attack,,"Catholic League Foot, Liechtenstein, Tiefenbach",1 hit per die. 1 self per action.,,,,,"One of the nobles who instigated the Bohemian Revolt (and thus the Thirty Years War) by chucking a couple of civil servants out a window. They survived, and Thurn went on to be one of the worst generals in the rebellion. His incompetence helped seal their fate at White Mountain."
+1,10A,blue,Schlick,4,4,,Attack,Triplet,Catholic League Cavalry,1 hit.,Screen,Pair,Catholic League Foot,,
+,,,,,,,,,,,,,,,
+MARSTON MOOR,,,,,,,,,,,,,,,
+2,11A,dkblue,Northern Horse,3,Doubles,PURSUIT,Attack,Pair,Fairfax,1 hit.,Screen,Pair,"Baillie, Lumsden, Fairfax",,
+2,12A,blue,Tillier's Left,6,(6),,Attack,,"Baillie, Lumsden",1 hit per die. 1 self per action.,,,,,
+2,13A,blue,Royalist Guns,I,Straight 4,,,,,,Screen,,Any enemy attack,,
+2,14A,blue,Tillier's Right,4,(5)/(6),RETIRE,Attack,,"Crawford, Manchester",1 hit per die. 1 self per action.,,,,,
+2,15A,blue,Whitecoats,2,Doubles,Tillier's Right,Attack,,"Crawford, Manchester",1 hit.,,,,,
+2,16A,dkblue,Byron,3,Doubles,PURSUIT,Attack,Two Pairs,Cromwell,1 hit.,Screen,Pair,"Crawford, Manchester, Cromwell",,
+2,17A,dkblue,Rupert's Lifeguard,1,,,,,,,,,,,"While this card is in play, Tillier's Left and Tillier's Right suffer one less hit when Attacked. <p>When either the Northern Horse or Byron are about to Rout, add the Lifeguard's Unit to that Formation. That is, that Formation does NOT Rout at this time, but only has one Unit block. <p>Remove this card from play if and when that happens. This does not constitute a Rout."
+2,18A,red,Cromwell,4,1-3,,Attack,,"Byron, Northern Horse",1 hit per die.,Screen,Pair,"Byron, Tillier's Right, Whitecoats",,"Cromwell's disciplined cavalry didn't chase after the fleeing Byron, but circled around to take out the other wing of horse."
+2,19A,red,Crawford,4,(5)/(6),RETIRE,Attack,,"Tillier's Right, Whitecoats",1 hit per die. 1 self per action.,,,,,
+2,20A,red,Manchester,4,(4),Crawford,Attack,,"Tillier's Right, Whitecoats",1 hit per die. 1 self per action.,,,,,
+2,21A,pink,Roundhead Guns,II,Triples,,,,,,Screen,,Any enemy attack,,
+2,22A,pink,Baillie,3,(6),RETIRE,Attack,,"Tillier's Left, Tillier's Right, Whitecoats",1 hit per die. 1 self per action.,,,,,
+2,23A,pink,Lumsden,5,(5),Baillie,Attack,,"Tillier's Left, Tillier's Right, Whitecoats",1 hit per die. 1 self per action.,,,,,
+2,24A,red,Fairfax,3,Doubles,PURSUIT,Attack,,Northern Horse,1 hit.,Screen,Pair,"Tillier's Left, Northern Horse",,
+,,,,,,,,,,,,,,,
+THE PLAINS OF ABRAHAM,,,,,,,,,,,,,,,
+3,25A,,,,,,,,,,,,,,
+3,26A,,,,,,,,,,,,,,
+3,27A,,,,,,,,,,,,,,
+3,28A,,,,,,,,,,,,,,
+3,29A,,,,,,,,,,,,,,
+3,30A,,,,,,,,,,,,,,
+3,31A,,,,,,,,,,,,,,
+3,32A,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+BOSWORTH FIELD,,,,,,,,,,,,,,,
+4,33A,,,,,,,,,,,,,,
+4,34A,,,,,,,,,,,,,,
+4,35A,,,,,,,,,,,,,,
+4,36A,,,,,,,,,,,,,,
+4,37A,,,,,,,,,,,,,,
+4,38A,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+MALPLAQUET,,,,,,,,,,,,,,,
+5,39A,,,,,,,,,,,,,,
+5,40A,,,,,,,,,,,,,,
+5,41A,,,,,,,,,,,,,,
+5,42A,,,,,,,,,,,,,,
+5,1B,,,,,,,,,,,,,,
+5,2B,,,,,,,,,,,,,,
+5,3B,,,,,,,,,,,,,,
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000,87A,,,,,,,,,,,,,,
+1000,88A,,,,,,,,,,,,,,
+1000,89A,,,,,,,,,,,,,,
+1000,90A,,,,,,,,,,,,,,
+1000,91A,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+BOUVINES,,,,,,,,,,,,,,,
+1001,83B,,,,,,,,,,,,,,
+1001,84B,,,,,,,,,,,,,,
+1001,85B,,,,,,,,,,,,,,
+1001,86B,,,,,,,,,,,,,,
+1001,87B,,,,,,,,,,,,,,
+1001,88B,,,,,,,,,,,,,,
+1001,89B,,,,,,,,,,,,,,
+1001,90B,,,,,,,,,,,,,,
+1001,91B,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+EXPANSION 2 - AGE OF ALEXANDER,,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+CHAERONEA,,,,,,,,,,,,,,,
+17,92A,,,,,,,,,,,,,,
+17,93A,,,,,,,,,,,,,,
+17,94A,,,,,,,,,,,,,,
+17,95A,,,,,,,,,,,,,,
+17,96A,,,,,,,,,,,,,,
+17,97A,,,,,,,,,,,,,,
+17,98A,,,,,,,,,,,,,,
+17,99A,,,,,,,,,,,,,,
+17,100A,,,,,,,,,,,,,,
+17,101A,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+THE GRANICUS,,,,,,,,,,,,,,,
+18,102A,,,,,,,,,,,,,,
+18,103A,,,,,,,,,,,,,,
+18,104A,,,,,,,,,,,,,,
+18,105A,,,,,,,,,,,,,,
+18,106A,,,,,,,,,,,,,,
+18,107A,,,,,,,,,,,,,,
+18,108A,,,,,,,,,,,,,,
+18,109A,,,,,,,,,,,,,,
+18,110A,,,,,,,,,,,,,,
+18,111A,,,,,,,,,,,,,,
+18,112A,,,,,,,,,,,,,,
+18,113A,,,,,,,,,,,,,,
+18,114A,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+ISSUS,,,,,,,,,,,,,,,
+19,115A,,,,,,,,,,,,,,
+19,116A,,,,,,,,,,,,,,
+19,117A,,,,,,,,,,,,,,
+19,118A,,,,,,,,,,,,,,
+19,119A,,,,,,,,,,,,,,
+19,120A,,,,,,,,,,,,,,
+19,121A,,,,,,,,,,,,,,
+19,122A,,,,,,,,,,,,,,
+19,123A,,,,,,,,,,,,,,
+19,124A,,,,,,,,,,,,,,
+19,125A,,,,,,,,,,,,,,
+19,126A,,,,,,,,,,,,,,
+19,127A,,,,,,,,,,,,,,
+19,128A,,,,,,,,,,,,,,
+19,129A,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+GAUGAMELA,,,,,,,,,,,,,,,
+20,130A,,,,,,,,,,,,,,
+20,131A,,,,,,,,,,,,,,
+20,132A,,,,,,,,,,,,,,
+20,133A,,,,,,,,,,,,,,
+20,134A,,,,,,,,,,,,,,
+20,135A,,,,,,,,,,,,,,
+20,92B,,,,,,,,,,,,,,
+20,93B,,,,,,,,,,,,,,
+20,94B,,,,,,,,,,,,,,
+20,95B,,,,,,,,,,,,,,
+20,96B,,,,,,,,,,,,,,
+20,97B,,,,,,,,,,,,,,
+20,98B,,,,,,,,,,,,,,
+20,99B,,,,,,,,,,,,,,
+20,100B,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+THE HYDASPES,,,,,,,,,,,,,,,
+21,101B,,,,,,,,,,,,,,
+21,102B,,,,,,,,,,,,,,
+21,103B,,,,,,,,,,,,,,
+21,104B,,,,,,,,,,,,,,
+21,105B,,,,,,,,,,,,,,
+21,106B,,,,,,,,,,,,,,
+21,107B,,,,,,,,,,,,,,
+21,108B,,,,,,,,,,,,,,
+21,109B,,,,,,,,,,,,,,
+21,110B,,,,,,,,,,,,,,
+21,111B,,,,,,,,,,,,,,
+21,112B,,,,,,,,,,,,,,
+21,113B,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+GABIENE,,,,,,,,,,,,,,,
+22,114B,,,,,,,,,,,,,,
+22,115B,,,,,,,,,,,,,,
+22,116B,,,,,,,,,,,,,,
+22,117B,,,,,,,,,,,,,,
+22,118B,,,,,,,,,,,,,,
+22,119B,,,,,,,,,,,,,,
+22,120B,,,,,,,,,,,,,,
+22,121B,,,,,,,,,,,,,,
+22,122B,,,,,,,,,,,,,,
+22,123B,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+IPSUS,,,,,,,,,,,,,,,
+23,124B,,,,,,,,,,,,,,
+23,125B,,,,,,,,,,,,,,
+23,126B,,,,,,,,,,,,,,
+23,127B,,,,,,,,,,,,,,
+23,128B,,,,,,,,,,,,,,
+23,129B,,,,,,,,,,,,,,
+23,130B,,,,,,,,,,,,,,
+23,131B,,,,,,,,,,,,,,
+23,132B,,,,,,,,,,,,,,
+23,133B,,,,,,,,,,,,,,
+23,134B,,,,,,,,,,,,,,
+23,135B,,,,,,,,,,,,,,
+,,,,,,,,,,,,,,,
+EXPANSION 3 - GETTYSBURG,,,,,,,,,,,,,,,
+EXPANSION 4 - THE ENGLISH CIVIL WAR,,,,,,,,,,,,,,,
+EXPANSION 5 - THE GRAND ALLIANCE,,,,,,,,,,,,,,,
+EXPANSION 6 - GREAT BATTLES OF PRINCE CHARLES ALEXANDER OF LORRAINE,,,,,,,,,,,,,,,
\ No newline at end of file diff --git a/tools/download.sh b/tools/download.sh new file mode 100644 index 0000000..874c81d --- /dev/null +++ b/tools/download.sh @@ -0,0 +1,3 @@ +# Download and process card data from spreadsheet. +curl -L 'https://docs.google.com/spreadsheets/d/e/2PACX-1vRKdgICtx6hzlWFuKYDQN4UO15rs7i-pBvawMWkaBWe5SmiivEP_ztyEVnpFCtsIB-MkKo3buD9qGdc/pub?gid=0&single=true&output=csv' > tools/cards.csv +curl -L 'https://docs.google.com/spreadsheets/d/e/2PACX-1vRKdgICtx6hzlWFuKYDQN4UO15rs7i-pBvawMWkaBWe5SmiivEP_ztyEVnpFCtsIB-MkKo3buD9qGdc/pub?gid=1992953161&single=true&output=csv' > tools/scenarios.csv diff --git a/tools/gendata.js b/tools/gendata.js new file mode 100644 index 0000000..764f011 --- /dev/null +++ b/tools/gendata.js @@ -0,0 +1,86 @@ +const fs = require("fs") +const { parse } = require("csv-parse/sync") + +var card_buffer = fs.readFileSync("tools/cards.csv", "utf-8") +var card_records = parse(card_buffer, { columns: true, skip_empty_lines: true }) + +// console.log(card_records) + +var result = [ +`<!doctype html> +<title>Table Battle Cards</title> +<link rel="stylesheet" href="/fonts/fonts.css"> +<link rel="stylesheet" href="/table-battles/cards.css"> +<style> +body{background-color:silver;max-width:1600px;margin:0 auto;padding:20px;background-image:url(../texture.png)} +.list{display:flex;flex-wrap:wrap;gap:20px;} +</style> +<div>` +] + +for (let c of card_records) { + if (!c.scenario) + continue + + if (!c.number) { + result.push(`</div><h2>${c.scenario}</h2><div class="list">`) + continue + } + + if (!c.name) + continue + + if (c.strength.endsWith("*")) { + c.strength = parseInt(c.strength) + c.star = true + } + + result.push(`<div class="card">`) + result.push(`<div class="formation ${c.wing}">${c.name}</div>`) + if (c.strength) + result.push(`<div class="strength">${c.strength}</div>`) + + if (c.dice) { + if (c.star) + result.push(`<div class="dice_area">${c.dice}<div class="star">★</div></div>`) + else + result.push(`<div class="dice_area">${c.dice}</div>`) + } + + if (c.action1_type) { + result.push(`<div class="action_row">`) + result.push(`<div class="action_type">${c.action1_type}</div>`) + result.push(`<div class="action_requirement">${c.action1_req}</div>`) + result.push(`<div class="action_target">${c.action1_target}</div>`) + if (c.action1_effect) + result.push(`<div class="action_effect">${c.action1_effect}</div>`) + result.push(`</div>`) + } + + if (c.action2_type || c.action2_effect) { + result.push(`<div class="action_row">`) + result.push(`<div class="action_type reaction">${c.action2_type}</div>`) + result.push(`<div class="action_requirement">${c.action2_req}</div>`) + result.push(`<div class="action_target">${c.action2_target}</div>`) + if (c.action2_effect) + result.push(`<div class="action_effect">${c.action2_effect}</div>`) + result.push(`</div>`) + } + + if (c.flavor) + result.push(`<div class="flavor">${c.flavor}</div>`) + + if (c.reserve) { + if (c.reserve === "RETIRE" || c.reserve === "PURSUIT") + result.push(`<div class="reserve">${c.reserve}</div>`) + else + result.push(`<div class="reserve">IN RESERVE (${c.reserve})</div>`) + } + + result.push(`<div class="card_number">${c.number}</div>`) + result.push(`<div class="wing_name">${c.wing}</div>`) + + result.push(`</div>`) +} + +console.log(result.join("\n")) diff --git a/tools/scenarios.csv b/tools/scenarios.csv new file mode 100644 index 0000000..d495051 --- /dev/null +++ b/tools/scenarios.csv @@ -0,0 +1,28 @@ +number,name,date,player1,cards1,morale1,player2,cards2,morale2,text
+1,White Mountain,8 November 1620,The Bohemian Revolt,07A-10A,4,Imperials & Catholic League,01A-06A,2,"A strong defensive position is squandered by the hapless rebel leadership, effectively ending the Bohemian Revolt. Incredibly, the war it ignited would continue on, engulfing most of Europe for three decades. A simple battle to get your feet wet."
+2,Marston Moor,2 July 1644,Royalists,11A-17A,2,Parliament & Covenanters,18A-24A,3,A letter from King Charles convinced Prince Rupert of the Rhine that he ought to fight a much larger army. Parliament won a lopsided victory. Only the stubborn stand of the Whitecoats prevented total disaster. This has more moving parts than the White Mountain scenario.
+3,The Plains of Abraham,13 September 1759,British,25A-28A,Rout 3,French,29A-32A,Rout 1,"The battle that won Canada for the British. To win, the British must Rout all 3 French cards without losing any of their own. If the French Rout a single card, they win (even if they lose their last card when doing so). This battle introduces Counter-attack Reactions."
+4,Bosworth Field,,,,,,,,
+5,Malplaquet,,,,,,,,
+6,Ivry,,,,,,,,
+7,The Dunes,,,,,,,,
+8,Brooklyn Heights,,,,,,,,
+36,Pharsalus,9 August 48 BCE,Gnaeus Pompeius Magnus,217A-220A,2,Gaius Iulius Caesar,221A-225A,2,"The decisive battle of Caesar's Civil War saw him square off against his old ally Pompey the Great. Knowing he would lose a straightforward clash of arms, Caesar gambled everything on a bold stratagem."
+37,Inkerman,5 November 1854,Russian Empire,217B-220B,1,Anglo-French Alliance,221B-225B,2,"In a dense fog, a massive - but badly coordinated - Russian army launched a surprise attack. As the fog lifted and fresh Allied troops poured in, their desperate, doomed defense improbably turned into a lopsided victory."
+,,,,,,,,,
+9,St. Albans,,,,,,,,
+10,Blore Heath,,,,,,,,
+11,,,,,,,,,
+12,,,,,,,,,
+13,,,,,,,,,
+14,,,,,,,,,
+15,,,,,,,,,
+16,,,,,,,,,
+,,,,,,,,,
+17,Chaeronea,2 August 338 BCE,,,,,,,
+18,,,,,,,,,
+19,,,,,,,,,
+20,,,,,,,,,
+21,,,,,,,,,
+22,,,,,,,,,
+23,,,,,,,,,
\ No newline at end of file |