From e1341ace2d5eacaf4ceb92703c9cac99a8ded395 Mon Sep 17 00:00:00 2001 From: Neale Pickett Date: Sun, 27 Nov 2022 14:52:57 -0700 Subject: [PATCH] The version we printed --- Makefile | 27 + board-parts.py | 43 + src/clue-board.svg | 4741 +++++++++++++++++++++++++++++++++++ src/clue-cards-rooms.svg | 507 ++++ src/clue-cards-suspects.svg | 966 +++++++ src/clue-modular.svg | 2320 +++++++++++++++++ src/clue-sheets.svg | 1447 +++++++++++ src/clue-weapons.svg | 132 + 8 files changed, 10183 insertions(+) create mode 100644 Makefile create mode 100644 board-parts.py create mode 100644 src/clue-board.svg create mode 100644 src/clue-cards-rooms.svg create mode 100644 src/clue-cards-suspects.svg create mode 100644 src/clue-modular.svg create mode 100644 src/clue-sheets.svg create mode 100644 src/clue-weapons.svg diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..f9fac1a --- /dev/null +++ b/Makefile @@ -0,0 +1,27 @@ +all: clue-weapons.pdf +all: clue-cards-suspects.pdf +all: clue-cards-rooms.pdf +all: clue-sheets.pdf +all: clue-board-parts-all.pdf + +%.pdf: %.svg + inkscape --export-area-drawing -o $@ $< +%.pdf: src/%.svg + inkscape -o $@ $< + +BOARD_WIDTH=$(shell inkscape --query-width src/clue-board.svg) +BOARD_HEIGHT=$(shell inkscape --query-height src/clue-board.svg) + +clue-board-parts-all.pdf: clue-board-part-0.pdf +clue-board-parts-all.pdf: clue-board-part-1.pdf +clue-board-parts-all.pdf: clue-board-part-2.pdf +clue-board-parts-all.pdf: clue-board-part-3.pdf +clue-board-parts-all.pdf: clue-board-part-4.pdf + pdfunite $+ $@ + +clue-board-part-%.svg: src/clue-board.svg board-parts.py + python3 board-parts.py $< + + +clean: + rm -f board-part-*.svg *.pdf diff --git a/board-parts.py b/board-parts.py new file mode 100644 index 0000000..1cae93d --- /dev/null +++ b/board-parts.py @@ -0,0 +1,43 @@ +#! /usr/bin/python3 + +import sys +import xml.dom.minidom + + +doc = xml.dom.minidom.parse(sys.argv[1]) + +# Ugh, XML +path = None +for e in doc.getElementsByTagName("clipPath"): + if e.getAttribute("id") == "boardClip": + path = e + +rect = path.getElementsByTagName("rect")[0] +rect_x = float(rect.getAttribute("x")) +rect_y = float(rect.getAttribute("y")) +rect_w = float(rect.getAttribute("width")) +rect_h = float(rect.getAttribute("height")) + +l3 = rect_w +l1 = l3 / 3 +l2 = l1 * 2 + +parts = [ + [ 0, 0, l1, l2], + [l1, 0, l1, l2], + [l2, 0, l1, l2], + [ 0, l2, l2, l1], + [l2, l2, l1, l1], +] + +for n in range(len(parts)): + x,y,w,h = parts[n] + x += rect_x + y += rect_y + rect.setAttribute("x", str(x)) + rect.setAttribute("y", str(y)) + rect.setAttribute("width", str(w)) + rect.setAttribute("height", str(h)) + with open("clue-board-part-%d.svg" % n, "w") as f: + f.write(doc.toxml()) + diff --git a/src/clue-board.svg b/src/clue-board.svg new file mode 100644 index 0000000..a26f8c2 --- /dev/null +++ b/src/clue-board.svg @@ -0,0 +1,4741 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + DiningRoom + BIlliardRoom + Library + Study + Lounge + Hall + Ballroom + Kitchen + Conservatory + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/clue-cards-rooms.svg b/src/clue-cards-rooms.svg new file mode 100644 index 0000000..10ee306 --- /dev/null +++ b/src/clue-cards-rooms.svg @@ -0,0 +1,507 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + Ballroom + + + Conservatory + + + BIlliardRoom + + + Library + + + Study + + + Hall + + + Lounge + + + DiningRoom + + + Kitchen + + + diff --git a/src/clue-cards-suspects.svg b/src/clue-cards-suspects.svg new file mode 100644 index 0000000..414b45c --- /dev/null +++ b/src/clue-cards-suspects.svg @@ -0,0 +1,966 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Rev. Peacock + Ms. Scarlett + Dr. White + Tangerine + Rufus + Mr. Green + Prof. Plum + Col. Mustard + + diff --git a/src/clue-modular.svg b/src/clue-modular.svg new file mode 100644 index 0000000..38078c8 --- /dev/null +++ b/src/clue-modular.svg @@ -0,0 +1,2320 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Hall + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Study + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Kitchen + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Ballroom + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Billiard Room + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Conservatory + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Hall + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Lounge + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Dining Room + + + + + + + + diff --git a/src/clue-sheets.svg b/src/clue-sheets.svg new file mode 100644 index 0000000..3e2ba75 --- /dev/null +++ b/src/clue-sheets.svg @@ -0,0 +1,1447 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Suspects + Weapons + Rooms + Peacock + Scarlett + White + Tangerine + Green + Plum + Mustard + Rufus + Pipe + Syringe + Revolver + Rope + Knife + Wrench + Poison + Hall + Lounge + Dining Room + Kitchen + Ballroom + Conservatory + Billiard Room + Study + Library + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Axe + + + + + + + + + + + diff --git a/src/clue-weapons.svg b/src/clue-weapons.svg new file mode 100644 index 0000000..f2c7d1a --- /dev/null +++ b/src/clue-weapons.svg @@ -0,0 +1,132 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + +