@shipload/sdk 2.0.0-rc8 → 2.0.0-rc9
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/lib/shipload.d.ts +401 -38
- package/lib/shipload.js +1390 -67
- package/lib/shipload.js.map +1 -1
- package/lib/shipload.m.js +1330 -68
- package/lib/shipload.m.js.map +1 -1
- package/package.json +6 -5
- package/src/capabilities/modules.ts +9 -5
- package/src/contracts/server.ts +279 -22
- package/src/data/capabilities.ts +372 -0
- package/src/data/categories.ts +57 -0
- package/src/data/colors.ts +19 -14
- package/src/data/locations.ts +53 -0
- package/src/data/recipes.ts +117 -14
- package/src/data/tiers.ts +41 -0
- package/src/derivation/crafting.ts +58 -1
- package/src/entities/container.ts +18 -0
- package/src/entities/makers.ts +6 -4
- package/src/entities/ship-deploy.ts +34 -1
- package/src/entities/warehouse.ts +7 -1
- package/src/index-module.ts +70 -2
- package/src/nft/description.ts +173 -0
- package/src/nft/deserializers.ts +81 -0
- package/src/nft/index.ts +2 -0
- package/src/resolution/resolve-item.ts +11 -1
- package/src/travel/travel.ts +17 -8
- package/src/types/entity.ts +1 -1
- package/src/types.ts +6 -6
|
@@ -0,0 +1,372 @@
|
|
|
1
|
+
export interface CapabilityAttribute {
|
|
2
|
+
capability: string
|
|
3
|
+
attribute: string
|
|
4
|
+
description: string
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
export interface StatMapping {
|
|
8
|
+
stat: string
|
|
9
|
+
capability: string
|
|
10
|
+
attribute: string
|
|
11
|
+
rationale: string
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export const capabilityNames: string[] = [
|
|
15
|
+
'Hull',
|
|
16
|
+
'Storage',
|
|
17
|
+
'Movement',
|
|
18
|
+
'Energy',
|
|
19
|
+
'Loader',
|
|
20
|
+
'Extraction',
|
|
21
|
+
'Warp',
|
|
22
|
+
'Manufacturing',
|
|
23
|
+
'Launch',
|
|
24
|
+
]
|
|
25
|
+
|
|
26
|
+
export const capabilityAttributes: CapabilityAttribute[] = [
|
|
27
|
+
{capability: 'Hull', attribute: 'mass', description: 'Total mass of the hull'},
|
|
28
|
+
{capability: 'Storage', attribute: 'capacity', description: 'Maximum mass that can be stored'},
|
|
29
|
+
{capability: 'Movement', attribute: 'thrust', description: 'Propulsion force'},
|
|
30
|
+
{capability: 'Movement', attribute: 'drain', description: 'Energy consumed per movement'},
|
|
31
|
+
{capability: 'Energy', attribute: 'capacity', description: 'Maximum energy storage'},
|
|
32
|
+
{capability: 'Energy', attribute: 'recharge', description: 'Energy regeneration rate'},
|
|
33
|
+
{capability: 'Loader', attribute: 'mass', description: 'Weight of the loader unit itself'},
|
|
34
|
+
{capability: 'Loader', attribute: 'thrust', description: 'Loading speed/force'},
|
|
35
|
+
{capability: 'Extraction', attribute: 'rate', description: 'Mass extracted per second'},
|
|
36
|
+
{capability: 'Extraction', attribute: 'drain', description: 'Energy consumed per extraction'},
|
|
37
|
+
{capability: 'Extraction', attribute: 'depth', description: 'Maximum extraction depth'},
|
|
38
|
+
{capability: 'Extraction', attribute: 'drill', description: 'Drilling speed/penetration'},
|
|
39
|
+
{capability: 'Warp', attribute: 'range', description: 'Maximum warp distance'},
|
|
40
|
+
{capability: 'Manufacturing', attribute: 'speed', description: 'Crafting time per item'},
|
|
41
|
+
{
|
|
42
|
+
capability: 'Manufacturing',
|
|
43
|
+
attribute: 'drain',
|
|
44
|
+
description: 'Energy consumed per second while crafting',
|
|
45
|
+
},
|
|
46
|
+
{capability: 'Manufacturing', attribute: 'quality', description: 'Modifier on output quality'},
|
|
47
|
+
{capability: 'Launch', attribute: 'range', description: 'Maximum launch distance'},
|
|
48
|
+
{capability: 'Launch', attribute: 'capacity', description: 'Maximum mass per launch'},
|
|
49
|
+
{capability: 'Launch', attribute: 'drain', description: 'Energy consumed per launch'},
|
|
50
|
+
]
|
|
51
|
+
|
|
52
|
+
export const statMappings: StatMapping[] = [
|
|
53
|
+
{
|
|
54
|
+
stat: 'Strength',
|
|
55
|
+
capability: 'Extraction',
|
|
56
|
+
attribute: 'rate',
|
|
57
|
+
rationale: 'Raw mechanical force drives faster extraction',
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
stat: 'Strength',
|
|
61
|
+
capability: 'Storage',
|
|
62
|
+
attribute: 'capacity',
|
|
63
|
+
rationale: 'Stronger walls hold more capacity per mass',
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
stat: 'Strength',
|
|
67
|
+
capability: 'Launch',
|
|
68
|
+
attribute: 'capacity',
|
|
69
|
+
rationale: 'Stronger housing handles larger launch loads',
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
stat: 'Tolerance',
|
|
73
|
+
capability: 'Movement',
|
|
74
|
+
attribute: 'thrust',
|
|
75
|
+
rationale: 'Engine components that tolerate more can push harder',
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
stat: 'Tolerance',
|
|
79
|
+
capability: 'Energy',
|
|
80
|
+
attribute: 'recharge',
|
|
81
|
+
rationale: 'Generator housing withstands stress for faster recharge',
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
stat: 'Tolerance',
|
|
85
|
+
capability: 'Extraction',
|
|
86
|
+
attribute: 'depth',
|
|
87
|
+
rationale: 'Housing withstands pressure/heat at extreme depths',
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
stat: 'Tolerance',
|
|
91
|
+
capability: 'Warp',
|
|
92
|
+
attribute: 'range',
|
|
93
|
+
rationale: 'Warp drive housing withstands extreme forces',
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
stat: 'Density',
|
|
97
|
+
capability: 'Hull',
|
|
98
|
+
attribute: 'mass',
|
|
99
|
+
rationale: 'Lighter metal = lighter hull',
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
stat: 'Density',
|
|
103
|
+
capability: 'Loader',
|
|
104
|
+
attribute: 'mass',
|
|
105
|
+
rationale: 'Lighter metal = lighter loader units',
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
stat: 'Density',
|
|
109
|
+
capability: 'Movement',
|
|
110
|
+
attribute: 'drain',
|
|
111
|
+
rationale: 'Lighter components require less energy to move',
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
stat: 'Conductivity',
|
|
115
|
+
capability: 'Movement',
|
|
116
|
+
attribute: 'drain',
|
|
117
|
+
rationale: 'Efficient energy transfer reduces movement energy cost',
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
stat: 'Conductivity',
|
|
121
|
+
capability: 'Extraction',
|
|
122
|
+
attribute: 'drain',
|
|
123
|
+
rationale: 'Efficient energy transfer reduces extraction energy cost',
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
stat: 'Conductivity',
|
|
127
|
+
capability: 'Manufacturing',
|
|
128
|
+
attribute: 'drain',
|
|
129
|
+
rationale: 'Efficient energy transfer reduces manufacturing energy cost',
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
stat: 'Conductivity',
|
|
133
|
+
capability: 'Energy',
|
|
134
|
+
attribute: 'recharge',
|
|
135
|
+
rationale: 'Better conductivity speeds energy flow during recharge',
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
stat: 'Ductility',
|
|
139
|
+
capability: 'Manufacturing',
|
|
140
|
+
attribute: 'quality',
|
|
141
|
+
rationale: 'Precise shaping enables tighter manufacturing tolerances',
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
stat: 'Ductility',
|
|
145
|
+
capability: 'Extraction',
|
|
146
|
+
attribute: 'rate',
|
|
147
|
+
rationale: 'Precisely shaped drill components extract faster',
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
stat: 'Ductility',
|
|
151
|
+
capability: 'Storage',
|
|
152
|
+
attribute: 'capacity',
|
|
153
|
+
rationale: 'Precision-formed container walls maximize volume',
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
stat: 'Ductility',
|
|
157
|
+
capability: 'Loader',
|
|
158
|
+
attribute: 'mass',
|
|
159
|
+
rationale: 'Precision-formed precious metal reduces loader unit mass',
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
stat: 'Reflectivity',
|
|
163
|
+
capability: 'Extraction',
|
|
164
|
+
attribute: 'depth',
|
|
165
|
+
rationale: 'Reflective heat shielding protects equipment at depth',
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
stat: 'Reflectivity',
|
|
169
|
+
capability: 'Launch',
|
|
170
|
+
attribute: 'range',
|
|
171
|
+
rationale: 'Reflective surfaces focus electromagnetic launch energy',
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
stat: 'Volatility',
|
|
175
|
+
capability: 'Extraction',
|
|
176
|
+
attribute: 'rate',
|
|
177
|
+
rationale: 'Energy release powers faster extraction',
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
stat: 'Volatility',
|
|
181
|
+
capability: 'Movement',
|
|
182
|
+
attribute: 'thrust',
|
|
183
|
+
rationale: 'Energy release drives propulsion force',
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
stat: 'Volatility',
|
|
187
|
+
capability: 'Loader',
|
|
188
|
+
attribute: 'thrust',
|
|
189
|
+
rationale: 'Energy release powers loader motors',
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
stat: 'Volatility',
|
|
193
|
+
capability: 'Launch',
|
|
194
|
+
attribute: 'capacity',
|
|
195
|
+
rationale: 'Energy release enables launching heavier payloads',
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
stat: 'Reactivity',
|
|
199
|
+
capability: 'Manufacturing',
|
|
200
|
+
attribute: 'speed',
|
|
201
|
+
rationale: 'Reactive gases accelerate chemical/thermal processing',
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
stat: 'Reactivity',
|
|
205
|
+
capability: 'Extraction',
|
|
206
|
+
attribute: 'drill',
|
|
207
|
+
rationale: 'Reactive gases manage heat/friction during drilling',
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
stat: 'Reactivity',
|
|
211
|
+
capability: 'Launch',
|
|
212
|
+
attribute: 'drain',
|
|
213
|
+
rationale: 'Reactive gas medium reduces electromagnetic resistance',
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
stat: 'Thermal',
|
|
217
|
+
capability: 'Manufacturing',
|
|
218
|
+
attribute: 'quality',
|
|
219
|
+
rationale: 'Precise thermal control during fabrication',
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
stat: 'Thermal',
|
|
223
|
+
capability: 'Extraction',
|
|
224
|
+
attribute: 'drain',
|
|
225
|
+
rationale: 'Thermal management reduces energy waste during extraction',
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
stat: 'Thermal',
|
|
229
|
+
capability: 'Energy',
|
|
230
|
+
attribute: 'capacity',
|
|
231
|
+
rationale: 'Thermal management enables denser energy storage',
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
stat: 'Resonance',
|
|
235
|
+
capability: 'Energy',
|
|
236
|
+
attribute: 'capacity',
|
|
237
|
+
rationale: 'Resonating crystals store energy in fields',
|
|
238
|
+
},
|
|
239
|
+
{
|
|
240
|
+
stat: 'Resonance',
|
|
241
|
+
capability: 'Warp',
|
|
242
|
+
attribute: 'range',
|
|
243
|
+
rationale: 'Resonant crystals amplify warp field projection',
|
|
244
|
+
},
|
|
245
|
+
{
|
|
246
|
+
stat: 'Resonance',
|
|
247
|
+
capability: 'Launch',
|
|
248
|
+
attribute: 'range',
|
|
249
|
+
rationale: 'Resonant crystals focus electromagnetic launch field',
|
|
250
|
+
},
|
|
251
|
+
{
|
|
252
|
+
stat: 'Resonance',
|
|
253
|
+
capability: 'Launch',
|
|
254
|
+
attribute: 'capacity',
|
|
255
|
+
rationale: 'Stronger resonant field launches heavier payloads',
|
|
256
|
+
},
|
|
257
|
+
{
|
|
258
|
+
stat: 'Hardness',
|
|
259
|
+
capability: 'Manufacturing',
|
|
260
|
+
attribute: 'speed',
|
|
261
|
+
rationale: 'Hard tooling surfaces cut and shape materials faster',
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
stat: 'Hardness',
|
|
265
|
+
capability: 'Launch',
|
|
266
|
+
attribute: 'drain',
|
|
267
|
+
rationale: 'Hard rail surfaces reduce friction, less energy wasted',
|
|
268
|
+
},
|
|
269
|
+
{
|
|
270
|
+
stat: 'Clarity',
|
|
271
|
+
capability: 'Energy',
|
|
272
|
+
attribute: 'recharge',
|
|
273
|
+
rationale: 'Flawless crystals enable smoother energy flow during recharge',
|
|
274
|
+
},
|
|
275
|
+
{
|
|
276
|
+
stat: 'Clarity',
|
|
277
|
+
capability: 'Manufacturing',
|
|
278
|
+
attribute: 'quality',
|
|
279
|
+
rationale: 'Precision optics for calibration during fabrication',
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
stat: 'Clarity',
|
|
283
|
+
capability: 'Manufacturing',
|
|
284
|
+
attribute: 'drain',
|
|
285
|
+
rationale: 'Precision computing optimizes energy routing in factory',
|
|
286
|
+
},
|
|
287
|
+
{
|
|
288
|
+
stat: 'Plasticity',
|
|
289
|
+
capability: 'Manufacturing',
|
|
290
|
+
attribute: 'speed',
|
|
291
|
+
rationale: 'Easily reshaped materials speed up processing',
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
stat: 'Plasticity',
|
|
295
|
+
capability: 'Movement',
|
|
296
|
+
attribute: 'thrust',
|
|
297
|
+
rationale: 'Flexible polymer seals reduce friction in propulsion',
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
stat: 'Plasticity',
|
|
301
|
+
capability: 'Loader',
|
|
302
|
+
attribute: 'thrust',
|
|
303
|
+
rationale: 'Flexible joints improve loader force transfer',
|
|
304
|
+
},
|
|
305
|
+
{
|
|
306
|
+
stat: 'Insulation',
|
|
307
|
+
capability: 'Movement',
|
|
308
|
+
attribute: 'drain',
|
|
309
|
+
rationale: 'Better insulation reduces energy loss during movement',
|
|
310
|
+
},
|
|
311
|
+
{
|
|
312
|
+
stat: 'Insulation',
|
|
313
|
+
capability: 'Extraction',
|
|
314
|
+
attribute: 'drain',
|
|
315
|
+
rationale: 'Better insulation reduces energy loss during extraction',
|
|
316
|
+
},
|
|
317
|
+
{
|
|
318
|
+
stat: 'Insulation',
|
|
319
|
+
capability: 'Manufacturing',
|
|
320
|
+
attribute: 'drain',
|
|
321
|
+
rationale: 'Better insulation reduces energy loss during manufacturing',
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
stat: 'Insulation',
|
|
325
|
+
capability: 'Launch',
|
|
326
|
+
attribute: 'drain',
|
|
327
|
+
rationale: 'Better insulation reduces energy loss during launch',
|
|
328
|
+
},
|
|
329
|
+
{
|
|
330
|
+
stat: 'Purity',
|
|
331
|
+
capability: 'Storage',
|
|
332
|
+
attribute: 'capacity',
|
|
333
|
+
rationale: 'Purer composites make better containers',
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
stat: 'Purity',
|
|
337
|
+
capability: 'Extraction',
|
|
338
|
+
attribute: 'drill',
|
|
339
|
+
rationale: 'Purer bio-lubricants reduce friction during drilling',
|
|
340
|
+
},
|
|
341
|
+
{
|
|
342
|
+
stat: 'Purity',
|
|
343
|
+
capability: 'Energy',
|
|
344
|
+
attribute: 'capacity',
|
|
345
|
+
rationale: 'Purer organic electrolytes store more charge',
|
|
346
|
+
},
|
|
347
|
+
]
|
|
348
|
+
|
|
349
|
+
const invertedAttributes = new Set(['drain', 'mass'])
|
|
350
|
+
|
|
351
|
+
export function isInvertedAttribute(attribute: string): boolean {
|
|
352
|
+
return invertedAttributes.has(attribute)
|
|
353
|
+
}
|
|
354
|
+
|
|
355
|
+
export function getCapabilityAttributes(capability?: string): CapabilityAttribute[] {
|
|
356
|
+
if (capability) {
|
|
357
|
+
return capabilityAttributes.filter((a) => a.capability === capability)
|
|
358
|
+
}
|
|
359
|
+
return capabilityAttributes
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
export function getStatMappings(): StatMapping[] {
|
|
363
|
+
return statMappings
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
export function getStatMappingsForStat(stat: string): StatMapping[] {
|
|
367
|
+
return statMappings.filter((m) => m.stat === stat)
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
export function getStatMappingsForCapability(capability: string): StatMapping[] {
|
|
371
|
+
return statMappings.filter((m) => m.capability === capability)
|
|
372
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import type {ResourceCategory} from '../types'
|
|
2
|
+
import {categoryColors} from './colors'
|
|
3
|
+
|
|
4
|
+
export interface CategoryInfo {
|
|
5
|
+
id: ResourceCategory
|
|
6
|
+
name: string
|
|
7
|
+
label: string
|
|
8
|
+
description: string
|
|
9
|
+
color: string
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
const categories: CategoryInfo[] = [
|
|
13
|
+
{
|
|
14
|
+
id: 'metal',
|
|
15
|
+
name: 'Metals',
|
|
16
|
+
label: 'Metal',
|
|
17
|
+
description: 'Structural, strong, heavy — hulls, frames, load-bearing components',
|
|
18
|
+
color: categoryColors.metal,
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
id: 'precious',
|
|
22
|
+
name: 'Precious Metals',
|
|
23
|
+
label: 'Precious',
|
|
24
|
+
description:
|
|
25
|
+
'Conductive, corrosion-resistant — electronics, energy systems, precision components',
|
|
26
|
+
color: categoryColors.precious,
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
id: 'gas',
|
|
30
|
+
name: 'Gases',
|
|
31
|
+
label: 'Gas',
|
|
32
|
+
description:
|
|
33
|
+
'Energy, fuel, volatile/reactive — propulsion, thermal processing, chemical reactions',
|
|
34
|
+
color: categoryColors.gas,
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
id: 'mineral',
|
|
38
|
+
name: 'Minerals',
|
|
39
|
+
label: 'Mineral',
|
|
40
|
+
description: 'Crystalline, hard, precise — sensors, optics, energy storage, cutting surfaces',
|
|
41
|
+
color: categoryColors.mineral,
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
id: 'organic',
|
|
45
|
+
name: 'Organics',
|
|
46
|
+
label: 'Organic',
|
|
47
|
+
description: 'Adaptive, biological, polymer — insulation, composites, bio-processes',
|
|
48
|
+
color: categoryColors.organic,
|
|
49
|
+
},
|
|
50
|
+
]
|
|
51
|
+
|
|
52
|
+
export function getCategoryInfo(): CategoryInfo[]
|
|
53
|
+
export function getCategoryInfo(id: ResourceCategory): CategoryInfo | undefined
|
|
54
|
+
export function getCategoryInfo(id?: ResourceCategory): CategoryInfo[] | CategoryInfo | undefined {
|
|
55
|
+
if (id === undefined) return categories
|
|
56
|
+
return categories.find((c) => c.id === id)
|
|
57
|
+
}
|
package/src/data/colors.ts
CHANGED
|
@@ -30,18 +30,23 @@ export const moduleIcon = '⬢'
|
|
|
30
30
|
export const itemIcons: Record<number, string> = {
|
|
31
31
|
10001: 'HP',
|
|
32
32
|
10002: 'CL',
|
|
33
|
-
10003: '
|
|
34
|
-
10004: '
|
|
35
|
-
10005: '
|
|
36
|
-
10006: '
|
|
37
|
-
10007: '
|
|
38
|
-
10008: '
|
|
39
|
-
10009: '
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
33
|
+
10003: 'TC',
|
|
34
|
+
10004: 'PC',
|
|
35
|
+
10005: 'DS',
|
|
36
|
+
10006: 'EP',
|
|
37
|
+
10007: 'CA',
|
|
38
|
+
10008: 'TB',
|
|
39
|
+
10009: 'RC',
|
|
40
|
+
10100: 'EN',
|
|
41
|
+
10101: 'GN',
|
|
42
|
+
10102: 'EX',
|
|
43
|
+
10103: 'LD',
|
|
44
|
+
10104: 'MF',
|
|
45
|
+
10105: 'ST',
|
|
46
|
+
10200: 'CT',
|
|
47
|
+
10201: 'SH',
|
|
48
|
+
10202: 'WH',
|
|
49
|
+
20001: 'HP',
|
|
50
|
+
20002: 'CL',
|
|
51
|
+
20200: 'CT',
|
|
47
52
|
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
export interface PlanetSubtypeInfo {
|
|
2
|
+
id: number
|
|
3
|
+
label: string
|
|
4
|
+
description: string
|
|
5
|
+
paletteType: string
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
const planetSubtypes: PlanetSubtypeInfo[] = [
|
|
9
|
+
{
|
|
10
|
+
id: 0,
|
|
11
|
+
label: 'Gas Giant',
|
|
12
|
+
description: 'Massive planets with thick atmospheres rich in gases',
|
|
13
|
+
paletteType: 'gasGiant',
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
id: 1,
|
|
17
|
+
label: 'Rocky',
|
|
18
|
+
description: 'Dense, mineral-rich worlds with metallic cores',
|
|
19
|
+
paletteType: 'rocky',
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
id: 2,
|
|
23
|
+
label: 'Terrestrial',
|
|
24
|
+
description: 'Earth-like planets with varied terrain and life potential',
|
|
25
|
+
paletteType: 'terrestrial',
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
id: 3,
|
|
29
|
+
label: 'Icy',
|
|
30
|
+
description: 'Frozen worlds with subsurface resources',
|
|
31
|
+
paletteType: 'ice',
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
id: 4,
|
|
35
|
+
label: 'Ocean',
|
|
36
|
+
description: 'Water worlds with dissolved minerals and organics',
|
|
37
|
+
paletteType: 'ocean',
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
id: 5,
|
|
41
|
+
label: 'Industrial',
|
|
42
|
+
description: 'Heavily processed worlds rich in refined materials',
|
|
43
|
+
paletteType: 'industrial',
|
|
44
|
+
},
|
|
45
|
+
]
|
|
46
|
+
|
|
47
|
+
export function getPlanetSubtypes(): PlanetSubtypeInfo[] {
|
|
48
|
+
return planetSubtypes
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export function getPlanetSubtype(id: number): PlanetSubtypeInfo | undefined {
|
|
52
|
+
return planetSubtypes.find((s) => s.id === id)
|
|
53
|
+
}
|