@elite-dangerous-almanac/core 0.1.0-beta.1
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/LICENSE +48 -0
- package/PROVENANCE/SNAPSHOTS.md +36 -0
- package/PROVENANCE/astro/SOURCES.md +94 -0
- package/PROVENANCE/commodities/SOURCES.md +41 -0
- package/PROVENANCE/materials/SOURCES.md +69 -0
- package/PROVENANCE/ships/SOURCES.md +1580 -0
- package/README.md +148 -0
- package/THIRD_PARTY_NOTICES.md +202 -0
- package/dist/astro/codex-region-lookup.d.ts +169 -0
- package/dist/astro/codex-region-lookup.js +1 -0
- package/dist/astro/codex-region-lookup.js.map +1 -0
- package/dist/astro/codex-region.d.ts +149 -0
- package/dist/astro/codex-region.js +1 -0
- package/dist/astro/codex-region.js.map +1 -0
- package/dist/astro/galaxy-grid.d.ts +83 -0
- package/dist/astro/galaxy-grid.js +1 -0
- package/dist/astro/galaxy-grid.js.map +1 -0
- package/dist/astro/hand-authored-regions.d.ts +121 -0
- package/dist/astro/hand-authored-regions.js +1 -0
- package/dist/astro/hand-authored-regions.js.map +1 -0
- package/dist/astro/index.d.ts +140 -0
- package/dist/astro/index.js +1 -0
- package/dist/astro/index.js.map +1 -0
- package/dist/astro/mass-code.d.ts +55 -0
- package/dist/astro/mass-code.js +1 -0
- package/dist/astro/mass-code.js.map +1 -0
- package/dist/astro/naming-region-origins.d.ts +4 -0
- package/dist/astro/naming-region-origins.js +1 -0
- package/dist/astro/naming-region-origins.js.map +1 -0
- package/dist/astro/nebulae-all.d.ts +40 -0
- package/dist/astro/nebulae-all.js +1 -0
- package/dist/astro/nebulae-all.js.map +1 -0
- package/dist/astro/nebulae-planetary.d.ts +37 -0
- package/dist/astro/nebulae-planetary.js +1 -0
- package/dist/astro/nebulae-planetary.js.map +1 -0
- package/dist/astro/nebulae-procgen.d.ts +36 -0
- package/dist/astro/nebulae-procgen.js +1 -0
- package/dist/astro/nebulae-procgen.js.map +1 -0
- package/dist/astro/nebulae-real.d.ts +37 -0
- package/dist/astro/nebulae-real.js +1 -0
- package/dist/astro/nebulae-real.js.map +1 -0
- package/dist/astro/nebulae.d.ts +169 -0
- package/dist/astro/nebulae.js +1 -0
- package/dist/astro/nebulae.js.map +1 -0
- package/dist/astro/permit-locked-regions.d.ts +54 -0
- package/dist/astro/permit-locked-regions.js +1 -0
- package/dist/astro/permit-locked-regions.js.map +1 -0
- package/dist/astro/permit-locked-systems.d.ts +74 -0
- package/dist/astro/permit-locked-systems.js +1 -0
- package/dist/astro/permit-locked-systems.js.map +1 -0
- package/dist/astro/permit-locks.d.ts +130 -0
- package/dist/astro/permit-locks.js +1 -0
- package/dist/astro/permit-locks.js.map +1 -0
- package/dist/astro/procedural-system.d.ts +228 -0
- package/dist/astro/procedural-system.js +1 -0
- package/dist/astro/procedural-system.js.map +1 -0
- package/dist/astro/sector-name.d.ts +87 -0
- package/dist/astro/sector-name.js +1 -0
- package/dist/astro/sector-name.js.map +1 -0
- package/dist/astro/system-address-input.d.ts +76 -0
- package/dist/astro/system-address-input.js +1 -0
- package/dist/astro/system-address-input.js.map +1 -0
- package/dist/astro/system-address.d.ts +4 -0
- package/dist/astro/system-address.js +1 -0
- package/dist/astro/system-address.js.map +1 -0
- package/dist/astro/system-name.d.ts +187 -0
- package/dist/astro/system-name.js +1 -0
- package/dist/astro/system-name.js.map +1 -0
- package/dist/chunk-2FHHMYDC.js +1 -0
- package/dist/chunk-2FHHMYDC.js.map +1 -0
- package/dist/chunk-462OKHXR.js +1 -0
- package/dist/chunk-462OKHXR.js.map +1 -0
- package/dist/chunk-5H74FKY7.js +1 -0
- package/dist/chunk-5H74FKY7.js.map +1 -0
- package/dist/chunk-6LUEKHO5.js +1 -0
- package/dist/chunk-6LUEKHO5.js.map +1 -0
- package/dist/chunk-76XKY2Y2.js +1 -0
- package/dist/chunk-76XKY2Y2.js.map +1 -0
- package/dist/chunk-7EE5VIHR.js +1 -0
- package/dist/chunk-7EE5VIHR.js.map +1 -0
- package/dist/chunk-A3NM7SAJ.js +1 -0
- package/dist/chunk-A3NM7SAJ.js.map +1 -0
- package/dist/chunk-A6XPYSVR.js +1 -0
- package/dist/chunk-A6XPYSVR.js.map +1 -0
- package/dist/chunk-AA3K5XUE.js +1 -0
- package/dist/chunk-AA3K5XUE.js.map +1 -0
- package/dist/chunk-AVZI6VKA.js +1 -0
- package/dist/chunk-AVZI6VKA.js.map +1 -0
- package/dist/chunk-B5TT26XE.js +1 -0
- package/dist/chunk-B5TT26XE.js.map +1 -0
- package/dist/chunk-BNILZXJD.js +1 -0
- package/dist/chunk-BNILZXJD.js.map +1 -0
- package/dist/chunk-BRDQUJXV.js +1 -0
- package/dist/chunk-BRDQUJXV.js.map +1 -0
- package/dist/chunk-BTPV5CIF.js +1 -0
- package/dist/chunk-BTPV5CIF.js.map +1 -0
- package/dist/chunk-CI3ACMRA.js +1 -0
- package/dist/chunk-CI3ACMRA.js.map +1 -0
- package/dist/chunk-COE5ADYJ.js +1 -0
- package/dist/chunk-COE5ADYJ.js.map +1 -0
- package/dist/chunk-CWAX3BSH.js +1 -0
- package/dist/chunk-CWAX3BSH.js.map +1 -0
- package/dist/chunk-DACZE3HX.js +1 -0
- package/dist/chunk-DACZE3HX.js.map +1 -0
- package/dist/chunk-DURKO7JU.js +1 -0
- package/dist/chunk-DURKO7JU.js.map +1 -0
- package/dist/chunk-E45EDCYH.js +1 -0
- package/dist/chunk-E45EDCYH.js.map +1 -0
- package/dist/chunk-ELIZXUMI.js +1 -0
- package/dist/chunk-ELIZXUMI.js.map +1 -0
- package/dist/chunk-EYGVDJ2I.js +1 -0
- package/dist/chunk-EYGVDJ2I.js.map +1 -0
- package/dist/chunk-FGXWVFN6.js +1 -0
- package/dist/chunk-FGXWVFN6.js.map +1 -0
- package/dist/chunk-GJCB2Z72.js +1 -0
- package/dist/chunk-GJCB2Z72.js.map +1 -0
- package/dist/chunk-HI7FCS3G.js +1 -0
- package/dist/chunk-HI7FCS3G.js.map +1 -0
- package/dist/chunk-HKXXFIRI.js +1 -0
- package/dist/chunk-HKXXFIRI.js.map +1 -0
- package/dist/chunk-HTB52N6S.js +1 -0
- package/dist/chunk-HTB52N6S.js.map +1 -0
- package/dist/chunk-I7PIDRMU.js +1 -0
- package/dist/chunk-I7PIDRMU.js.map +1 -0
- package/dist/chunk-IH4NXKVW.js +1 -0
- package/dist/chunk-IH4NXKVW.js.map +1 -0
- package/dist/chunk-INNFH37U.js +1 -0
- package/dist/chunk-INNFH37U.js.map +1 -0
- package/dist/chunk-J2PNZQY4.js +1 -0
- package/dist/chunk-J2PNZQY4.js.map +1 -0
- package/dist/chunk-JQG4C67D.js +1 -0
- package/dist/chunk-JQG4C67D.js.map +1 -0
- package/dist/chunk-JTQVWIGL.js +1 -0
- package/dist/chunk-JTQVWIGL.js.map +1 -0
- package/dist/chunk-JWJ7RSZC.js +1 -0
- package/dist/chunk-JWJ7RSZC.js.map +1 -0
- package/dist/chunk-K3AMV27L.js +1 -0
- package/dist/chunk-K3AMV27L.js.map +1 -0
- package/dist/chunk-K7F6WC4T.js +1 -0
- package/dist/chunk-K7F6WC4T.js.map +1 -0
- package/dist/chunk-K7L7SMIR.js +1 -0
- package/dist/chunk-K7L7SMIR.js.map +1 -0
- package/dist/chunk-KG4EWDZZ.js +1 -0
- package/dist/chunk-KG4EWDZZ.js.map +1 -0
- package/dist/chunk-KMFUCORC.js +1 -0
- package/dist/chunk-KMFUCORC.js.map +1 -0
- package/dist/chunk-L2ZZXEZM.js +1 -0
- package/dist/chunk-L2ZZXEZM.js.map +1 -0
- package/dist/chunk-L747RVPO.js +1 -0
- package/dist/chunk-L747RVPO.js.map +1 -0
- package/dist/chunk-MFV4VZFP.js +1 -0
- package/dist/chunk-MFV4VZFP.js.map +1 -0
- package/dist/chunk-NWPK6Q3S.js +1 -0
- package/dist/chunk-NWPK6Q3S.js.map +1 -0
- package/dist/chunk-PMJG7PHU.js +1 -0
- package/dist/chunk-PMJG7PHU.js.map +1 -0
- package/dist/chunk-PP2VSA6M.js +1 -0
- package/dist/chunk-PP2VSA6M.js.map +1 -0
- package/dist/chunk-Q22LXT53.js +1 -0
- package/dist/chunk-Q22LXT53.js.map +1 -0
- package/dist/chunk-Q5MR36RW.js +1 -0
- package/dist/chunk-Q5MR36RW.js.map +1 -0
- package/dist/chunk-Q5XOGATC.js +1 -0
- package/dist/chunk-Q5XOGATC.js.map +1 -0
- package/dist/chunk-QTDBO7R2.js +1 -0
- package/dist/chunk-QTDBO7R2.js.map +1 -0
- package/dist/chunk-R4OD62HV.js +1 -0
- package/dist/chunk-R4OD62HV.js.map +1 -0
- package/dist/chunk-RD73TFGS.js +1 -0
- package/dist/chunk-RD73TFGS.js.map +1 -0
- package/dist/chunk-RIT6MOO5.js +1 -0
- package/dist/chunk-RIT6MOO5.js.map +1 -0
- package/dist/chunk-RVSXKQHE.js +1 -0
- package/dist/chunk-RVSXKQHE.js.map +1 -0
- package/dist/chunk-S4DBNX2B.js +1 -0
- package/dist/chunk-S4DBNX2B.js.map +1 -0
- package/dist/chunk-S4UWCHL6.js +1 -0
- package/dist/chunk-S4UWCHL6.js.map +1 -0
- package/dist/chunk-SQS7672E.js +1 -0
- package/dist/chunk-SQS7672E.js.map +1 -0
- package/dist/chunk-TLNHETGC.js +1 -0
- package/dist/chunk-TLNHETGC.js.map +1 -0
- package/dist/chunk-U6TMCYA6.js +1 -0
- package/dist/chunk-U6TMCYA6.js.map +1 -0
- package/dist/chunk-V4C6FIE2.js +1 -0
- package/dist/chunk-V4C6FIE2.js.map +1 -0
- package/dist/chunk-VXVUEF5U.js +1 -0
- package/dist/chunk-VXVUEF5U.js.map +1 -0
- package/dist/chunk-VZXL5KBR.js +1 -0
- package/dist/chunk-VZXL5KBR.js.map +1 -0
- package/dist/chunk-VZZ2XIRE.js +1 -0
- package/dist/chunk-VZZ2XIRE.js.map +1 -0
- package/dist/chunk-WV5YM7H5.js +1 -0
- package/dist/chunk-WV5YM7H5.js.map +1 -0
- package/dist/chunk-Y2MUIE5W.js +1 -0
- package/dist/chunk-Y2MUIE5W.js.map +1 -0
- package/dist/chunk-Z43DN4PY.js +1 -0
- package/dist/chunk-Z43DN4PY.js.map +1 -0
- package/dist/chunk-Z4GTTB7I.js +1 -0
- package/dist/chunk-Z4GTTB7I.js.map +1 -0
- package/dist/chunk-Z4OUB4SJ.js +1 -0
- package/dist/chunk-Z4OUB4SJ.js.map +1 -0
- package/dist/chunk-ZFT56QFR.js +1 -0
- package/dist/chunk-ZFT56QFR.js.map +1 -0
- package/dist/chunk-ZNCXENNB.js +1 -0
- package/dist/chunk-ZNCXENNB.js.map +1 -0
- package/dist/commodities/commodities-all.d.ts +25 -0
- package/dist/commodities/commodities-all.js +1 -0
- package/dist/commodities/commodities-all.js.map +1 -0
- package/dist/commodities/commodities-rare.d.ts +34 -0
- package/dist/commodities/commodities-rare.js +1 -0
- package/dist/commodities/commodities-rare.js.map +1 -0
- package/dist/commodities/commodities-standard.d.ts +34 -0
- package/dist/commodities/commodities-standard.js +1 -0
- package/dist/commodities/commodities-standard.js.map +1 -0
- package/dist/commodities/commodities.d.ts +142 -0
- package/dist/commodities/commodities.js +1 -0
- package/dist/commodities/commodities.js.map +1 -0
- package/dist/commodities/index.d.ts +30 -0
- package/dist/commodities/index.js +1 -0
- package/dist/commodities/index.js.map +1 -0
- package/dist/galactic-position-shLkm4Qg.d.ts +30 -0
- package/dist/materials/index.d.ts +47 -0
- package/dist/materials/index.js +1 -0
- package/dist/materials/index.js.map +1 -0
- package/dist/materials/materials-all.d.ts +26 -0
- package/dist/materials/materials-all.js +1 -0
- package/dist/materials/materials-all.js.map +1 -0
- package/dist/materials/materials-encoded.d.ts +31 -0
- package/dist/materials/materials-encoded.js +1 -0
- package/dist/materials/materials-encoded.js.map +1 -0
- package/dist/materials/materials-manufactured.d.ts +32 -0
- package/dist/materials/materials-manufactured.js +1 -0
- package/dist/materials/materials-manufactured.js.map +1 -0
- package/dist/materials/materials-raw.d.ts +31 -0
- package/dist/materials/materials-raw.js +1 -0
- package/dist/materials/materials-raw.js.map +1 -0
- package/dist/materials/materials.d.ts +277 -0
- package/dist/materials/materials.js +1 -0
- package/dist/materials/materials.js.map +1 -0
- package/dist/materials/micro-resources-all.d.ts +28 -0
- package/dist/materials/micro-resources-all.js +1 -0
- package/dist/materials/micro-resources-all.js.map +1 -0
- package/dist/materials/micro-resources-component.d.ts +29 -0
- package/dist/materials/micro-resources-component.js +1 -0
- package/dist/materials/micro-resources-component.js.map +1 -0
- package/dist/materials/micro-resources-consumable.d.ts +29 -0
- package/dist/materials/micro-resources-consumable.js +1 -0
- package/dist/materials/micro-resources-consumable.js.map +1 -0
- package/dist/materials/micro-resources-data.d.ts +29 -0
- package/dist/materials/micro-resources-data.js +1 -0
- package/dist/materials/micro-resources-data.js.map +1 -0
- package/dist/materials/micro-resources-item.d.ts +29 -0
- package/dist/materials/micro-resources-item.js +1 -0
- package/dist/materials/micro-resources-item.js.map +1 -0
- package/dist/materials/micro-resources.d.ts +136 -0
- package/dist/materials/micro-resources.js +1 -0
- package/dist/materials/micro-resources.js.map +1 -0
- package/dist/ship-loadout-Ba63RDf-.d.ts +1059 -0
- package/dist/ships/ammunition.d.ts +107 -0
- package/dist/ships/ammunition.js +1 -0
- package/dist/ships/ammunition.js.map +1 -0
- package/dist/ships/armour.d.ts +134 -0
- package/dist/ships/armour.js +1 -0
- package/dist/ships/armour.js.map +1 -0
- package/dist/ships/blueprint-costs.d.ts +128 -0
- package/dist/ships/blueprint-costs.js +1 -0
- package/dist/ships/blueprint-costs.js.map +1 -0
- package/dist/ships/blueprint-journal.d.ts +116 -0
- package/dist/ships/blueprint-journal.js +1 -0
- package/dist/ships/blueprint-journal.js.map +1 -0
- package/dist/ships/blueprints.d.ts +103 -0
- package/dist/ships/blueprints.js +1 -0
- package/dist/ships/blueprints.js.map +1 -0
- package/dist/ships/decorative-modifications.d.ts +176 -0
- package/dist/ships/decorative-modifications.js +1 -0
- package/dist/ships/decorative-modifications.js.map +1 -0
- package/dist/ships/engineering-options.d.ts +246 -0
- package/dist/ships/engineering-options.js +1 -0
- package/dist/ships/engineering-options.js.map +1 -0
- package/dist/ships/engineering.d.ts +229 -0
- package/dist/ships/engineering.js +1 -0
- package/dist/ships/engineering.js.map +1 -0
- package/dist/ships/experimental-effect-costs.d.ts +56 -0
- package/dist/ships/experimental-effect-costs.js +1 -0
- package/dist/ships/experimental-effect-costs.js.map +1 -0
- package/dist/ships/experimental-effects.d.ts +62 -0
- package/dist/ships/experimental-effects.js +1 -0
- package/dist/ships/experimental-effects.js.map +1 -0
- package/dist/ships/index.d.ts +205 -0
- package/dist/ships/index.js +1 -0
- package/dist/ships/index.js.map +1 -0
- package/dist/ships/jump-range.d.ts +115 -0
- package/dist/ships/jump-range.js +1 -0
- package/dist/ships/jump-range.js.map +1 -0
- package/dist/ships/loadout-calculations.d.ts +109 -0
- package/dist/ships/loadout-calculations.js +1 -0
- package/dist/ships/loadout-calculations.js.map +1 -0
- package/dist/ships/loadout-validation.d.ts +80 -0
- package/dist/ships/loadout-validation.js +1 -0
- package/dist/ships/loadout-validation.js.map +1 -0
- package/dist/ships/module-capabilities.d.ts +205 -0
- package/dist/ships/module-capabilities.js +1 -0
- package/dist/ships/module-capabilities.js.map +1 -0
- package/dist/ships/modules-all.d.ts +43 -0
- package/dist/ships/modules-all.js +1 -0
- package/dist/ships/modules-all.js.map +1 -0
- package/dist/ships/modules-core.d.ts +40 -0
- package/dist/ships/modules-core.js +1 -0
- package/dist/ships/modules-core.js.map +1 -0
- package/dist/ships/modules-hardpoint.d.ts +42 -0
- package/dist/ships/modules-hardpoint.js +1 -0
- package/dist/ships/modules-hardpoint.js.map +1 -0
- package/dist/ships/modules-internal.d.ts +40 -0
- package/dist/ships/modules-internal.js +1 -0
- package/dist/ships/modules-internal.js.map +1 -0
- package/dist/ships/modules-utility.d.ts +40 -0
- package/dist/ships/modules-utility.js +1 -0
- package/dist/ships/modules-utility.js.map +1 -0
- package/dist/ships/modules.d.ts +755 -0
- package/dist/ships/modules.js +1 -0
- package/dist/ships/modules.js.map +1 -0
- package/dist/ships/power.d.ts +168 -0
- package/dist/ships/power.js +1 -0
- package/dist/ships/power.js.map +1 -0
- package/dist/ships/pre-engineered-stats.d.ts +147 -0
- package/dist/ships/pre-engineered-stats.js +1 -0
- package/dist/ships/pre-engineered-stats.js.map +1 -0
- package/dist/ships/pre-engineered.d.ts +215 -0
- package/dist/ships/pre-engineered.js +1 -0
- package/dist/ships/pre-engineered.js.map +1 -0
- package/dist/ships/resistances.d.ts +208 -0
- package/dist/ships/resistances.js +1 -0
- package/dist/ships/resistances.js.map +1 -0
- package/dist/ships/shields.d.ts +221 -0
- package/dist/ships/shields.js +1 -0
- package/dist/ships/shields.js.map +1 -0
- package/dist/ships/ship-loadout.d.ts +16 -0
- package/dist/ships/ship-loadout.js +1 -0
- package/dist/ships/ship-loadout.js.map +1 -0
- package/dist/ships/ships.d.ts +191 -0
- package/dist/ships/ships.js +1 -0
- package/dist/ships/ships.js.map +1 -0
- package/dist/ships/slef.d.ts +318 -0
- package/dist/ships/slef.js +1 -0
- package/dist/ships/slef.js.map +1 -0
- package/dist/ships/slots.d.ts +418 -0
- package/dist/ships/slots.js +1 -0
- package/dist/ships/slots.js.map +1 -0
- package/dist/ships/source-purchase.d.ts +132 -0
- package/dist/ships/source-purchase.js +1 -0
- package/dist/ships/source-purchase.js.map +1 -0
- package/dist/ships/weapons.d.ts +380 -0
- package/dist/ships/weapons.js +1 -0
- package/dist/ships/weapons.js.map +1 -0
- package/dist/system-address-DYsN1qOT.d.ts +313 -0
- package/package.json +375 -0
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { Nebula } from './nebulae.js';
|
|
2
|
+
import '../galactic-position-shLkm4Qg.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* The catalogue of **planetary** nebulae — 5489 of them, the largest class in the
|
|
6
|
+
* catalogue, each catalogued at the procedurally-named system it surrounds.
|
|
7
|
+
*
|
|
8
|
+
* @remarks
|
|
9
|
+
* **This is the heaviest data module in the library (~399 KiB bundled).** Import it
|
|
10
|
+
* only when you genuinely need every planetary nebula; for the 180 recognisable
|
|
11
|
+
* real-world nebulae use `./nebulae-real` instead (~16 KiB). Because each catalogue
|
|
12
|
+
* is its own module, importing that one never pulls this one in.
|
|
13
|
+
*
|
|
14
|
+
* Data from EDAstro; see [ATTRIBUTIONS.md](https://github.com/DarkSession/Elite-Dangerous-Almanac/blob/main/ATTRIBUTIONS.md) for credit and licence terms.
|
|
15
|
+
*
|
|
16
|
+
* @packageDocumentation
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* All 5489 planetary nebulae, sorted by name.
|
|
21
|
+
*
|
|
22
|
+
* @remarks
|
|
23
|
+
* Every record has `type: 'planetary'`. `name` is normally identical to `system`;
|
|
24
|
+
* where explorers have given one a community name it is appended in parentheses
|
|
25
|
+
* (`"Aemonz WZ-Y e6771 (Lazurite Nebula)"`).
|
|
26
|
+
*
|
|
27
|
+
* @example
|
|
28
|
+
* ```ts
|
|
29
|
+
* import { PLANETARY_NEBULAE } from '@elite-dangerous-almanac/core/astro/nebulae-planetary';
|
|
30
|
+
*
|
|
31
|
+
* PLANETARY_NEBULAE.length; // -> 5489
|
|
32
|
+
* PLANETARY_NEBULAE[0]?.name; // -> 'Aemonz EQ-Y e1899'
|
|
33
|
+
* ```
|
|
34
|
+
*/
|
|
35
|
+
declare const PLANETARY_NEBULAE: readonly Nebula[];
|
|
36
|
+
|
|
37
|
+
export { PLANETARY_NEBULAE };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{PLANETARY_NEBULAE}from"../chunk-Z4OUB4SJ.js"; //# sourceMappingURL=nebulae-planetary.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"O"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { Nebula } from './nebulae.js';
|
|
2
|
+
import '../galactic-position-shLkm4Qg.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* The catalogue of **procedurally generated** nebulae — 166 nebulae the galaxy
|
|
6
|
+
* generator places out in the black, catalogued at a nearby system.
|
|
7
|
+
*
|
|
8
|
+
* Their names follow the procedural scheme of the sector they sit in
|
|
9
|
+
* (`Agnairt AA-A h36`), so unlike {@link REAL_NEBULAE} they carry no real-world
|
|
10
|
+
* catalogue identity. About 16 KiB bundled; the far larger planetary class lives in
|
|
11
|
+
* `./nebulae-planetary`.
|
|
12
|
+
*
|
|
13
|
+
* Data from EDAstro; see [ATTRIBUTIONS.md](https://github.com/DarkSession/Elite-Dangerous-Almanac/blob/main/ATTRIBUTIONS.md) for credit and licence terms.
|
|
14
|
+
*
|
|
15
|
+
* @packageDocumentation
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* All 166 procedurally generated nebulae, sorted by name.
|
|
20
|
+
*
|
|
21
|
+
* @remarks
|
|
22
|
+
* Every record has `type: 'procgen'`. Note that `name` and `system` differ here:
|
|
23
|
+
* the nebula is named for its own boxel (`Agnairt AA-A h36`) while `system` is the
|
|
24
|
+
* catalogued system nearby (`Agnairt TA-U d4-360`).
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* ```ts
|
|
28
|
+
* import { PROCGEN_NEBULAE } from '@elite-dangerous-almanac/core/astro/nebulae-procgen';
|
|
29
|
+
*
|
|
30
|
+
* PROCGEN_NEBULAE.length; // -> 166
|
|
31
|
+
* PROCGEN_NEBULAE[0]?.name; // -> 'Agnairt AA-A h36'
|
|
32
|
+
* ```
|
|
33
|
+
*/
|
|
34
|
+
declare const PROCGEN_NEBULAE: readonly Nebula[];
|
|
35
|
+
|
|
36
|
+
export { PROCGEN_NEBULAE };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{PROCGEN_NEBULAE}from"../chunk-K7F6WC4T.js"; //# sourceMappingURL=nebulae-procgen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"O"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { Nebula } from './nebulae.js';
|
|
2
|
+
import '../galactic-position-shLkm4Qg.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* The catalogue of **real** nebulae — the 180 real-world nebulae and dark regions
|
|
6
|
+
* Elite Dangerous models under their catalogue name (Horsehead, Witch Head,
|
|
7
|
+
* Barnard's Loop, the Coalsack and Aquila dark regions, …).
|
|
8
|
+
*
|
|
9
|
+
* This is the small, human-recognisable slice of the nebula catalogue (~16 KiB
|
|
10
|
+
* bundled) and the one most apps want. The much larger planetary and procedurally
|
|
11
|
+
* generated classes live in `./nebulae-planetary` and `./nebulae-procgen`, so
|
|
12
|
+
* importing this module never bundles them.
|
|
13
|
+
*
|
|
14
|
+
* Data from EDAstro; see [ATTRIBUTIONS.md](https://github.com/DarkSession/Elite-Dangerous-Almanac/blob/main/ATTRIBUTIONS.md) for credit and licence terms.
|
|
15
|
+
*
|
|
16
|
+
* @packageDocumentation
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* All 180 real-world nebulae and dark regions, sorted by name.
|
|
21
|
+
*
|
|
22
|
+
* @remarks
|
|
23
|
+
* Every record has `type: 'real'`. Search it with `nearestNebulae` or
|
|
24
|
+
* `nebulaeWithin` from `./nebulae`.
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* ```ts
|
|
28
|
+
* import { REAL_NEBULAE } from '@elite-dangerous-almanac/core/astro/nebulae-real';
|
|
29
|
+
*
|
|
30
|
+
* REAL_NEBULAE.length; // -> 180
|
|
31
|
+
* REAL_NEBULAE.find((n) => n.name === 'Horsehead Nebula')?.system;
|
|
32
|
+
* // -> 'Horsehead Dark Region IR-V c2-9'
|
|
33
|
+
* ```
|
|
34
|
+
*/
|
|
35
|
+
declare const REAL_NEBULAE: readonly Nebula[];
|
|
36
|
+
|
|
37
|
+
export { REAL_NEBULAE };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{REAL_NEBULAE}from"../chunk-HI7FCS3G.js"; //# sourceMappingURL=nebulae-real.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"O"}
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
import { G as GalacticPosition } from '../galactic-position-shLkm4Qg.js';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Nebula catalogue types and proximity queries — the **data-free** core of the
|
|
5
|
+
* nebulae feature.
|
|
6
|
+
*
|
|
7
|
+
* Elite Dangerous models thousands of nebulae. This module holds the
|
|
8
|
+
* {@link Nebula} record shape and the pure functions that search a catalogue
|
|
9
|
+
* ({@link nearestNebulae}, {@link nebulaeWithin}, {@link getNebulaByName}); the
|
|
10
|
+
* catalogues themselves live in sibling modules, one per class, so you only bundle
|
|
11
|
+
* the ones you ask for:
|
|
12
|
+
*
|
|
13
|
+
* Sizes are each module's import graph once your bundler has minified it — the
|
|
14
|
+
* published package itself is not minified — before any transport compression; the
|
|
15
|
+
* gzipped figure is roughly a fifth of it.
|
|
16
|
+
*
|
|
17
|
+
* | Module | Export | Entries | Minified | Gzipped |
|
|
18
|
+
* | --- | --- | --- | --- | --- |
|
|
19
|
+
* | `./nebulae-real` | `REAL_NEBULAE` | 180 | 16.4 KiB | 5.3 KiB |
|
|
20
|
+
* | `./nebulae-procgen` | `PROCGEN_NEBULAE` | 166 | 16.4 KiB | 5.7 KiB |
|
|
21
|
+
* | `./nebulae-planetary` | `PLANETARY_NEBULAE` | 5489 | 399.3 KiB | 116.0 KiB |
|
|
22
|
+
* | `./nebulae-all` | `ALL_NEBULAE` | 5835 | 431.7 KiB | 126.5 KiB |
|
|
23
|
+
*
|
|
24
|
+
* Importing a query function from here costs nothing but the function: pass in
|
|
25
|
+
* whichever catalogue you imported. The catalogue argument is **required** — 94% of
|
|
26
|
+
* `ALL_NEBULAE` is planetary nebulae most apps never touch, so there is no default
|
|
27
|
+
* worth falling back to silently.
|
|
28
|
+
*
|
|
29
|
+
* Positions are galactic light-years with Sol at the origin — the same frame the
|
|
30
|
+
* journal, EDSM and Spansh use. Catalogue data originates from EDAstro; see
|
|
31
|
+
* [ATTRIBUTIONS.md](https://github.com/DarkSession/Elite-Dangerous-Almanac/blob/main/ATTRIBUTIONS.md)
|
|
32
|
+
* for credit and licence terms.
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* ```ts
|
|
36
|
+
* import { nearestNebulae } from '@elite-dangerous-almanac/core/astro/nebulae';
|
|
37
|
+
* import { REAL_NEBULAE } from '@elite-dangerous-almanac/core/astro/nebulae-real';
|
|
38
|
+
*
|
|
39
|
+
* nearestNebulae({ x: 0, y: 0, z: 0 }, REAL_NEBULAE, 1)[0]?.name; // -> 'Pleiades'
|
|
40
|
+
* ```
|
|
41
|
+
*
|
|
42
|
+
* @packageDocumentation
|
|
43
|
+
*/
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* How a nebula is classified by the source catalogue.
|
|
47
|
+
*
|
|
48
|
+
* - `real` — a catalogued real-world nebula or dark region the game models by name
|
|
49
|
+
* (Horsehead Nebula, Barnard's Loop, Coalsack Dark Region, …).
|
|
50
|
+
* - `planetary` — a planetary nebula, catalogued at the procedurally-named system
|
|
51
|
+
* it surrounds. By far the largest class.
|
|
52
|
+
* - `procgen` — a procedurally generated nebula, catalogued at a nearby system.
|
|
53
|
+
*/
|
|
54
|
+
type NebulaType = 'real' | 'planetary' | 'procgen';
|
|
55
|
+
/**
|
|
56
|
+
* One catalogued nebula and where it sits in the galaxy.
|
|
57
|
+
*
|
|
58
|
+
* @remarks
|
|
59
|
+
* A nebula is a volume, but the catalogue records a single reference point — the
|
|
60
|
+
* position of {@link Nebula.system}, the system it is catalogued at. Distances
|
|
61
|
+
* computed from it are therefore "distance to the catalogued system", not distance
|
|
62
|
+
* to the nebula's edge.
|
|
63
|
+
*/
|
|
64
|
+
interface Nebula {
|
|
65
|
+
/**
|
|
66
|
+
* Display name, e.g. `"Witch Head Nebula"`. For procedurally-named nebulae this
|
|
67
|
+
* is usually the system name, sometimes with a community name appended in
|
|
68
|
+
* parentheses (`"Aemonz WZ-Y e6771 (Lazurite Nebula)"`).
|
|
69
|
+
*/
|
|
70
|
+
readonly name: string;
|
|
71
|
+
/** The in-game system the nebula is catalogued at, e.g. `"Witch Head Sector IR-W c1-8"`. */
|
|
72
|
+
readonly system: string;
|
|
73
|
+
/** Galactic X of the catalogued system, in light-years (Sol at origin). */
|
|
74
|
+
readonly x: number;
|
|
75
|
+
/** Galactic Y of the catalogued system, in light-years (Sol at origin). */
|
|
76
|
+
readonly y: number;
|
|
77
|
+
/** Galactic Z of the catalogued system, in light-years (Sol at origin). */
|
|
78
|
+
readonly z: number;
|
|
79
|
+
/** Which class of nebula this is. */
|
|
80
|
+
readonly type: NebulaType;
|
|
81
|
+
/**
|
|
82
|
+
* Id of the galactic codex region the nebula sits in, 1–42.
|
|
83
|
+
*
|
|
84
|
+
* @remarks
|
|
85
|
+
* Resolve it to a name with `getCodexRegion` from `./codex-region` — that
|
|
86
|
+
* costs ~9 KB of region metadata rather than the ~267 KB lookup grid
|
|
87
|
+
* `findCodexRegionAt` needs.
|
|
88
|
+
*/
|
|
89
|
+
readonly regionId: number;
|
|
90
|
+
}
|
|
91
|
+
/** A {@link Nebula} annotated with its distance from a queried point. */
|
|
92
|
+
interface NebulaWithDistance extends Nebula {
|
|
93
|
+
/** Straight-line distance from the queried coordinates, in light-years. */
|
|
94
|
+
readonly distanceLy: number;
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* The nebulae closest to a point, nearest first.
|
|
98
|
+
*
|
|
99
|
+
* @param coords - The point to measure from, in light-years (Sol at origin). A
|
|
100
|
+
* `ProceduralSystem.position` value fits once you have narrowed it — it is
|
|
101
|
+
* `GalacticPosition | null`, and is `null` unless that system was built from an address
|
|
102
|
+
* *and* you supplied its coordinates, so null-check it first.
|
|
103
|
+
* @param nebulae - The catalogue to search — `REAL_NEBULAE`, `PLANETARY_NEBULAE`,
|
|
104
|
+
* `PROCGEN_NEBULAE`, `ALL_NEBULAE`, or any subset you have filtered yourself.
|
|
105
|
+
* @param count - How many to return. Defaults to `3`. Fractional values are truncated
|
|
106
|
+
* towards zero, values `<= 0` and `NaN` yield an empty array, and a count larger than
|
|
107
|
+
* the catalogue returns the whole catalogue.
|
|
108
|
+
* @returns Up to `count` nebulae sorted by ascending {@link NebulaWithDistance.distanceLy}.
|
|
109
|
+
* Ties keep catalogue order. The input array is not modified.
|
|
110
|
+
* @example
|
|
111
|
+
* ```ts
|
|
112
|
+
* import { nearestNebulae } from '@elite-dangerous-almanac/core/astro/nebulae';
|
|
113
|
+
* import { REAL_NEBULAE } from '@elite-dangerous-almanac/core/astro/nebulae-real';
|
|
114
|
+
*
|
|
115
|
+
* // The three real nebulae nearest Sol
|
|
116
|
+
* nearestNebulae({ x: 0, y: 0, z: 0 }, REAL_NEBULAE).map((n) => n.name);
|
|
117
|
+
* // -> [ 'Pleiades', 'R Cra', 'Lupus Dark Region B' ] (nearest first)
|
|
118
|
+
*
|
|
119
|
+
* nearestNebulae({ x: 0, y: 0, z: 0 }, REAL_NEBULAE, 1)[0]?.distanceLy; // -> ≈383.31
|
|
120
|
+
* ```
|
|
121
|
+
*/
|
|
122
|
+
declare function nearestNebulae(coords: GalacticPosition, nebulae: readonly Nebula[], count?: number): NebulaWithDistance[];
|
|
123
|
+
/**
|
|
124
|
+
* Every nebula within a radius of a point, nearest first.
|
|
125
|
+
*
|
|
126
|
+
* @param coords - The point to measure from, in light-years (Sol at origin).
|
|
127
|
+
* @param nebulae - The catalogue to search (see {@link nearestNebulae}).
|
|
128
|
+
* @param radiusLy - Search radius in light-years, inclusive of the boundary.
|
|
129
|
+
* Negative radii yield an empty array.
|
|
130
|
+
* @returns The matching nebulae sorted by ascending
|
|
131
|
+
* {@link NebulaWithDistance.distanceLy}. Ties keep catalogue order. The input array
|
|
132
|
+
* is not modified.
|
|
133
|
+
* @example
|
|
134
|
+
* ```ts
|
|
135
|
+
* import { nebulaeWithin } from '@elite-dangerous-almanac/core/astro/nebulae';
|
|
136
|
+
* import { REAL_NEBULAE } from '@elite-dangerous-almanac/core/astro/nebulae-real';
|
|
137
|
+
*
|
|
138
|
+
* // Real nebulae within 400 ly of Sol
|
|
139
|
+
* nebulaeWithin({ x: 0, y: 0, z: 0 }, REAL_NEBULAE, 400).map((n) => n.name);
|
|
140
|
+
* // -> [ 'Pleiades' ]
|
|
141
|
+
* ```
|
|
142
|
+
*/
|
|
143
|
+
declare function nebulaeWithin(coords: GalacticPosition, nebulae: readonly Nebula[], radiusLy: number): NebulaWithDistance[];
|
|
144
|
+
/**
|
|
145
|
+
* Look up a nebula by name (case-insensitive).
|
|
146
|
+
*
|
|
147
|
+
* @param name - The nebula name as the catalogue spells it, e.g.
|
|
148
|
+
* `"Witch Head Nebula"`. Matching ignores case and surrounding whitespace on both the
|
|
149
|
+
* argument and the catalogue's own `name`, but is otherwise exact — including any
|
|
150
|
+
* parenthetical community name (`"Aemonz WZ-Y e6771 (Lazurite Nebula)"`), so pass the
|
|
151
|
+
* whole string. A record whose `name` is not a string never matches.
|
|
152
|
+
* @param nebulae - The catalogue to search (see {@link nearestNebulae}).
|
|
153
|
+
* @returns The matching {@link Nebula}, or `null` if the catalogue holds no nebula
|
|
154
|
+
* of that name. Only the catalogue you pass is searched — a real nebula will not
|
|
155
|
+
* be found in `PLANETARY_NEBULAE`.
|
|
156
|
+
* @throws {TypeError} If `name` is present and not a string. A nullish
|
|
157
|
+
* `name` is a miss, answered the way an unrecognised one is.
|
|
158
|
+
* @example
|
|
159
|
+
* ```ts
|
|
160
|
+
* import { getNebulaByName } from '@elite-dangerous-almanac/core/astro/nebulae';
|
|
161
|
+
* import { REAL_NEBULAE } from '@elite-dangerous-almanac/core/astro/nebulae-real';
|
|
162
|
+
*
|
|
163
|
+
* getNebulaByName('witch head nebula', REAL_NEBULAE)?.system;
|
|
164
|
+
* // -> 'Witch Head Sector RY-R b4-0'
|
|
165
|
+
* ```
|
|
166
|
+
*/
|
|
167
|
+
declare function getNebulaByName(name: string, nebulae: readonly Nebula[]): Nebula | null;
|
|
168
|
+
|
|
169
|
+
export { type Nebula, type NebulaType, type NebulaWithDistance, getNebulaByName, nearestNebulae, nebulaeWithin };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{getNebulaByName,nearestNebulae,nebulaeWithin}from"../chunk-ZFT56QFR.js"; //# sourceMappingURL=nebulae.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"O"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Whole permit-locked regions, kept separate from individually locked systems.
|
|
3
|
+
*
|
|
4
|
+
* Importing this leaf module costs only the 28 region names. `ProceduralSystem` uses it
|
|
5
|
+
* to preserve the library's fine-grained tree-shaking boundary.
|
|
6
|
+
*
|
|
7
|
+
* @packageDocumentation
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* The 28 permit-locked regions, sorted by name.
|
|
11
|
+
*
|
|
12
|
+
* @remarks
|
|
13
|
+
* Each entry is both a hand-authored region name and the whole-token prefix used
|
|
14
|
+
* by system names inside it. The array is frozen at runtime.
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```ts
|
|
18
|
+
* import { PERMIT_LOCKED_REGIONS } from '@elite-dangerous-almanac/core/astro/permit-locked-regions';
|
|
19
|
+
*
|
|
20
|
+
* PERMIT_LOCKED_REGIONS.slice(0, 3); // -> [ 'Bleia1', 'Bleia2', 'Bleia3' ]
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
23
|
+
declare const PERMIT_LOCKED_REGIONS: readonly string[];
|
|
24
|
+
/**
|
|
25
|
+
* Whether a region is permit-locked, by its exact name.
|
|
26
|
+
*
|
|
27
|
+
* @param name - A hand-authored region name in any casing, with optional
|
|
28
|
+
* surrounding whitespace.
|
|
29
|
+
* @returns `true` when the exact region is permit-locked. A system name inside the
|
|
30
|
+
* region does not count as an exact region-name match.
|
|
31
|
+
* @throws {TypeError} If `name` is present and not a string. A nullish
|
|
32
|
+
* `name` is a miss, answered the way an unrecognised one is.
|
|
33
|
+
*/
|
|
34
|
+
declare function isPermitLockedRegionName(name: string): boolean;
|
|
35
|
+
/**
|
|
36
|
+
* Find the permit-locked region prefix applying to a system name.
|
|
37
|
+
*
|
|
38
|
+
* @param systemName - A system name in any casing, with optional surrounding
|
|
39
|
+
* whitespace.
|
|
40
|
+
* @returns The canonically-cased region name, or `null` when no locked region
|
|
41
|
+
* prefix applies.
|
|
42
|
+
* @throws {TypeError} If `systemName` is present and not a string. A nullish
|
|
43
|
+
* `systemName` is a miss, answered the way an unrecognised one is.
|
|
44
|
+
* @example
|
|
45
|
+
* ```ts
|
|
46
|
+
* import { permitLockedRegionForSystemName } from '@elite-dangerous-almanac/core/astro/permit-locked-regions';
|
|
47
|
+
*
|
|
48
|
+
* permitLockedRegionForSystemName('Col 70 Sector AA-D b17-0');
|
|
49
|
+
* // -> 'Col 70 Sector'
|
|
50
|
+
* ```
|
|
51
|
+
*/
|
|
52
|
+
declare function permitLockedRegionForSystemName(systemName: string): string | null;
|
|
53
|
+
|
|
54
|
+
export { PERMIT_LOCKED_REGIONS, isPermitLockedRegionName, permitLockedRegionForSystemName };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{PERMIT_LOCKED_REGIONS,isPermitLockedRegionName,permitLockedRegionForSystemName}from"../chunk-VZXL5KBR.js"; //# sourceMappingURL=permit-locked-regions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"O"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { SystemAddressInput } from './system-address-input.js';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Individually permit-locked systems, indexed independently from region locks.
|
|
5
|
+
*
|
|
6
|
+
* Import this leaf module when only exact system locks or journal addresses are
|
|
7
|
+
* needed; it does not load the permit-locked region catalogue.
|
|
8
|
+
*
|
|
9
|
+
* @packageDocumentation
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
/** One individually permit-locked system. */
|
|
13
|
+
interface PermitLockedSystem {
|
|
14
|
+
/** Canonically-cased system name, e.g. `"Shinrarta Dezhra"`. */
|
|
15
|
+
readonly name: string;
|
|
16
|
+
/**
|
|
17
|
+
* The system's 64-bit system address, as reported by the player journal's
|
|
18
|
+
* `SystemAddress` field.
|
|
19
|
+
*
|
|
20
|
+
* @remarks
|
|
21
|
+
* Most of these systems are hand-named rather than procedural, so their address
|
|
22
|
+
* cannot be computed from the name. It is recorded from Spansh/EDSM; see
|
|
23
|
+
* [`data/astro/SOURCES.md`](https://github.com/DarkSession/Elite-Dangerous-Almanac/blob/main/data/astro/SOURCES.md).
|
|
24
|
+
*/
|
|
25
|
+
readonly id64: bigint;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* The 54 individually permit-locked systems, sorted by name.
|
|
29
|
+
*
|
|
30
|
+
* @remarks
|
|
31
|
+
* The array and every record are frozen at runtime. Region-locked systems are not
|
|
32
|
+
* listed here; see `PERMIT_LOCKED_REGIONS` in `./permit-locked-regions`.
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* ```ts
|
|
36
|
+
* import { PERMIT_LOCKED_SYSTEMS } from '@elite-dangerous-almanac/core/astro/permit-locked-systems';
|
|
37
|
+
*
|
|
38
|
+
* PERMIT_LOCKED_SYSTEMS.find((system) => system.name === 'Sol')?.id64;
|
|
39
|
+
* // -> 10477373803n
|
|
40
|
+
* ```
|
|
41
|
+
*/
|
|
42
|
+
declare const PERMIT_LOCKED_SYSTEMS: readonly PermitLockedSystem[];
|
|
43
|
+
/**
|
|
44
|
+
* Find an individually permit-locked system by exact name.
|
|
45
|
+
*
|
|
46
|
+
* @param name - A system name in any casing, with optional surrounding whitespace.
|
|
47
|
+
* @returns The frozen catalogue record, or `null` when the name is not individually
|
|
48
|
+
* permit-locked. Region prefixes are not checked.
|
|
49
|
+
* @throws {TypeError} If `name` is present and not a string. A nullish
|
|
50
|
+
* `name` is a miss, answered the way an unrecognised one is.
|
|
51
|
+
*/
|
|
52
|
+
declare function permitLockedSystemForName(name: string): PermitLockedSystem | null;
|
|
53
|
+
/**
|
|
54
|
+
* Find an individually permit-locked system by its system address.
|
|
55
|
+
*
|
|
56
|
+
* @param address - A `bigint` from this library, a safe integer from a normally
|
|
57
|
+
* parsed journal event, or a decimal string from persisted JSON. Unsafe numbers,
|
|
58
|
+
* non-integers and malformed strings yield `null` rather than risking a rounded
|
|
59
|
+
* address comparison.
|
|
60
|
+
* @returns The frozen catalogue record, or `null` when the address is invalid or
|
|
61
|
+
* not individually permit-locked.
|
|
62
|
+
* @example
|
|
63
|
+
* ```ts
|
|
64
|
+
* import { permitLockedSystemForAddress } from '@elite-dangerous-almanac/core/astro/permit-locked-systems';
|
|
65
|
+
*
|
|
66
|
+
* declare const event: { SystemAddress: number }; // an `FSDJump` line, parsed
|
|
67
|
+
*
|
|
68
|
+
* permitLockedSystemForAddress(event.SystemAddress)?.name; // -> 'Sol'
|
|
69
|
+
* permitLockedSystemForAddress('10477373803')?.name; // -> 'Sol'
|
|
70
|
+
* ```
|
|
71
|
+
*/
|
|
72
|
+
declare function permitLockedSystemForAddress(address: SystemAddressInput): PermitLockedSystem | null;
|
|
73
|
+
|
|
74
|
+
export { PERMIT_LOCKED_SYSTEMS, type PermitLockedSystem, SystemAddressInput, permitLockedSystemForAddress, permitLockedSystemForName };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{PERMIT_LOCKED_SYSTEMS,permitLockedSystemForAddress,permitLockedSystemForName}from"../chunk-WV5YM7H5.js"; //# sourceMappingURL=permit-locked-systems.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"O"}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
export { PERMIT_LOCKED_SYSTEMS, PermitLockedSystem, permitLockedSystemForAddress, permitLockedSystemForName } from './permit-locked-systems.js';
|
|
2
|
+
export { PERMIT_LOCKED_REGIONS, isPermitLockedRegionName, permitLockedRegionForSystemName } from './permit-locked-regions.js';
|
|
3
|
+
export { SystemAddressInput } from './system-address-input.js';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Permit-locked systems and regions — "can a commander jump here without a
|
|
7
|
+
* permit?", answered from a **system name** alone.
|
|
8
|
+
*
|
|
9
|
+
* A permit lock is not published in any game data file, journal event or API
|
|
10
|
+
* (even Sol, permit-locked since launch, reports no permit flag), so this is a
|
|
11
|
+
* hand-maintained community list. It has two halves:
|
|
12
|
+
*
|
|
13
|
+
* - {@link PERMIT_LOCKED_SYSTEMS} — 54 individually locked systems, each with its
|
|
14
|
+
* name and `id64` (`Sol`, `Shinrarta Dezhra`, `Achenar`, …).
|
|
15
|
+
* - {@link PERMIT_LOCKED_REGIONS} — 28 whole regions whose permit covers every
|
|
16
|
+
* system inside them (`Col 70 Sector`, `Bleia1`, `Cone Sector`, …), matched by
|
|
17
|
+
* name prefix, because the game names every system in a region after it.
|
|
18
|
+
*
|
|
19
|
+
* {@link permitLockForSystemName} checks both and tells you which one hit.
|
|
20
|
+
*
|
|
21
|
+
* @remarks
|
|
22
|
+
* Permit state lives in the two tree-shakeable leaf modules
|
|
23
|
+
* `./permit-locked-systems` and `./permit-locked-regions`; this module composes and
|
|
24
|
+
* re-exports both. `HandAuthoredRegion` carries no permit flag, so
|
|
25
|
+
* {@link isPermitLockedRegionName} is how the geometric route asks the question:
|
|
26
|
+
*
|
|
27
|
+
* ```ts
|
|
28
|
+
* const region = findHandAuthoredRegionAt(position);
|
|
29
|
+
* const needsPermit = region !== null && isPermitLockedRegionName(region.name);
|
|
30
|
+
* ```
|
|
31
|
+
*
|
|
32
|
+
* **Prefer that route when you have coordinates.** Resolving a region from a
|
|
33
|
+
* *position* is exact; matching the start of a name is a best-effort fallback for
|
|
34
|
+
* when a name is all you have (a journal line, a user's search box, a route plan).
|
|
35
|
+
*
|
|
36
|
+
* **Scope.** Systems only. Permit-locked *bodies* inside otherwise-open systems
|
|
37
|
+
* (Diso 5 C, Lave 2, Sol's Moon and Triton) are deliberately excluded — a
|
|
38
|
+
* system-level flag would be wrong for them.
|
|
39
|
+
*
|
|
40
|
+
* Sourced from the community "Elite Dangerous Permit Database" spreadsheet via
|
|
41
|
+
* canonn-signals; see [ATTRIBUTIONS.md](https://github.com/DarkSession/Elite-Dangerous-Almanac/blob/main/ATTRIBUTIONS.md) for credit and licence terms.
|
|
42
|
+
*
|
|
43
|
+
* @example
|
|
44
|
+
* ```ts
|
|
45
|
+
* declare const event: { SystemAddress: number }; // an `FSDJump` line, parsed
|
|
46
|
+
*
|
|
47
|
+
* import {
|
|
48
|
+
* permitLockForSystemName,
|
|
49
|
+
* permitLockedSystemForAddress,
|
|
50
|
+
* } from '@elite-dangerous-almanac/core/astro/permit-locks';
|
|
51
|
+
*
|
|
52
|
+
* permitLockForSystemName('Shinrarta Dezhra'); // -> { kind: 'system', ... }
|
|
53
|
+
* permitLockForSystemName('Col 70 Sector AA-D b17-0'); // -> { kind: 'region', name: 'Col 70 Sector' }
|
|
54
|
+
* permitLockedSystemForAddress(event.SystemAddress); // accepts a journal number
|
|
55
|
+
* ```
|
|
56
|
+
*
|
|
57
|
+
* @packageDocumentation
|
|
58
|
+
*/
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* Why a system needs a permit: because that exact system is locked
|
|
62
|
+
* (`kind: 'system'`), or because it lies inside a locked region
|
|
63
|
+
* (`kind: 'region'`).
|
|
64
|
+
*/
|
|
65
|
+
type PermitLock = {
|
|
66
|
+
/** The system itself is on the permit-locked list. */
|
|
67
|
+
readonly kind: 'system';
|
|
68
|
+
/** The canonically-cased system name, e.g. `"Shinrarta Dezhra"`. */
|
|
69
|
+
readonly name: string;
|
|
70
|
+
/** That system's 64-bit system address. */
|
|
71
|
+
readonly id64: bigint;
|
|
72
|
+
} | {
|
|
73
|
+
/** The system lies inside a permit-locked region. */
|
|
74
|
+
readonly kind: 'region';
|
|
75
|
+
/**
|
|
76
|
+
* The region's name, e.g. `"Col 70 Sector"`. Also a `HAND_AUTHORED_REGIONS`
|
|
77
|
+
* entry name, so you can look its spheres up by it (see
|
|
78
|
+
* `./hand-authored-regions`). No `id64` — a region is not a system.
|
|
79
|
+
*/
|
|
80
|
+
readonly name: string;
|
|
81
|
+
};
|
|
82
|
+
/**
|
|
83
|
+
* The permit lock that applies to a system name, or `null` if it is open space.
|
|
84
|
+
*
|
|
85
|
+
* Checks the exact-name list first, then the region names, so a system that is
|
|
86
|
+
* both individually listed and inside a locked region reports `kind: 'system'`.
|
|
87
|
+
*
|
|
88
|
+
* @param name - A system name in any casing, with or without surrounding
|
|
89
|
+
* whitespace, e.g. `" shinrarta dezhra "`. An empty or blank string yields `null`.
|
|
90
|
+
* @returns A {@link PermitLock} naming the system or region responsible, or `null`
|
|
91
|
+
* when nothing on the list matches.
|
|
92
|
+
* @throws {TypeError} If `name` is present and not a string. A nullish
|
|
93
|
+
* `name` is a miss, answered the way an unrecognised one is.
|
|
94
|
+
* @example
|
|
95
|
+
* ```ts
|
|
96
|
+
* import { permitLockForSystemName } from '@elite-dangerous-almanac/core/astro/permit-locks';
|
|
97
|
+
*
|
|
98
|
+
* permitLockForSystemName('sol');
|
|
99
|
+
* // -> { kind: 'system', name: 'Sol', id64: 10477373803n }
|
|
100
|
+
*
|
|
101
|
+
* permitLockForSystemName('Bleia1 DL-Y f26');
|
|
102
|
+
* // -> { kind: 'region', name: 'Bleia1' }
|
|
103
|
+
*
|
|
104
|
+
* permitLockForSystemName('Col 285 Sector IX-T d3-31'); // -> null (the bubble's Col 285)
|
|
105
|
+
* ```
|
|
106
|
+
*/
|
|
107
|
+
declare function permitLockForSystemName(name: string): PermitLock | null;
|
|
108
|
+
/**
|
|
109
|
+
* Whether a system needs a permit — either its own, or its region's.
|
|
110
|
+
*
|
|
111
|
+
* A convenience wrapper over {@link permitLockForSystemName} for when you only need
|
|
112
|
+
* the yes/no. Use that function instead when you want to tell the commander *which*
|
|
113
|
+
* permit they are missing.
|
|
114
|
+
*
|
|
115
|
+
* @param name - A system name in any casing, e.g. `"vega"`.
|
|
116
|
+
* @returns `true` if the name matches a permit-locked system or region.
|
|
117
|
+
* @throws {TypeError} If `name` is present and not a string. A nullish
|
|
118
|
+
* `name` is a miss, answered the way an unrecognised one is.
|
|
119
|
+
* @example
|
|
120
|
+
* ```ts
|
|
121
|
+
* import { isPermitLockedSystemName } from '@elite-dangerous-almanac/core/astro/permit-locks';
|
|
122
|
+
*
|
|
123
|
+
* isPermitLockedSystemName('Sirius'); // -> true (system lock)
|
|
124
|
+
* isPermitLockedSystemName('Cone Sector GW-W c1-5'); // -> true (region lock)
|
|
125
|
+
* isPermitLockedSystemName('Colonia'); // -> false
|
|
126
|
+
* ```
|
|
127
|
+
*/
|
|
128
|
+
declare function isPermitLockedSystemName(name: string): boolean;
|
|
129
|
+
|
|
130
|
+
export { type PermitLock, isPermitLockedSystemName, permitLockForSystemName };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{isPermitLockedSystemName,permitLockForSystemName}from"../chunk-MFV4VZFP.js";export{PERMIT_LOCKED_SYSTEMS,permitLockedSystemForAddress,permitLockedSystemForName}from"../chunk-WV5YM7H5.js";export{PERMIT_LOCKED_REGIONS,isPermitLockedRegionName,permitLockedRegionForSystemName}from"../chunk-VZXL5KBR.js"; //# sourceMappingURL=permit-locks.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"O"}
|