@elite-dangerous-almanac/core 0.1.7 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/PROVENANCE/i18n/SOURCES.md +2 -2
- package/PROVENANCE/ships/SOURCES.md +29 -9
- package/README.md +54 -40
- package/dist/astro/galaxy-grid.js +1 -1
- package/dist/astro/index.d.ts +1 -1
- package/dist/astro/index.js +1 -1
- package/dist/astro/naming-region-origins.d.ts +1 -1
- package/dist/astro/naming-region-origins.js +1 -1
- package/dist/astro/nebulae.d.ts +2 -2
- package/dist/astro/permit-locks.d.ts +2 -1
- package/dist/astro/permit-locks.js +1 -1
- package/dist/astro/procedural-system.d.ts +2 -1
- package/dist/astro/procedural-system.js +1 -1
- package/dist/astro/sector-name.d.ts +2 -1
- package/dist/astro/sector-name.js +1 -1
- package/dist/astro/system-address.d.ts +1 -1
- package/dist/astro/system-name.d.ts +14 -9
- package/dist/astro/system-name.js +1 -1
- package/dist/chunk-2W5MW376.js +1 -0
- package/dist/chunk-2W5MW376.js.map +1 -0
- package/dist/{chunk-VZZUNSDF.js → chunk-4KJ7CR74.js} +1 -1
- package/dist/{chunk-VZZUNSDF.js.map → chunk-4KJ7CR74.js.map} +1 -1
- package/dist/{chunk-6EUVIZAS.js → chunk-4QYTVSNR.js} +1 -1
- package/dist/{chunk-EKQCVCMK.js → chunk-5ZVYRX6Z.js} +1 -1
- package/dist/{chunk-EKQCVCMK.js.map → chunk-5ZVYRX6Z.js.map} +1 -1
- package/dist/chunk-6GJHUWMO.js +1 -0
- package/dist/chunk-6GJHUWMO.js.map +1 -0
- package/dist/chunk-6L56LWTT.js +1 -0
- package/dist/chunk-6L56LWTT.js.map +1 -0
- package/dist/{chunk-GQ5GX5TB.js → chunk-6O4NRRSB.js} +1 -1
- package/dist/chunk-6O4NRRSB.js.map +1 -0
- package/dist/{chunk-WNGQ3IAM.js → chunk-6UNAD74Z.js} +1 -1
- package/dist/{chunk-WNGQ3IAM.js.map → chunk-6UNAD74Z.js.map} +1 -1
- package/dist/{chunk-JPBMRJFC.js → chunk-77I24V6B.js} +1 -1
- package/dist/chunk-77I24V6B.js.map +1 -0
- package/dist/chunk-7ATBEOVC.js +1 -0
- package/dist/chunk-7ATBEOVC.js.map +1 -0
- package/dist/chunk-7TQ2X6Q3.js +1 -0
- package/dist/chunk-7TQ2X6Q3.js.map +1 -0
- package/dist/{chunk-6EPYVBAX.js → chunk-A6OINYNP.js} +1 -1
- package/dist/{chunk-Q3QCLNVG.js → chunk-AYAKU4YA.js} +1 -1
- package/dist/chunk-AYAKU4YA.js.map +1 -0
- package/dist/chunk-B7EYTZRK.js +1 -0
- package/dist/chunk-B7EYTZRK.js.map +1 -0
- package/dist/{chunk-EBAHNZ36.js → chunk-CIULJH3G.js} +1 -1
- package/dist/{chunk-EBAHNZ36.js.map → chunk-CIULJH3G.js.map} +1 -1
- package/dist/{chunk-SNADUQSJ.js → chunk-CJK2IBI2.js} +1 -1
- package/dist/{chunk-SNADUQSJ.js.map → chunk-CJK2IBI2.js.map} +1 -1
- package/dist/{chunk-DYPOL3CI.js → chunk-CJQ37JII.js} +1 -1
- package/dist/chunk-CJQ37JII.js.map +1 -0
- package/dist/chunk-D6YEHR5S.js +1 -0
- package/dist/chunk-D6YEHR5S.js.map +1 -0
- package/dist/{chunk-Z6XMXMVI.js → chunk-DBDCOHI4.js} +1 -1
- package/dist/chunk-DBDCOHI4.js.map +1 -0
- package/dist/{chunk-AFVYCQWL.js → chunk-DCB4COCL.js} +1 -1
- package/dist/{chunk-AFVYCQWL.js.map → chunk-DCB4COCL.js.map} +1 -1
- package/dist/{chunk-CJWFY6OX.js → chunk-DSMLYA2M.js} +1 -1
- package/dist/{chunk-CJWFY6OX.js.map → chunk-DSMLYA2M.js.map} +1 -1
- package/dist/{chunk-UXBCLFGU.js → chunk-DWRNXUAX.js} +1 -1
- package/dist/{chunk-UXBCLFGU.js.map → chunk-DWRNXUAX.js.map} +1 -1
- package/dist/{chunk-UHSNB5SV.js → chunk-EVJ32UF3.js} +1 -1
- package/dist/{chunk-UHSNB5SV.js.map → chunk-EVJ32UF3.js.map} +1 -1
- package/dist/chunk-EVW4Z4CB.js +1 -0
- package/dist/chunk-EVW4Z4CB.js.map +1 -0
- package/dist/{chunk-4S6WB7QR.js → chunk-FF2X4K5P.js} +1 -1
- package/dist/chunk-FF2X4K5P.js.map +1 -0
- package/dist/chunk-FYVPZBXN.js +1 -0
- package/dist/chunk-FYVPZBXN.js.map +1 -0
- package/dist/{chunk-QTZPA2FR.js → chunk-GLWPSVFV.js} +1 -1
- package/dist/chunk-GLWPSVFV.js.map +1 -0
- package/dist/chunk-GZYPQIO2.js +1 -0
- package/dist/chunk-GZYPQIO2.js.map +1 -0
- package/dist/chunk-H47K3UWG.js +1 -0
- package/dist/chunk-H47K3UWG.js.map +1 -0
- package/dist/chunk-JGOAQLYW.js +1 -0
- package/dist/chunk-JGOAQLYW.js.map +1 -0
- package/dist/{chunk-JWWYAMGD.js → chunk-MGRDB2BZ.js} +1 -1
- package/dist/{chunk-JWWYAMGD.js.map → chunk-MGRDB2BZ.js.map} +1 -1
- package/dist/{chunk-MKGJPVPS.js → chunk-MRTTQYT5.js} +1 -1
- package/dist/{chunk-MKGJPVPS.js.map → chunk-MRTTQYT5.js.map} +1 -1
- package/dist/chunk-MTJ4MS7W.js +1 -0
- package/dist/chunk-MTJ4MS7W.js.map +1 -0
- package/dist/chunk-NIURLW2F.js +1 -0
- package/dist/chunk-NIURLW2F.js.map +1 -0
- package/dist/chunk-OLKNYGGT.js +1 -0
- package/dist/chunk-OLKNYGGT.js.map +1 -0
- package/dist/{chunk-UXFMVZAY.js → chunk-OVUHQEH5.js} +1 -1
- package/dist/{chunk-UXFMVZAY.js.map → chunk-OVUHQEH5.js.map} +1 -1
- package/dist/chunk-OYFMHDYT.js +1 -0
- package/dist/chunk-OYFMHDYT.js.map +1 -0
- package/dist/chunk-OYR5HUQZ.js +1 -0
- package/dist/chunk-OYR5HUQZ.js.map +1 -0
- package/dist/{chunk-LLHGSBPI.js → chunk-PA5EITW5.js} +1 -1
- package/dist/{chunk-LLHGSBPI.js.map → chunk-PA5EITW5.js.map} +1 -1
- package/dist/chunk-PL75RTA2.js +1 -0
- package/dist/{chunk-2VPVZELZ.js.map → chunk-PL75RTA2.js.map} +1 -1
- package/dist/chunk-PY5L6WC5.js +1 -0
- package/dist/chunk-PY5L6WC5.js.map +1 -0
- package/dist/{chunk-W6EPHHTS.js → chunk-Q2L75GSI.js} +1 -1
- package/dist/chunk-Q2L75GSI.js.map +1 -0
- package/dist/chunk-QJ7GB6FF.js +1 -0
- package/dist/chunk-QJ7GB6FF.js.map +1 -0
- package/dist/chunk-QTAMQ6ME.js +1 -0
- package/dist/chunk-QTAMQ6ME.js.map +1 -0
- package/dist/{chunk-VDVFJXX5.js → chunk-QY3L5BKN.js} +1 -1
- package/dist/{chunk-FMPRCYKY.js → chunk-RRYBSAPX.js} +1 -1
- package/dist/chunk-RRYBSAPX.js.map +1 -0
- package/dist/{chunk-J42ZXLBL.js → chunk-T62GO4AA.js} +1 -1
- package/dist/chunk-T62GO4AA.js.map +1 -0
- package/dist/{chunk-E3BRVGJJ.js → chunk-TBZJIQ5P.js} +1 -1
- package/dist/{chunk-E3BRVGJJ.js.map → chunk-TBZJIQ5P.js.map} +1 -1
- package/dist/chunk-V3AEUBHV.js +1 -0
- package/dist/chunk-V3AEUBHV.js.map +1 -0
- package/dist/chunk-VYDQHPY2.js +1 -0
- package/dist/chunk-VYDQHPY2.js.map +1 -0
- package/dist/chunk-XUHAPOM6.js +1 -0
- package/dist/chunk-XUHAPOM6.js.map +1 -0
- package/dist/chunk-Y6KJJMIM.js +1 -0
- package/dist/chunk-Y6KJJMIM.js.map +1 -0
- package/dist/chunk-YXPZ7QQB.js +1 -0
- package/dist/chunk-YXPZ7QQB.js.map +1 -0
- package/dist/{chunk-Y6UZWNP4.js → chunk-ZCEAPJDH.js} +1 -1
- package/dist/{chunk-Y6UZWNP4.js.map → chunk-ZCEAPJDH.js.map} +1 -1
- package/dist/commodities/commodities.d.ts +20 -10
- package/dist/commodities/commodities.js +1 -1
- package/dist/commodities/index.d.ts +15 -4
- package/dist/commodities/index.js +1 -1
- package/dist/equipment/index.js +1 -1
- package/dist/equipment/modification-costs.d.ts +2 -1
- package/dist/equipment/modification-costs.js.map +1 -1
- package/dist/equipment/modification-journal.js +1 -1
- package/dist/equipment/modifications.d.ts +2 -1
- package/dist/equipment/modifications.js +1 -1
- package/dist/equipment/suits.d.ts +6 -3
- package/dist/equipment/suits.js +1 -1
- package/dist/equipment/upgrade-costs.d.ts +8 -4
- package/dist/equipment/upgrade-costs.js +1 -1
- package/dist/equipment/upgrade-costs.js.map +1 -1
- package/dist/equipment/weapons.d.ts +13 -5
- package/dist/equipment/weapons.js +1 -1
- package/dist/i18n/blueprints.d.ts +6 -6
- package/dist/i18n/blueprints.js +1 -1
- package/dist/i18n/diagnostics.d.ts +1 -13
- package/dist/i18n/engineering-groups.d.ts +1 -0
- package/dist/i18n/engineering-groups.js +1 -1
- package/dist/i18n/experimental-effect-descriptions.d.ts +4 -3
- package/dist/i18n/experimental-effect-descriptions.js +1 -1
- package/dist/i18n/experimental-effects.d.ts +5 -4
- package/dist/i18n/experimental-effects.js +1 -1
- package/dist/i18n/index.d.ts +1 -13
- package/dist/i18n/index.js +1 -1
- package/dist/i18n/pre-engineered.d.ts +7 -6
- package/dist/i18n/pre-engineered.js +1 -1
- package/dist/materials/index.d.ts +16 -4
- package/dist/materials/index.js +1 -1
- package/dist/materials/materials.d.ts +36 -19
- package/dist/materials/materials.js +1 -1
- package/dist/materials/micro-resources.d.ts +18 -7
- package/dist/materials/micro-resources.js +1 -1
- package/dist/ships/armour.d.ts +20 -4
- package/dist/ships/armour.js +1 -1
- package/dist/ships/blueprint-costs.d.ts +20 -17
- package/dist/ships/blueprint-costs.js +1 -1
- package/dist/ships/blueprint-journal.d.ts +9 -8
- package/dist/ships/blueprint-journal.js +1 -1
- package/dist/ships/blueprints.d.ts +14 -12
- package/dist/ships/blueprints.js +1 -1
- package/dist/ships/build-metrics.d.ts +1061 -0
- package/dist/ships/build-metrics.js +1 -0
- package/dist/ships/build-metrics.js.map +1 -0
- package/dist/ships/distributor.d.ts +10 -3
- package/dist/ships/distributor.js +1 -1
- package/dist/ships/engineering-options.d.ts +8 -6
- package/dist/ships/engineering-options.js +1 -1
- package/dist/ships/engineering.d.ts +2 -16
- package/dist/ships/engineering.js +1 -1
- package/dist/ships/experimental-effect-costs.d.ts +5 -5
- package/dist/ships/experimental-effect-costs.js +1 -1
- package/dist/ships/experimental-effects.d.ts +9 -8
- package/dist/ships/experimental-effects.js +1 -1
- package/dist/ships/heat.d.ts +7 -2
- package/dist/ships/heat.js +1 -1
- package/dist/ships/index.d.ts +34 -22
- package/dist/ships/index.js +1 -1
- package/dist/ships/jump-range.d.ts +10 -3
- package/dist/ships/jump-range.js +1 -1
- package/dist/ships/loadout-calculations.d.ts +1 -1
- package/dist/ships/loadout-calculations.js +1 -1
- package/dist/ships/mobility-capacitor.d.ts +90 -0
- package/dist/ships/mobility-capacitor.js +1 -0
- package/dist/ships/mobility-capacitor.js.map +1 -0
- package/dist/ships/mobility.d.ts +41 -17
- package/dist/ships/mobility.js +1 -1
- package/dist/ships/modules-all.js +1 -1
- package/dist/ships/modules-core.js +1 -1
- package/dist/ships/modules.d.ts +27 -1
- package/dist/ships/modules.js +1 -1
- package/dist/ships/power.d.ts +12 -5
- package/dist/ships/power.js +1 -1
- package/dist/ships/pre-engineered-stats.d.ts +10 -8
- package/dist/ships/pre-engineered-stats.js +1 -1
- package/dist/ships/pre-engineered.d.ts +6 -6
- package/dist/ships/pre-engineered.js +1 -1
- package/dist/ships/resistances.d.ts +2 -2
- package/dist/ships/resistances.js +1 -1
- package/dist/ships/shield-capacitor.d.ts +133 -0
- package/dist/ships/shield-capacitor.js +1 -0
- package/dist/ships/shield-capacitor.js.map +1 -0
- package/dist/ships/shield-recovery.d.ts +16 -2
- package/dist/ships/shield-recovery.js +1 -1
- package/dist/ships/shields.d.ts +86 -28
- package/dist/ships/shields.js +1 -1
- package/dist/ships/ship-loadout.d.ts +100 -671
- package/dist/ships/ship-loadout.js +1 -1
- package/dist/ships/ships.d.ts +7 -6
- package/dist/ships/ships.js +1 -1
- package/dist/ships/slef.d.ts +11 -9
- package/dist/ships/slef.js +1 -1
- package/dist/ships/source-purchase.d.ts +2 -1
- package/dist/ships/source-purchase.js +1 -1
- package/dist/ships/weapons-capacitor.d.ts +10 -3
- package/dist/ships/weapons-capacitor.js +1 -1
- package/dist/ships/weapons.d.ts +22 -6
- package/dist/ships/weapons.js +1 -1
- package/dist/{system-address-DYsN1qOT.d.ts → system-address-cyJaeZIS.d.ts} +2 -1
- package/package.json +17 -2
- package/dist/chunk-24INI4U7.js +0 -1
- package/dist/chunk-24INI4U7.js.map +0 -1
- package/dist/chunk-2FHHMYDC.js +0 -1
- package/dist/chunk-2FHHMYDC.js.map +0 -1
- package/dist/chunk-2TW4ZBI3.js +0 -1
- package/dist/chunk-2TW4ZBI3.js.map +0 -1
- package/dist/chunk-2VPVZELZ.js +0 -1
- package/dist/chunk-4S6WB7QR.js.map +0 -1
- package/dist/chunk-DVL5RBKX.js +0 -1
- package/dist/chunk-DVL5RBKX.js.map +0 -1
- package/dist/chunk-DYPOL3CI.js.map +0 -1
- package/dist/chunk-EXVCRIDP.js +0 -1
- package/dist/chunk-EXVCRIDP.js.map +0 -1
- package/dist/chunk-FGXWVFN6.js +0 -1
- package/dist/chunk-FGXWVFN6.js.map +0 -1
- package/dist/chunk-FMPRCYKY.js.map +0 -1
- package/dist/chunk-G3265B27.js +0 -1
- package/dist/chunk-G3265B27.js.map +0 -1
- package/dist/chunk-GQ5GX5TB.js.map +0 -1
- package/dist/chunk-IOJXLDJN.js +0 -1
- package/dist/chunk-IOJXLDJN.js.map +0 -1
- package/dist/chunk-IYU4WLFM.js +0 -1
- package/dist/chunk-IYU4WLFM.js.map +0 -1
- package/dist/chunk-J42ZXLBL.js.map +0 -1
- package/dist/chunk-JPBMRJFC.js.map +0 -1
- package/dist/chunk-LJI7VXJD.js +0 -1
- package/dist/chunk-LJI7VXJD.js.map +0 -1
- package/dist/chunk-OCND33TO.js +0 -1
- package/dist/chunk-OCND33TO.js.map +0 -1
- package/dist/chunk-P2QOL63K.js +0 -1
- package/dist/chunk-P2QOL63K.js.map +0 -1
- package/dist/chunk-Q3QCLNVG.js.map +0 -1
- package/dist/chunk-QTZPA2FR.js.map +0 -1
- package/dist/chunk-RLUS76LZ.js +0 -1
- package/dist/chunk-RLUS76LZ.js.map +0 -1
- package/dist/chunk-TEOJCBSG.js +0 -1
- package/dist/chunk-TEOJCBSG.js.map +0 -1
- package/dist/chunk-TMMGS6TC.js +0 -1
- package/dist/chunk-TMMGS6TC.js.map +0 -1
- package/dist/chunk-W6EPHHTS.js.map +0 -1
- package/dist/chunk-Z6XMXMVI.js.map +0 -1
- package/dist/chunk-ZNCXENNB.js +0 -1
- package/dist/chunk-ZNCXENNB.js.map +0 -1
- package/dist/chunk-ZZT2PQZ5.js +0 -1
- package/dist/chunk-ZZT2PQZ5.js.map +0 -1
- /package/dist/{chunk-6EUVIZAS.js.map → chunk-4QYTVSNR.js.map} +0 -0
- /package/dist/{chunk-6EPYVBAX.js.map → chunk-A6OINYNP.js.map} +0 -0
- /package/dist/{chunk-VDVFJXX5.js.map → chunk-QY3L5BKN.js.map} +0 -0
|
@@ -39,7 +39,7 @@ import './slots.js';
|
|
|
39
39
|
*/
|
|
40
40
|
type BlueprintGradeCosts = Readonly<Record<string, readonly EngineeringMaterial[]>>;
|
|
41
41
|
/**
|
|
42
|
-
* Every craftable blueprint's per-roll material recipes, keyed by Frontier
|
|
42
|
+
* Every craftable blueprint's per-roll material recipes, keyed by Frontier symbol and then grade.
|
|
43
43
|
*
|
|
44
44
|
* @remarks
|
|
45
45
|
* Its ids and grade sets are the craftable subset of `BLUEPRINTS` from
|
|
@@ -59,7 +59,7 @@ declare const BLUEPRINT_COSTS: Readonly<Record<string, BlueprintGradeCosts>>;
|
|
|
59
59
|
/**
|
|
60
60
|
* Look up all per-grade material recipes for one blueprint.
|
|
61
61
|
*
|
|
62
|
-
* @param
|
|
62
|
+
* @param blueprintSymbol - The blueprint id, e.g. `"FSD_LongRange"`, matched
|
|
63
63
|
* case-insensitively after trimming surrounding whitespace.
|
|
64
64
|
* @remarks
|
|
65
65
|
* The material half only, straight from the catalogue. The Merc Coin some recipes charge
|
|
@@ -68,8 +68,8 @@ declare const BLUEPRINT_COSTS: Readonly<Record<string, BlueprintGradeCosts>>;
|
|
|
68
68
|
*
|
|
69
69
|
* @returns The frozen grade-to-material-list record, or `null` if no ordinary craft
|
|
70
70
|
* cost is catalogued (including a known fixed reward identity).
|
|
71
|
-
* @throws {TypeError} If `
|
|
72
|
-
* `
|
|
71
|
+
* @throws {TypeError} If `blueprintSymbol` is present and not a string. A nullish
|
|
72
|
+
* `blueprintSymbol` is a miss, answered the way an unrecognised one is.
|
|
73
73
|
* @example
|
|
74
74
|
* ```ts
|
|
75
75
|
* import { getBlueprintCosts } from '@elite-dangerous-almanac/core/ships/blueprint-costs';
|
|
@@ -78,7 +78,7 @@ declare const BLUEPRINT_COSTS: Readonly<Record<string, BlueprintGradeCosts>>;
|
|
|
78
78
|
* // -> [{ symbol: 'Arsenic', name: 'Arsenic', count: 1 }, ...]
|
|
79
79
|
* ```
|
|
80
80
|
*/
|
|
81
|
-
declare function getBlueprintCosts(
|
|
81
|
+
declare function getBlueprintCosts(blueprintSymbol: string): BlueprintGradeCosts | null;
|
|
82
82
|
/**
|
|
83
83
|
* What one engineering step costs — the materials it consumes and the Merc Coin billed
|
|
84
84
|
* beside them.
|
|
@@ -109,15 +109,15 @@ interface BlueprintCost {
|
|
|
109
109
|
/**
|
|
110
110
|
* Look up what **one roll** at one blueprint grade costs.
|
|
111
111
|
*
|
|
112
|
-
* @param
|
|
112
|
+
* @param blueprintSymbol - The blueprint id, e.g. `"FSD_LongRange"`, matched
|
|
113
113
|
* case-insensitively after trimming surrounding whitespace.
|
|
114
114
|
* @param grade - The grade, `1`–`5`.
|
|
115
115
|
* @returns The materials one roll consumes and the Merc Coin it bills, or `null` if no
|
|
116
116
|
* ordinary craft cost is catalogued for the blueprint and grade. `materials` is the
|
|
117
117
|
* frozen catalogue list; `mercCoins` is `0` unless the recipe charges a currency.
|
|
118
118
|
* @throws {RangeError} If `grade` is not an integer from 1 through 5.
|
|
119
|
-
* @throws {TypeError} If `
|
|
120
|
-
* `
|
|
119
|
+
* @throws {TypeError} If `blueprintSymbol` is present and not a string. A nullish
|
|
120
|
+
* `blueprintSymbol` is a miss, answered the way an unrecognised one is.
|
|
121
121
|
* @example
|
|
122
122
|
* ```ts
|
|
123
123
|
* import { getBlueprintGradeCost } from '@elite-dangerous-almanac/core/ships/blueprint-costs';
|
|
@@ -128,12 +128,15 @@ interface BlueprintCost {
|
|
|
128
128
|
* getBlueprintGradeCost('RailGun_LongShot', 5)?.mercCoins; // -> 50
|
|
129
129
|
* ```
|
|
130
130
|
*/
|
|
131
|
-
declare function getBlueprintGradeCost(
|
|
131
|
+
declare function getBlueprintGradeCost(blueprintSymbol: string, grade: number): BlueprintCost | null;
|
|
132
132
|
/**
|
|
133
133
|
* Compute the **total** cost of engineering a module up to a grade — every grade the
|
|
134
|
-
* module still has to climb, each rolled the number of times it takes to complete
|
|
135
|
-
*
|
|
136
|
-
*
|
|
134
|
+
* module still has to climb, each rolled the number of times it takes to complete,
|
|
135
|
+
* summed into one shopping list and one Merc Coin total.
|
|
136
|
+
*
|
|
137
|
+
* **Grade `N` takes `N` rolls** to fill its progress bar (grade 1 → 1 roll, grade 2 → 2
|
|
138
|
+
* rolls, … grade 5 → 5 rolls), and each roll costs that grade's recipe once, so the
|
|
139
|
+
* climb is weighted rather than a plain sum — for the materials and the Merc Coin alike.
|
|
137
140
|
*
|
|
138
141
|
* By default it prices the whole climb from unengineered; pass `currentGrade` to price
|
|
139
142
|
* only what remains. Each grade `g` in `currentGrade + 1 … grade` contributes
|
|
@@ -153,7 +156,7 @@ declare function getBlueprintGradeCost(fdname: string, grade: number): Blueprint
|
|
|
153
156
|
* same at every grade. Either spelling therefore prices correctly without a fitted
|
|
154
157
|
* module; cross-catalogue tests pin that invariant.
|
|
155
158
|
*
|
|
156
|
-
* @param
|
|
159
|
+
* @param blueprintSymbol - The blueprint id, e.g. `"FSD_LongRange"`, matched
|
|
157
160
|
* case-insensitively after trimming surrounding whitespace.
|
|
158
161
|
* @param grade - The target grade, `1`–`5`.
|
|
159
162
|
* @param currentGrade - The completed grade, `0`–`5`; defaults to `0` for an
|
|
@@ -166,8 +169,8 @@ declare function getBlueprintGradeCost(fdname: string, grade: number): Blueprint
|
|
|
166
169
|
* charges no currency, so `null` remains the one answer meaning "not catalogued".
|
|
167
170
|
* @throws {RangeError} If `grade` is not an integer from 1 through 5, or `currentGrade`
|
|
168
171
|
* is not an integer from 0 through 5.
|
|
169
|
-
* @throws {TypeError} If `
|
|
170
|
-
* `
|
|
172
|
+
* @throws {TypeError} If `blueprintSymbol` is present and not a string. A nullish
|
|
173
|
+
* `blueprintSymbol` is a miss, answered the way an unrecognised one is.
|
|
171
174
|
* @example
|
|
172
175
|
* ```ts
|
|
173
176
|
* import { getBlueprintCost } from '@elite-dangerous-almanac/core/ships/blueprint-costs';
|
|
@@ -181,7 +184,7 @@ declare function getBlueprintGradeCost(fdname: string, grade: number): Blueprint
|
|
|
181
184
|
* getBlueprintCost('FuelScoop_Efficiency', 5)?.mercCoins; // -> 350
|
|
182
185
|
* ```
|
|
183
186
|
*/
|
|
184
|
-
declare function getBlueprintCost(
|
|
187
|
+
declare function getBlueprintCost(blueprintSymbol: string, grade: number, currentGrade?: number): BlueprintCost | null;
|
|
185
188
|
/**
|
|
186
189
|
* Merc Coin charged for **one roll** of a blueprint, keyed by grade (`"1"`–`"5"`).
|
|
187
190
|
*
|
|
@@ -195,7 +198,7 @@ declare function getBlueprintCost(fdname: string, grade: number, currentGrade?:
|
|
|
195
198
|
type BlueprintMercCoinCosts = Readonly<Record<string, number>>;
|
|
196
199
|
/**
|
|
197
200
|
* The Merc Coin charged per roll by every blueprint that charges any, keyed by Frontier
|
|
198
|
-
*
|
|
201
|
+
* symbol and then grade.
|
|
199
202
|
*
|
|
200
203
|
* @remarks
|
|
201
204
|
* The raw catalogue behind {@link BlueprintCost.mercCoins}; reach for
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{BLUEPRINT_COSTS,BLUEPRINT_MERC_COIN_COSTS,getBlueprintCost,getBlueprintCosts,getBlueprintGradeCost}from"../chunk-
|
|
1
|
+
export{BLUEPRINT_COSTS,BLUEPRINT_MERC_COIN_COSTS,getBlueprintCost,getBlueprintCosts,getBlueprintGradeCost}from"../chunk-MTJ4MS7W.js"; //# sourceMappingURL=blueprint-costs.js.map
|
|
@@ -39,17 +39,18 @@
|
|
|
39
39
|
* unaffected — both spellings of a pair bill the same at every grade, so
|
|
40
40
|
* `getBlueprintCost` needs no module.
|
|
41
41
|
*
|
|
42
|
-
* @param
|
|
43
|
-
* @param
|
|
44
|
-
* trimmed. Colliding journal spellings are resolved against `
|
|
42
|
+
* @param moduleSymbol - A module symbol, e.g. `"Hpt_CloudScanner_Size0_Class5"`.
|
|
43
|
+
* @param blueprintSymbol - A blueprint catalogue or journal id, matched case-insensitively and
|
|
44
|
+
* trimmed. Colliding journal spellings are resolved against `moduleSymbol`.
|
|
45
45
|
* @returns The id to join to `BLUEPRINTS`, in that catalogue's spelling when a journal
|
|
46
|
-
* name resolved, and otherwise `
|
|
46
|
+
* name resolved, and otherwise `blueprintSymbol` exactly as it was passed — byte for byte, so a
|
|
47
47
|
* caller who never meets the collision never sees their own spelling rewritten.
|
|
48
48
|
*
|
|
49
|
-
* @throws {TypeError} If `
|
|
49
|
+
* @throws {TypeError} If `blueprintSymbol` is not a string, including when it is missing — this
|
|
50
50
|
* returns an id rather than reporting whether one is known, so there is no miss for a
|
|
51
|
-
* nullish one to be. A nullish `
|
|
52
|
-
*
|
|
51
|
+
* nullish one to be. A nullish `moduleSymbol` *is* a miss: an unknown module offers no
|
|
52
|
+
* menu,
|
|
53
|
+
* and `blueprintSymbol` comes back unchanged.
|
|
53
54
|
* @example
|
|
54
55
|
* ```ts
|
|
55
56
|
* import { resolveBlueprintForModule } from '@elite-dangerous-almanac/core/ships/blueprint-journal';
|
|
@@ -69,6 +70,6 @@
|
|
|
69
70
|
* // -> 'Weapon_Overcharged'
|
|
70
71
|
* ```
|
|
71
72
|
*/
|
|
72
|
-
declare function resolveBlueprintForModule(
|
|
73
|
+
declare function resolveBlueprintForModule(moduleSymbol: string, blueprintSymbol: string): string;
|
|
73
74
|
|
|
74
75
|
export { resolveBlueprintForModule };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{resolveBlueprintForModule}from"../chunk-
|
|
1
|
+
export{resolveBlueprintForModule}from"../chunk-OLKNYGGT.js"; //# sourceMappingURL=blueprint-journal.js.map
|
|
@@ -7,7 +7,7 @@ import './slots.js';
|
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* The **blueprint mechanics catalogue** — every engineering blueprint's per-grade stat
|
|
10
|
-
* modifiers, keyed by the blueprint's Frontier
|
|
10
|
+
* modifiers, keyed by the blueprint's Frontier symbol
|
|
11
11
|
* (as it appears in a journal `Loadout` event's `Engineering.BlueprintName`).
|
|
12
12
|
*
|
|
13
13
|
* Its own module (and data file) so consumers who never engineer a build do not bundle
|
|
@@ -18,7 +18,7 @@ import './slots.js';
|
|
|
18
18
|
* costs — though `ShipLoadout` carries both, since it prices a build as well as
|
|
19
19
|
* engineering one.
|
|
20
20
|
*
|
|
21
|
-
* Keys are Frontier
|
|
21
|
+
* Keys are Frontier symbols — normally the exact strings a journal `Loadout` event
|
|
22
22
|
* carries in `Engineering.BlueprintName` (e.g. `"FSD_LongRange"`), not the in-game display
|
|
23
23
|
* names. **Three keys collide**: each is a recipe the game writes under an id another
|
|
24
24
|
* record already answers to:
|
|
@@ -49,7 +49,7 @@ import './slots.js';
|
|
|
49
49
|
*/
|
|
50
50
|
|
|
51
51
|
/**
|
|
52
|
-
* Every blueprint, keyed by Frontier
|
|
52
|
+
* Every blueprint, keyed by Frontier symbol (e.g. `"FSD_LongRange"`). Each is a
|
|
53
53
|
* {@link Blueprint} — its display `name` and its per-grade `grades`, where each grade
|
|
54
54
|
* carries its `features` (modifiers) and optional converted `damageDistribution`.
|
|
55
55
|
*
|
|
@@ -65,9 +65,10 @@ import './slots.js';
|
|
|
65
65
|
*/
|
|
66
66
|
declare const BLUEPRINTS: Readonly<Record<string, Blueprint>>;
|
|
67
67
|
/**
|
|
68
|
-
* Look up a blueprint by its Frontier
|
|
68
|
+
* Look up a blueprint by its Frontier symbol, case-insensitively.
|
|
69
69
|
*
|
|
70
|
-
* @param
|
|
70
|
+
* @param blueprintSymbol - The blueprint id, e.g. `"FSD_LongRange"`. Leading/trailing
|
|
71
|
+
* whitespace and case are ignored.
|
|
71
72
|
* @returns The blueprint (its `name` and `grades`), or `null` if this catalogue stores no
|
|
72
73
|
* blueprint under that id.
|
|
73
74
|
* @remarks
|
|
@@ -77,21 +78,22 @@ declare const BLUEPRINTS: Readonly<Record<string, Blueprint>>;
|
|
|
77
78
|
* engineer — and are carried by the variants returned from
|
|
78
79
|
* `getPreEngineeredVariants` in `ships/pre-engineered`. Their fixed modifiers still
|
|
79
80
|
* change the fitted article's stats.
|
|
80
|
-
* @throws {TypeError} If `
|
|
81
|
-
* `
|
|
81
|
+
* @throws {TypeError} If `blueprintSymbol` is present and not a string. A nullish
|
|
82
|
+
* `blueprintSymbol` is a miss, answered the way an unrecognised one is.
|
|
82
83
|
*/
|
|
83
|
-
declare function getBlueprint(
|
|
84
|
+
declare function getBlueprint(blueprintSymbol: string): Blueprint | null;
|
|
84
85
|
/**
|
|
85
86
|
* Look up one complete grade of a blueprint, case-insensitively.
|
|
86
87
|
*
|
|
87
|
-
* @param
|
|
88
|
+
* @param blueprintSymbol - The blueprint id, e.g. `"FSD_LongRange"`. Leading/trailing
|
|
89
|
+
* whitespace and case are ignored.
|
|
88
90
|
* @param grade - The grade, `1`–`5`.
|
|
89
91
|
* @returns The grade record — its modifier `features` and optional converted
|
|
90
92
|
* `damageDistribution` — or `null` if the catalogue holds no such blueprint or grade.
|
|
91
93
|
* See {@link getBlueprint} for what an absent blueprint can mean besides "unknown".
|
|
92
94
|
* @throws {RangeError} If `grade` is not an integer from 1 through 5.
|
|
93
|
-
* @throws {TypeError} If `
|
|
94
|
-
* `
|
|
95
|
+
* @throws {TypeError} If `blueprintSymbol` is present and not a string. A nullish
|
|
96
|
+
* `blueprintSymbol` is a miss, answered the way an unrecognised one is.
|
|
95
97
|
* @example
|
|
96
98
|
* ```ts
|
|
97
99
|
* import { getBlueprintGrade } from '@elite-dangerous-almanac/core/ships/blueprints';
|
|
@@ -100,6 +102,6 @@ declare function getBlueprint(fdname: string): Blueprint | null;
|
|
|
100
102
|
* grade?.features; // -> [{ label: 'Integrity', ... }, ...]
|
|
101
103
|
* ```
|
|
102
104
|
*/
|
|
103
|
-
declare function getBlueprintGrade(
|
|
105
|
+
declare function getBlueprintGrade(blueprintSymbol: string, grade: number): BlueprintGrade | null;
|
|
104
106
|
|
|
105
107
|
export { BLUEPRINTS, getBlueprint, getBlueprintGrade };
|
package/dist/ships/blueprints.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{BLUEPRINTS,getBlueprint,getBlueprintGrade}from"../chunk-
|
|
1
|
+
export{BLUEPRINTS,getBlueprint,getBlueprintGrade}from"../chunk-AYAKU4YA.js"; //# sourceMappingURL=blueprints.js.map
|