From d77d280bd50eb729ec4301f1d4cae4d93709620b Mon Sep 17 00:00:00 2001 From: Yanick Champoux Date: Sat, 26 Mar 2022 14:24:57 -0400 Subject: [PATCH] print the rest --- .../components/Output/Print/Hull/index.svelte | 2 +- .../Output/Print/Identification/index.svelte | 7 +- .../Output/Print/Print.stories.svelte | 23 +++ src/lib/components/Output/Print/index.svelte | 91 ++++---- src/lib/components/Output/Print/sample.js | 195 +++++++++--------- src/lib/components/Output/Print/stories.js | 13 -- 6 files changed, 165 insertions(+), 166 deletions(-) create mode 100644 src/lib/components/Output/Print/Print.stories.svelte delete mode 100644 src/lib/components/Output/Print/stories.js diff --git a/src/lib/components/Output/Print/Hull/index.svelte b/src/lib/components/Output/Print/Hull/index.svelte index cffeaad..52b32c5 100644 --- a/src/lib/components/Output/Print/Hull/index.svelte +++ b/src/lib/components/Output/Print/Hull/index.svelte @@ -9,7 +9,7 @@ diff --git a/src/lib/components/Output/Print/sample.js b/src/lib/components/Output/Print/sample.js index 4c356b3..bd9352c 100644 --- a/src/lib/components/Output/Print/sample.js +++ b/src/lib/components/Output/Print/sample.js @@ -1,108 +1,105 @@ export default { - ftl: { - mass: 0, - cost: 0, - type: "standard", + "identification": { + "shipType": "Scout", + "shipClass": "Blah", + "isCarrier": false, + "mass": 10 }, - engine: { - mass: 40, - cost: 80, - rating: 6, - advanced: false, - }, - general: { - ship_class: "Deviant", - name: "", - ship_type: "Battleship", - mass: 132, - used_mass: 131, - cost: 415, - }, - weaponry: { - firecons: { - nbr: 5, - mass: 5, - cost: 20, + "propulsion": { + "drive": { + "reqs": { + "cost": 2, + "mass": 1 + }, + "rating": 3, + "advanced": true }, - weapons: [ - { - weapon_type: "submunition", - arcs: ["F"], - mass: 1, - cost: 3, - id: 1, + "ftl": { + "reqs": { + "cost": 0, + "mass": 0 }, - { - weapon_type: "beam", - weapon_class: "2", - arcs: ["A", "AS", "FS"], - mass: 2, - cost: 6, - id: 2, + "type": "none" + } + }, + "structure": { + "hull": { + "reqs": { + "cost": 2, + "mass": 1 }, - { - weapon_type: "pds", - mass: 1, - cost: 3, - id: 3, + "rating": 10, + "min": 1, + "max": 10 + }, + "screens": { + "reqs": { + "cost": 0, + "mass": 0 }, + "standard": 3, + "advanced": 2 + }, + "cargo": { + "reqs": { + "cost": 0, + "mass": 0 + }, + "space": 0 + }, + "streamlining": { + "reqs": { + "cost": 0, + "mass": 0 + }, + "type": "none" + }, + "armor": { + "layers": [], + "reqs": { + "mass": 0, + "cost": 0 + } + } + }, + "carrier": { + "reqs": { + "cost": 0, + "mass": 0 + }, + "bays": 0, + "squadrons": [] + }, + "weaponry": { + "weapons": [ + { + "id": 1, + "type": "beam", + "reqs": { + "mass": 1, + "cost": 3 + }, + "weaponClass": 1 + } ], - adfc: { - rating: 0, - cost: 0, - mass: 0, + "firecons": { + "stations": 1, + "reqs": { + "cost": 4, + "mass": 1 + } }, + "adfc": { + "rating": 1, + "reqs": { + "cost": 8, + "mass": 2 + } + } }, - structure: { - mass: 0, - cost: 0, - hull: { - rating: 22, - advanced: false, - cost: 44, - mass: 22, - }, - screens: { - standard: 2, - advanced: 1, - cost: 105, - mass: 35, - }, - armour: [ - { - layer: 1, - rating: 7, - cost: 14, - mass: 14, - }, - { - layer: 2, - rating: 2, - cost: 8, - mass: 4, - }, - { - layer: 3, - rating: 0, - cost: 0, - mass: 0, - }, - ], - }, - cargo: { - space: 7, - cost: 0, - mass: 7, - }, - streamlining: { - type: "none", - cost: 0, - mass: 0, - }, - carrier: { - bays: 0, - cost: 0, - mass: 0, - squadrons: [], - }, -}; + "reqs": { + "cost": 19, + "mass": 10, + "usedMass": 6 + } +} diff --git a/src/lib/components/Output/Print/stories.js b/src/lib/components/Output/Print/stories.js deleted file mode 100644 index 858e5c1..0000000 --- a/src/lib/components/Output/Print/stories.js +++ /dev/null @@ -1,13 +0,0 @@ -import Print from "./index.svelte"; -import sample from "./sample"; - -export default { - title: "printouts", -}; - -export const basic = () => ({ - Component: Print, - props: { - ship: sample, - }, -});