Skip to content

Commit

Permalink
support flipSide
Browse files Browse the repository at this point in the history
  • Loading branch information
seiyria committed Jun 16, 2024
1 parent 0e9144f commit 429e001
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
8 changes: 5 additions & 3 deletions content/card-data/arcs/en-US/blightedreach.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
**When Secured:** Flip this card over to its Imperial Council Decided side. As a reminder, tuck it partially under your played card so its card title is showing.
image: AID01A
name: Imperial Council in Session
flipSide: ARCS/AID01B
tags:
- Blighted Reach
- Imperial Council
Expand All @@ -23,6 +24,7 @@
*You may flip this card to In Session if you call a Summit and Petition the Council.*
image: AID01B
name: Imperial Council Decided
flipSide: ARCS/AID01A
tags:
- Blighted Reach
- Imperial Council
Expand Down Expand Up @@ -412,7 +414,7 @@
**II.** Collect lore from the Court and from your Rivals in Summits.
**III.** Use your Golems to scrap your lore and the Golems themselves.
**III.** Use your Golems to scrap your lore and the Golems themselves.
image: FATE05
name: Caretaker
tags:
Expand All @@ -432,7 +434,7 @@
**II.** Hold initiative and gather Guild support to burnish your image.
**III.** Have the most Guild cards and continue to hold the initiative.
**III.** Have the most Guild cards and continue to hold the initiative.
image: FATE06
name: Partisan
tags:
Expand Down Expand Up @@ -6922,4 +6924,4 @@
- Edict
- Judge
meta:
act: 3
act: 3
13 changes: 12 additions & 1 deletion scripts/validate-cards.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,14 @@ allCards.forEach((card, index) => {
process.exit(1);
}

if (card.flipSide) {
const flipSide = allCards.find((c) => c.id === card.flipSide);
if (!flipSide) {
console.error(`Card ${card.id} has invalid flipSide ${card.flipSide}`);
process.exit(1);
}
}

const otherProps = omit(card, [
'id',
'name',
Expand All @@ -45,10 +53,13 @@ allCards.forEach((card, index) => {
'locale',
'tags',
'meta',
'flipSide',
]);

if (Object.keys(otherProps).length > 0) {
console.error(`Card ${card.id} has other props: ${otherProps.join(',')}`);
console.error(
`Card ${card.id} has other props: ${Object.keys(otherProps).join(',')}`,
);
process.exit(1);
}
});
Expand Down

0 comments on commit 429e001

Please sign in to comment.