@shipload/sdk 1.0.0-next.74 → 1.0.0-next.76
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/scan.js +1 -1
- package/lib/scan.js.map +1 -1
- package/lib/scan.m.js +1 -1
- package/lib/scan.m.js.map +1 -1
- package/lib/shipload.d.ts +81 -35
- package/lib/shipload.js +13576 -11311
- package/lib/shipload.js.map +1 -1
- package/lib/shipload.m.js +13554 -11311
- package/lib/shipload.m.js.map +1 -1
- package/lib/testing.d.ts +20 -16
- package/lib/testing.js +229 -53
- package/lib/testing.js.map +1 -1
- package/lib/testing.m.js +229 -53
- package/lib/testing.m.js.map +1 -1
- package/package.json +6 -6
- package/src/capabilities/storage.ts +45 -10
- package/src/contracts/server.ts +49 -41
- package/src/data/component-process.test.ts +119 -0
- package/src/data/component-process.ts +33 -0
- package/src/data/entities.json +367 -2
- package/src/data/item-ids.ts +15 -0
- package/src/data/items.json +90 -0
- package/src/data/kind-registry.json +97 -7
- package/src/data/metadata.ts +83 -5
- package/src/data/recipes-runtime.ts +1 -1
- package/src/data/recipes.json +1476 -10
- package/src/data/task-types.json +9 -0
- package/src/derivation/capabilities.test.ts +25 -2
- package/src/derivation/capabilities.ts +16 -3
- package/src/derivation/capacity-fn-registry.ts +8 -1
- package/src/derivation/reserve-regen.ts +5 -9
- package/src/derivation/stratum.ts +1 -1
- package/src/derivation/tiers.ts +1 -1
- package/src/derivation/upgrades.ts +5 -4
- package/src/index-module.ts +10 -1
- package/src/influence/influence.test.ts +1 -1
- package/src/managers/actions.ts +12 -19
- package/src/managers/entities.test.ts +23 -0
- package/src/managers/entities.ts +8 -1
- package/src/managers/shuttle.test.ts +67 -0
- package/src/managers/shuttle.ts +17 -0
- package/src/nft/description.ts +6 -0
- package/src/resolution/resolve-item.test.ts +6 -6
- package/src/resolution/resolve-item.ts +4 -0
- package/src/scan/scan-wasm.base64.ts +1 -1
- package/src/scheduling/availability.test.ts +3 -3
- package/src/scheduling/availability.ts +3 -4
- package/src/scheduling/lanes.ts +1 -1
- package/src/scheduling/projection.ts +15 -13
- package/src/scheduling/schedule.test.ts +24 -0
- package/src/scheduling/schedule.ts +11 -4
- package/src/scheduling/task-effects.ts +3 -1
- package/src/scheduling/unwrap.test.ts +25 -6
- package/src/scheduling/unwrap.ts +19 -3
- package/src/travel/travel.ts +4 -0
- package/src/types.ts +2 -0
|
@@ -152,13 +152,13 @@
|
|
|
152
152
|
"itemId": 10205,
|
|
153
153
|
"kind": "mdriver",
|
|
154
154
|
"displayLabel": "",
|
|
155
|
-
"baseCapacityFn": "
|
|
155
|
+
"baseCapacityFn": "structure"
|
|
156
156
|
},
|
|
157
157
|
{
|
|
158
158
|
"itemId": 10206,
|
|
159
159
|
"kind": "mcatcher",
|
|
160
160
|
"displayLabel": "",
|
|
161
|
-
"baseCapacityFn": "
|
|
161
|
+
"baseCapacityFn": "structure"
|
|
162
162
|
},
|
|
163
163
|
{
|
|
164
164
|
"itemId": 10200,
|
|
@@ -182,13 +182,13 @@
|
|
|
182
182
|
"itemId": 10209,
|
|
183
183
|
"kind": "builddock",
|
|
184
184
|
"displayLabel": "",
|
|
185
|
-
"baseCapacityFn": "
|
|
185
|
+
"baseCapacityFn": "structure"
|
|
186
186
|
},
|
|
187
187
|
{
|
|
188
188
|
"itemId": 10216,
|
|
189
189
|
"kind": "nexus",
|
|
190
190
|
"displayLabel": "",
|
|
191
|
-
"baseCapacityFn": "
|
|
191
|
+
"baseCapacityFn": "structure"
|
|
192
192
|
},
|
|
193
193
|
{
|
|
194
194
|
"itemId": 11212,
|
|
@@ -208,6 +208,96 @@
|
|
|
208
208
|
"displayLabel": "Dredger",
|
|
209
209
|
"baseCapacityFn": "ship"
|
|
210
210
|
},
|
|
211
|
+
{
|
|
212
|
+
"itemId": 11215,
|
|
213
|
+
"kind": "ship",
|
|
214
|
+
"displayLabel": "Tender",
|
|
215
|
+
"baseCapacityFn": "ship"
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
"itemId": 11216,
|
|
219
|
+
"kind": "ship",
|
|
220
|
+
"displayLabel": "Tender",
|
|
221
|
+
"baseCapacityFn": "ship"
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
"itemId": 11217,
|
|
225
|
+
"kind": "ship",
|
|
226
|
+
"displayLabel": "Wright",
|
|
227
|
+
"baseCapacityFn": "ship"
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
"itemId": 11218,
|
|
231
|
+
"kind": "ship",
|
|
232
|
+
"displayLabel": "Wright",
|
|
233
|
+
"baseCapacityFn": "ship"
|
|
234
|
+
},
|
|
235
|
+
{
|
|
236
|
+
"itemId": 11219,
|
|
237
|
+
"kind": "ship",
|
|
238
|
+
"displayLabel": "Tug",
|
|
239
|
+
"baseCapacityFn": "ship"
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
"itemId": 11220,
|
|
243
|
+
"kind": "ship",
|
|
244
|
+
"displayLabel": "Tug",
|
|
245
|
+
"baseCapacityFn": "ship"
|
|
246
|
+
},
|
|
247
|
+
{
|
|
248
|
+
"itemId": 11221,
|
|
249
|
+
"kind": "ship",
|
|
250
|
+
"displayLabel": "Porter",
|
|
251
|
+
"baseCapacityFn": "ship"
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
"itemId": 11222,
|
|
255
|
+
"kind": "ship",
|
|
256
|
+
"displayLabel": "Porter",
|
|
257
|
+
"baseCapacityFn": "ship"
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
"itemId": 11223,
|
|
261
|
+
"kind": "ship",
|
|
262
|
+
"displayLabel": "Smith",
|
|
263
|
+
"baseCapacityFn": "ship"
|
|
264
|
+
},
|
|
265
|
+
{
|
|
266
|
+
"itemId": 11224,
|
|
267
|
+
"kind": "ship",
|
|
268
|
+
"displayLabel": "Smith",
|
|
269
|
+
"baseCapacityFn": "ship"
|
|
270
|
+
},
|
|
271
|
+
{
|
|
272
|
+
"itemId": 11225,
|
|
273
|
+
"kind": "ship",
|
|
274
|
+
"displayLabel": "Trawler",
|
|
275
|
+
"baseCapacityFn": "ship"
|
|
276
|
+
},
|
|
277
|
+
{
|
|
278
|
+
"itemId": 11226,
|
|
279
|
+
"kind": "ship",
|
|
280
|
+
"displayLabel": "Steward",
|
|
281
|
+
"baseCapacityFn": "ship"
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
"itemId": 11227,
|
|
285
|
+
"kind": "ship",
|
|
286
|
+
"displayLabel": "Wrangler",
|
|
287
|
+
"baseCapacityFn": "ship"
|
|
288
|
+
},
|
|
289
|
+
{
|
|
290
|
+
"itemId": 11228,
|
|
291
|
+
"kind": "ship",
|
|
292
|
+
"displayLabel": "Artisan",
|
|
293
|
+
"baseCapacityFn": "ship"
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
"itemId": 11229,
|
|
297
|
+
"kind": "ship",
|
|
298
|
+
"displayLabel": "Outfitter",
|
|
299
|
+
"baseCapacityFn": "ship"
|
|
300
|
+
},
|
|
211
301
|
{
|
|
212
302
|
"itemId": 10219,
|
|
213
303
|
"kind": "depot",
|
|
@@ -224,13 +314,13 @@
|
|
|
224
314
|
"itemId": 11203,
|
|
225
315
|
"kind": "extractor",
|
|
226
316
|
"displayLabel": "",
|
|
227
|
-
"baseCapacityFn": "
|
|
317
|
+
"baseCapacityFn": "structure"
|
|
228
318
|
},
|
|
229
319
|
{
|
|
230
320
|
"itemId": 11204,
|
|
231
321
|
"kind": "factory",
|
|
232
322
|
"displayLabel": "",
|
|
233
|
-
"baseCapacityFn": "
|
|
323
|
+
"baseCapacityFn": "structure"
|
|
234
324
|
},
|
|
235
325
|
{
|
|
236
326
|
"itemId": 11207,
|
|
@@ -242,7 +332,7 @@
|
|
|
242
332
|
"itemId": 11209,
|
|
243
333
|
"kind": "asmblyard",
|
|
244
334
|
"displayLabel": "Assembly Yard",
|
|
245
|
-
"baseCapacityFn": "
|
|
335
|
+
"baseCapacityFn": "structure"
|
|
246
336
|
}
|
|
247
337
|
]
|
|
248
338
|
}
|
package/src/data/metadata.ts
CHANGED
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
import items from './items.json'
|
|
2
2
|
|
|
3
|
+
export type ComponentProcess = 'refined' | 'machined'
|
|
4
|
+
|
|
3
5
|
export interface ItemFamily {
|
|
4
6
|
name: string
|
|
5
7
|
description: string
|
|
6
8
|
color: string
|
|
9
|
+
process?: ComponentProcess
|
|
7
10
|
}
|
|
8
11
|
|
|
9
12
|
export interface EntityMetadata {
|
|
@@ -14,27 +17,27 @@ export const itemFamilies: Record<string, ItemFamily> = {
|
|
|
14
17
|
// === Resources ===
|
|
15
18
|
ore: {
|
|
16
19
|
name: 'Ore',
|
|
17
|
-
description: '
|
|
20
|
+
description: 'Goes into Plate and Beam.',
|
|
18
21
|
color: '#C26D3F',
|
|
19
22
|
},
|
|
20
23
|
crystal: {
|
|
21
24
|
name: 'Crystal',
|
|
22
|
-
description: '
|
|
25
|
+
description: 'Goes into Sensors and Resonators.',
|
|
23
26
|
color: '#4ADBFF',
|
|
24
27
|
},
|
|
25
28
|
gas: {
|
|
26
29
|
name: 'Gas',
|
|
27
|
-
description: '
|
|
30
|
+
description: 'Goes into Plasma Cells and Reactors.',
|
|
28
31
|
color: '#B877FF',
|
|
29
32
|
},
|
|
30
33
|
regolith: {
|
|
31
34
|
name: 'Regolith',
|
|
32
|
-
description: '
|
|
35
|
+
description: 'Goes into Ceramic and Frame.',
|
|
33
36
|
color: '#C4A57B',
|
|
34
37
|
},
|
|
35
38
|
biomass: {
|
|
36
39
|
name: 'Biomass',
|
|
37
|
-
description: '
|
|
40
|
+
description: 'Goes into Polymer and Resin.',
|
|
38
41
|
color: '#5A8B3E',
|
|
39
42
|
},
|
|
40
43
|
|
|
@@ -43,51 +46,61 @@ export const itemFamilies: Record<string, ItemFamily> = {
|
|
|
43
46
|
name: 'Plate',
|
|
44
47
|
description: 'Goes into Cargo Holds, Containers, and hulls.',
|
|
45
48
|
color: '#7B8D9E',
|
|
49
|
+
process: 'refined',
|
|
46
50
|
},
|
|
47
51
|
frame: {
|
|
48
52
|
name: 'Frame',
|
|
49
53
|
description: 'Goes into Limpet Bays, Cargo Holds, and hulls.',
|
|
50
54
|
color: '#C4A57B',
|
|
55
|
+
process: 'machined',
|
|
51
56
|
},
|
|
52
57
|
'plasma-cell': {
|
|
53
58
|
name: 'Plasma Cell',
|
|
54
59
|
description: 'Goes into Engines, Battery Banks, and hulls.',
|
|
55
60
|
color: '#E86344',
|
|
61
|
+
process: 'refined',
|
|
56
62
|
},
|
|
57
63
|
resonator: {
|
|
58
64
|
name: 'Resonator',
|
|
59
65
|
description: 'Goes into Power Cores, Tractor Beams, Warp Drives, and hulls.',
|
|
60
66
|
color: '#4ADBFF',
|
|
67
|
+
process: 'machined',
|
|
61
68
|
},
|
|
62
69
|
beam: {
|
|
63
70
|
name: 'Beam',
|
|
64
71
|
description: 'Goes into Limpet Bays and hulls.',
|
|
65
72
|
color: '#7B8D9E',
|
|
73
|
+
process: 'machined',
|
|
66
74
|
},
|
|
67
75
|
sensor: {
|
|
68
76
|
name: 'Sensor',
|
|
69
77
|
description: 'Goes into Fabricators, Assembly Arms, and hulls.',
|
|
70
78
|
color: '#4ADBFF',
|
|
79
|
+
process: 'refined',
|
|
71
80
|
},
|
|
72
81
|
polymer: {
|
|
73
82
|
name: 'Polymer',
|
|
74
83
|
description: 'Goes into Shuttle Bays, Battery Banks, and hulls.',
|
|
75
84
|
color: '#5A8B3E',
|
|
85
|
+
process: 'refined',
|
|
76
86
|
},
|
|
77
87
|
ceramic: {
|
|
78
88
|
name: 'Ceramic',
|
|
79
89
|
description: 'Goes into Assembly Arms, Containers, and hulls.',
|
|
80
90
|
color: '#C4A57B',
|
|
91
|
+
process: 'refined',
|
|
81
92
|
},
|
|
82
93
|
reactor: {
|
|
83
94
|
name: 'Reactor',
|
|
84
95
|
description: 'Goes into Fabricators, Warp Drives, and hulls.',
|
|
85
96
|
color: '#B877FF',
|
|
97
|
+
process: 'machined',
|
|
86
98
|
},
|
|
87
99
|
resin: {
|
|
88
100
|
name: 'Resin',
|
|
89
101
|
description: 'Goes into Tractor Beams and hulls.',
|
|
90
102
|
color: '#5A8B3E',
|
|
103
|
+
process: 'machined',
|
|
91
104
|
},
|
|
92
105
|
|
|
93
106
|
// === Modules ===
|
|
@@ -254,6 +267,31 @@ export const itemFamilies: Record<string, ItemFamily> = {
|
|
|
254
267
|
description: 'A gathering ship with a hold for longer runs.',
|
|
255
268
|
color: '#4AE898',
|
|
256
269
|
},
|
|
270
|
+
trawler: {
|
|
271
|
+
name: 'Trawler',
|
|
272
|
+
description: 'A gathering ship that tows a container for longer runs.',
|
|
273
|
+
color: '#4AE898',
|
|
274
|
+
},
|
|
275
|
+
steward: {
|
|
276
|
+
name: 'Steward',
|
|
277
|
+
description: 'A transfer ship with a hold for the cargo it moves.',
|
|
278
|
+
color: '#4AE898',
|
|
279
|
+
},
|
|
280
|
+
wrangler: {
|
|
281
|
+
name: 'Wrangler',
|
|
282
|
+
description: 'A transfer ship that also tows.',
|
|
283
|
+
color: '#4AE898',
|
|
284
|
+
},
|
|
285
|
+
artisan: {
|
|
286
|
+
name: 'Artisan',
|
|
287
|
+
description: 'A crafting ship with a hold for its materials.',
|
|
288
|
+
color: '#4AE898',
|
|
289
|
+
},
|
|
290
|
+
outfitter: {
|
|
291
|
+
name: 'Outfitter',
|
|
292
|
+
description: 'A construction ship with a hold for upgrade materials.',
|
|
293
|
+
color: '#4AE898',
|
|
294
|
+
},
|
|
257
295
|
}
|
|
258
296
|
|
|
259
297
|
const COMPONENT_FAMILIES = [
|
|
@@ -298,6 +336,21 @@ const ENTITY_FAMILIES: Record<number, string> = {
|
|
|
298
336
|
11212: 'prospector',
|
|
299
337
|
11213: 'prospector',
|
|
300
338
|
11214: 'dredger',
|
|
339
|
+
11215: 'tender',
|
|
340
|
+
11216: 'tender',
|
|
341
|
+
11217: 'wright',
|
|
342
|
+
11218: 'wright',
|
|
343
|
+
11219: 'tug',
|
|
344
|
+
11220: 'tug',
|
|
345
|
+
11221: 'porter',
|
|
346
|
+
11222: 'porter',
|
|
347
|
+
11223: 'smith',
|
|
348
|
+
11224: 'smith',
|
|
349
|
+
11225: 'trawler',
|
|
350
|
+
11226: 'steward',
|
|
351
|
+
11227: 'wrangler',
|
|
352
|
+
11228: 'artisan',
|
|
353
|
+
11229: 'outfitter',
|
|
301
354
|
}
|
|
302
355
|
|
|
303
356
|
interface RawItem {
|
|
@@ -371,6 +424,31 @@ export const entityMetadata: Record<number, EntityMetadata> = {
|
|
|
371
424
|
11214: {
|
|
372
425
|
moduleSlotLabels: ['Power Core', 'Engine', 'Limpet Bay', 'Cargo Hold'],
|
|
373
426
|
},
|
|
427
|
+
11215: {moduleSlotLabels: ['Power Core', 'Engine', 'Shuttle Bay']},
|
|
428
|
+
11216: {
|
|
429
|
+
moduleSlotLabels: ['Power Core', 'Engine', 'Auxiliary System', 'Shuttle Bay'],
|
|
430
|
+
},
|
|
431
|
+
11217: {moduleSlotLabels: ['Power Core', 'Engine', 'Assembly Arm']},
|
|
432
|
+
11218: {
|
|
433
|
+
moduleSlotLabels: ['Power Core', 'Engine', 'Auxiliary System', 'Assembly Arm'],
|
|
434
|
+
},
|
|
435
|
+
11219: {moduleSlotLabels: ['Power Core', 'Engine', 'Tractor Beam']},
|
|
436
|
+
11220: {
|
|
437
|
+
moduleSlotLabels: ['Power Core', 'Engine', 'Auxiliary System', 'Tractor Beam'],
|
|
438
|
+
},
|
|
439
|
+
11221: {moduleSlotLabels: ['Power Core', 'Engine', 'Cargo Hold']},
|
|
440
|
+
11222: {
|
|
441
|
+
moduleSlotLabels: ['Power Core', 'Engine', 'Auxiliary System', 'Cargo Hold'],
|
|
442
|
+
},
|
|
443
|
+
11223: {moduleSlotLabels: ['Power Core', 'Engine', 'Fabricator']},
|
|
444
|
+
11224: {
|
|
445
|
+
moduleSlotLabels: ['Power Core', 'Engine', 'Auxiliary System', 'Fabricator'],
|
|
446
|
+
},
|
|
447
|
+
11225: {moduleSlotLabels: ['Power Core', 'Engine', 'Limpet Bay', 'Tractor Beam']},
|
|
448
|
+
11226: {moduleSlotLabels: ['Power Core', 'Engine', 'Shuttle Bay', 'Cargo Hold']},
|
|
449
|
+
11227: {moduleSlotLabels: ['Power Core', 'Engine', 'Shuttle Bay', 'Tractor Beam']},
|
|
450
|
+
11228: {moduleSlotLabels: ['Power Core', 'Engine', 'Fabricator', 'Cargo Hold']},
|
|
451
|
+
11229: {moduleSlotLabels: ['Power Core', 'Engine', 'Assembly Arm', 'Cargo Hold']},
|
|
374
452
|
11202: {
|
|
375
453
|
moduleSlotLabels: ['Shuttle Bay', 'Cargo Hold', 'Cargo Hold', 'Cargo Hold', 'Cargo Hold'],
|
|
376
454
|
},
|