@shipload/sdk 2.0.0-rc4 → 2.0.0-rc6
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 +411 -1025
- package/lib/shipload.js +879 -2057
- package/lib/shipload.js.map +1 -1
- package/lib/shipload.m.js +852 -2028
- package/lib/shipload.m.js.map +1 -1
- package/package.json +1 -1
- package/src/capabilities/crafting.ts +10 -0
- package/src/capabilities/guards.ts +0 -5
- package/src/capabilities/index.ts +1 -0
- package/src/capabilities/storage.ts +0 -8
- package/src/contracts/server.ts +106 -225
- package/src/data/items.json +15 -14
- package/src/data/recipes.ts +129 -0
- package/src/derivation/crafting.ts +120 -0
- package/src/derivation/index.ts +9 -6
- package/src/derivation/resources.ts +54 -53
- package/src/derivation/stats.ts +146 -0
- package/src/derivation/stratum.ts +14 -14
- package/src/entities/cargo-utils.ts +6 -64
- package/src/entities/container.ts +18 -0
- package/src/entities/entity-inventory.ts +0 -4
- package/src/entities/inventory-accessor.ts +0 -4
- package/src/entities/location.ts +2 -197
- package/src/entities/player.ts +1 -274
- package/src/entities/ship.ts +0 -21
- package/src/entities/warehouse.ts +0 -4
- package/src/index-module.ts +43 -47
- package/src/managers/actions.ts +38 -90
- package/src/managers/context.ts +0 -9
- package/src/managers/index.ts +0 -1
- package/src/managers/locations.ts +2 -85
- package/src/market/items.ts +1 -2
- package/src/scheduling/projection.ts +0 -10
- package/src/shipload.ts +0 -5
- package/src/types/capabilities.ts +1 -9
- package/src/types/entity-traits.ts +3 -4
- package/src/types/entity.ts +0 -1
- package/src/types.ts +8 -28
- package/src/utils/system.ts +5 -4
- package/src/managers/trades.ts +0 -119
- package/src/market/market.ts +0 -208
- package/src/market/rolls.ts +0 -8
- package/src/trading/collect.ts +0 -938
- package/src/trading/deal.ts +0 -207
- package/src/trading/trade.ts +0 -203
package/lib/shipload.js
CHANGED
|
@@ -213,7 +213,7 @@ var platform = /*#__PURE__*/Object.freeze({
|
|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rX3Jlc3VsdHMAAAAgI3NzVwx0YXNrX3Jlc3VsdHMAAGBuTYqyYgtnYW1lX2NvbmZpZwCwctnlqbJiDWVudGl0eV9pbmZvW10AAPDZ5amyYgtlbnRpdHlfaW5mbwAAAFiq7LJiCml0ZW1zX2luZm8AJnXZIBqzYg1sb2NhdGlvbl9pbmZvAIDJJiEas2IQbG9jYXRpb25fZGVyaXZlZAAA8OcaNbNiC25lYXJieV9pbmZvAAC4yptYs2ILcGxheWVyX2luZm8AwFX5moyzYgxzdGFydGVyX2luZm8AgNTZ3IyzYgxzdHJhdHVtX2RhdGGAlbtGSo2zYhBlbnRpdHlfc3VtbWFyeVtdAKLa5uaq6WUMdGFza19yZXN1bHRzAAAAAADQsGkLY2hlY2tzdW0yNTYAAABAhNKwaQtjaGVja3N1bTUxMgAAAIpd05C6DHRhc2tfcmVzdWx0cwAAAEDtSLG6D3Jlc29sdmVfcmVzdWx0cwAAAFctPM3NDHRhc2tfcmVzdWx0cwAAAABEtc3NDHRhc2tfcmVzdWx0cwAAAAAAUK/hDHRhc2tfcmVzdWx0cw==');
|
|
217
217
|
const abi = antelope.ABI.from(abiBlob);
|
|
218
218
|
var Types;
|
|
219
219
|
(function (Types) {
|
|
@@ -229,66 +229,6 @@ var Types;
|
|
|
229
229
|
antelope.Struct.type('advance')
|
|
230
230
|
], advance);
|
|
231
231
|
Types.advance = advance;
|
|
232
|
-
let buycontainer = class buycontainer extends antelope.Struct {
|
|
233
|
-
};
|
|
234
|
-
tslib.__decorate([
|
|
235
|
-
antelope.Struct.field(antelope.Name)
|
|
236
|
-
], buycontainer.prototype, "account", void 0);
|
|
237
|
-
tslib.__decorate([
|
|
238
|
-
antelope.Struct.field(antelope.UInt64)
|
|
239
|
-
], buycontainer.prototype, "ship_id", void 0);
|
|
240
|
-
tslib.__decorate([
|
|
241
|
-
antelope.Struct.field('string')
|
|
242
|
-
], buycontainer.prototype, "name", void 0);
|
|
243
|
-
buycontainer = tslib.__decorate([
|
|
244
|
-
antelope.Struct.type('buycontainer')
|
|
245
|
-
], buycontainer);
|
|
246
|
-
Types.buycontainer = buycontainer;
|
|
247
|
-
let buyitems = class buyitems extends antelope.Struct {
|
|
248
|
-
};
|
|
249
|
-
tslib.__decorate([
|
|
250
|
-
antelope.Struct.field(antelope.Name)
|
|
251
|
-
], buyitems.prototype, "entity_type", void 0);
|
|
252
|
-
tslib.__decorate([
|
|
253
|
-
antelope.Struct.field(antelope.UInt64)
|
|
254
|
-
], buyitems.prototype, "id", void 0);
|
|
255
|
-
tslib.__decorate([
|
|
256
|
-
antelope.Struct.field(antelope.UInt16)
|
|
257
|
-
], buyitems.prototype, "item_id", void 0);
|
|
258
|
-
tslib.__decorate([
|
|
259
|
-
antelope.Struct.field(antelope.UInt32)
|
|
260
|
-
], buyitems.prototype, "quantity", void 0);
|
|
261
|
-
buyitems = tslib.__decorate([
|
|
262
|
-
antelope.Struct.type('buyitems')
|
|
263
|
-
], buyitems);
|
|
264
|
-
Types.buyitems = buyitems;
|
|
265
|
-
let buyship = class buyship extends antelope.Struct {
|
|
266
|
-
};
|
|
267
|
-
tslib.__decorate([
|
|
268
|
-
antelope.Struct.field(antelope.Name)
|
|
269
|
-
], buyship.prototype, "account", void 0);
|
|
270
|
-
tslib.__decorate([
|
|
271
|
-
antelope.Struct.field('string')
|
|
272
|
-
], buyship.prototype, "name", void 0);
|
|
273
|
-
buyship = tslib.__decorate([
|
|
274
|
-
antelope.Struct.type('buyship')
|
|
275
|
-
], buyship);
|
|
276
|
-
Types.buyship = buyship;
|
|
277
|
-
let buywarehouse = class buywarehouse extends antelope.Struct {
|
|
278
|
-
};
|
|
279
|
-
tslib.__decorate([
|
|
280
|
-
antelope.Struct.field(antelope.Name)
|
|
281
|
-
], buywarehouse.prototype, "account", void 0);
|
|
282
|
-
tslib.__decorate([
|
|
283
|
-
antelope.Struct.field(antelope.UInt64)
|
|
284
|
-
], buywarehouse.prototype, "ship_id", void 0);
|
|
285
|
-
tslib.__decorate([
|
|
286
|
-
antelope.Struct.field('string')
|
|
287
|
-
], buywarehouse.prototype, "name", void 0);
|
|
288
|
-
buywarehouse = tslib.__decorate([
|
|
289
|
-
antelope.Struct.type('buywarehouse')
|
|
290
|
-
], buywarehouse);
|
|
291
|
-
Types.buywarehouse = buywarehouse;
|
|
292
232
|
let cancel = class cancel extends antelope.Struct {
|
|
293
233
|
};
|
|
294
234
|
tslib.__decorate([
|
|
@@ -348,9 +288,6 @@ var Types;
|
|
|
348
288
|
tslib.__decorate([
|
|
349
289
|
antelope.Struct.field(antelope.UInt32)
|
|
350
290
|
], cargo_item.prototype, "quantity", void 0);
|
|
351
|
-
tslib.__decorate([
|
|
352
|
-
antelope.Struct.field(antelope.UInt64)
|
|
353
|
-
], cargo_item.prototype, "unit_cost", void 0);
|
|
354
291
|
tslib.__decorate([
|
|
355
292
|
antelope.Struct.field(antelope.UInt64, { optional: true })
|
|
356
293
|
], cargo_item.prototype, "seed", void 0);
|
|
@@ -372,9 +309,6 @@ var Types;
|
|
|
372
309
|
tslib.__decorate([
|
|
373
310
|
antelope.Struct.field(antelope.UInt64)
|
|
374
311
|
], cargo_row.prototype, "quantity", void 0);
|
|
375
|
-
tslib.__decorate([
|
|
376
|
-
antelope.Struct.field(antelope.UInt64)
|
|
377
|
-
], cargo_row.prototype, "unit_cost", void 0);
|
|
378
312
|
tslib.__decorate([
|
|
379
313
|
antelope.Struct.field(antelope.UInt64)
|
|
380
314
|
], cargo_row.prototype, "seed", void 0);
|
|
@@ -457,15 +391,6 @@ var Types;
|
|
|
457
391
|
antelope.Struct.type('loader_stats')
|
|
458
392
|
], loader_stats);
|
|
459
393
|
Types.loader_stats = loader_stats;
|
|
460
|
-
let trade_stats = class trade_stats extends antelope.Struct {
|
|
461
|
-
};
|
|
462
|
-
tslib.__decorate([
|
|
463
|
-
antelope.Struct.field(antelope.UInt16)
|
|
464
|
-
], trade_stats.prototype, "margin", void 0);
|
|
465
|
-
trade_stats = tslib.__decorate([
|
|
466
|
-
antelope.Struct.type('trade_stats')
|
|
467
|
-
], trade_stats);
|
|
468
|
-
Types.trade_stats = trade_stats;
|
|
469
394
|
let extractor_stats = class extractor_stats extends antelope.Struct {
|
|
470
395
|
};
|
|
471
396
|
tslib.__decorate([
|
|
@@ -496,6 +421,18 @@ var Types;
|
|
|
496
421
|
antelope.Struct.type('warp_stats')
|
|
497
422
|
], warp_stats);
|
|
498
423
|
Types.warp_stats = warp_stats;
|
|
424
|
+
let crafter_stats = class crafter_stats extends antelope.Struct {
|
|
425
|
+
};
|
|
426
|
+
tslib.__decorate([
|
|
427
|
+
antelope.Struct.field(antelope.UInt16)
|
|
428
|
+
], crafter_stats.prototype, "speed", void 0);
|
|
429
|
+
tslib.__decorate([
|
|
430
|
+
antelope.Struct.field(antelope.UInt16)
|
|
431
|
+
], crafter_stats.prototype, "drain", void 0);
|
|
432
|
+
crafter_stats = tslib.__decorate([
|
|
433
|
+
antelope.Struct.type('crafter_stats')
|
|
434
|
+
], crafter_stats);
|
|
435
|
+
Types.crafter_stats = crafter_stats;
|
|
499
436
|
let entity_defaults = class entity_defaults extends antelope.Struct {
|
|
500
437
|
};
|
|
501
438
|
tslib.__decorate([
|
|
@@ -519,15 +456,15 @@ var Types;
|
|
|
519
456
|
tslib.__decorate([
|
|
520
457
|
antelope.Struct.field(loader_stats)
|
|
521
458
|
], entity_defaults.prototype, "ship_loaders", void 0);
|
|
522
|
-
tslib.__decorate([
|
|
523
|
-
antelope.Struct.field(trade_stats)
|
|
524
|
-
], entity_defaults.prototype, "ship_trade", void 0);
|
|
525
459
|
tslib.__decorate([
|
|
526
460
|
antelope.Struct.field(extractor_stats)
|
|
527
461
|
], entity_defaults.prototype, "ship_extractor", void 0);
|
|
528
462
|
tslib.__decorate([
|
|
529
463
|
antelope.Struct.field(warp_stats)
|
|
530
464
|
], entity_defaults.prototype, "ship_warp", void 0);
|
|
465
|
+
tslib.__decorate([
|
|
466
|
+
antelope.Struct.field(crafter_stats)
|
|
467
|
+
], entity_defaults.prototype, "ship_crafter", void 0);
|
|
531
468
|
tslib.__decorate([
|
|
532
469
|
antelope.Struct.field(antelope.UInt32)
|
|
533
470
|
], entity_defaults.prototype, "warehouse_capacity", void 0);
|
|
@@ -555,9 +492,6 @@ var Types;
|
|
|
555
492
|
tslib.__decorate([
|
|
556
493
|
antelope.Struct.field(antelope.UInt16)
|
|
557
494
|
], item_def.prototype, "id", void 0);
|
|
558
|
-
tslib.__decorate([
|
|
559
|
-
antelope.Struct.field(antelope.UInt32)
|
|
560
|
-
], item_def.prototype, "base_price", void 0);
|
|
561
495
|
tslib.__decorate([
|
|
562
496
|
antelope.Struct.field(antelope.UInt32)
|
|
563
497
|
], item_def.prototype, "mass", void 0);
|
|
@@ -627,9 +561,6 @@ var Types;
|
|
|
627
561
|
tslib.__decorate([
|
|
628
562
|
antelope.Struct.field(antelope.UInt64, { optional: true })
|
|
629
563
|
], task.prototype, "entitygroup", void 0);
|
|
630
|
-
tslib.__decorate([
|
|
631
|
-
antelope.Struct.field(antelope.Int64, { optional: true })
|
|
632
|
-
], task.prototype, "credits", void 0);
|
|
633
564
|
tslib.__decorate([
|
|
634
565
|
antelope.Struct.field(antelope.UInt16, { optional: true })
|
|
635
566
|
], task.prototype, "energy_cost", void 0);
|
|
@@ -679,6 +610,69 @@ var Types;
|
|
|
679
610
|
antelope.Struct.type('container_row')
|
|
680
611
|
], container_row);
|
|
681
612
|
Types.container_row = container_row;
|
|
613
|
+
let craft = class craft extends antelope.Struct {
|
|
614
|
+
};
|
|
615
|
+
tslib.__decorate([
|
|
616
|
+
antelope.Struct.field(antelope.Name)
|
|
617
|
+
], craft.prototype, "entity_type", void 0);
|
|
618
|
+
tslib.__decorate([
|
|
619
|
+
antelope.Struct.field(antelope.UInt64)
|
|
620
|
+
], craft.prototype, "id", void 0);
|
|
621
|
+
tslib.__decorate([
|
|
622
|
+
antelope.Struct.field(antelope.UInt16)
|
|
623
|
+
], craft.prototype, "recipe_id", void 0);
|
|
624
|
+
tslib.__decorate([
|
|
625
|
+
antelope.Struct.field(antelope.UInt32)
|
|
626
|
+
], craft.prototype, "quantity", void 0);
|
|
627
|
+
tslib.__decorate([
|
|
628
|
+
antelope.Struct.field(cargo_item, { array: true })
|
|
629
|
+
], craft.prototype, "inputs", void 0);
|
|
630
|
+
craft = tslib.__decorate([
|
|
631
|
+
antelope.Struct.type('craft')
|
|
632
|
+
], craft);
|
|
633
|
+
Types.craft = craft;
|
|
634
|
+
let createentity = class createentity extends antelope.Struct {
|
|
635
|
+
};
|
|
636
|
+
tslib.__decorate([
|
|
637
|
+
antelope.Struct.field(antelope.Name)
|
|
638
|
+
], createentity.prototype, "owner", void 0);
|
|
639
|
+
tslib.__decorate([
|
|
640
|
+
antelope.Struct.field(antelope.Name)
|
|
641
|
+
], createentity.prototype, "entity_type", void 0);
|
|
642
|
+
tslib.__decorate([
|
|
643
|
+
antelope.Struct.field('string')
|
|
644
|
+
], createentity.prototype, "entity_name", void 0);
|
|
645
|
+
tslib.__decorate([
|
|
646
|
+
antelope.Struct.field(antelope.Int64)
|
|
647
|
+
], createentity.prototype, "x", void 0);
|
|
648
|
+
tslib.__decorate([
|
|
649
|
+
antelope.Struct.field(antelope.Int64)
|
|
650
|
+
], createentity.prototype, "y", void 0);
|
|
651
|
+
createentity = tslib.__decorate([
|
|
652
|
+
antelope.Struct.type('createentity')
|
|
653
|
+
], createentity);
|
|
654
|
+
Types.createentity = createentity;
|
|
655
|
+
let deploy = class deploy extends antelope.Struct {
|
|
656
|
+
};
|
|
657
|
+
tslib.__decorate([
|
|
658
|
+
antelope.Struct.field(antelope.Name)
|
|
659
|
+
], deploy.prototype, "entity_type", void 0);
|
|
660
|
+
tslib.__decorate([
|
|
661
|
+
antelope.Struct.field(antelope.UInt64)
|
|
662
|
+
], deploy.prototype, "id", void 0);
|
|
663
|
+
tslib.__decorate([
|
|
664
|
+
antelope.Struct.field(antelope.UInt16)
|
|
665
|
+
], deploy.prototype, "packed_item_id", void 0);
|
|
666
|
+
tslib.__decorate([
|
|
667
|
+
antelope.Struct.field(antelope.UInt64)
|
|
668
|
+
], deploy.prototype, "seed", void 0);
|
|
669
|
+
tslib.__decorate([
|
|
670
|
+
antelope.Struct.field('string')
|
|
671
|
+
], deploy.prototype, "entity_name", void 0);
|
|
672
|
+
deploy = tslib.__decorate([
|
|
673
|
+
antelope.Struct.type('deploy')
|
|
674
|
+
], deploy);
|
|
675
|
+
Types.deploy = deploy;
|
|
682
676
|
let enable = class enable extends antelope.Struct {
|
|
683
677
|
};
|
|
684
678
|
tslib.__decorate([
|
|
@@ -747,6 +741,9 @@ var Types;
|
|
|
747
741
|
tslib.__decorate([
|
|
748
742
|
antelope.Struct.field(warp_stats, { optional: true })
|
|
749
743
|
], entity_info.prototype, "warp", void 0);
|
|
744
|
+
tslib.__decorate([
|
|
745
|
+
antelope.Struct.field(crafter_stats, { optional: true })
|
|
746
|
+
], entity_info.prototype, "crafter", void 0);
|
|
750
747
|
tslib.__decorate([
|
|
751
748
|
antelope.Struct.field('bool')
|
|
752
749
|
], entity_info.prototype, "is_idle", void 0);
|
|
@@ -1081,27 +1078,6 @@ var Types;
|
|
|
1081
1078
|
antelope.Struct.type('location_derived')
|
|
1082
1079
|
], location_derived);
|
|
1083
1080
|
Types.location_derived = location_derived;
|
|
1084
|
-
let location_item = class location_item extends antelope.Struct {
|
|
1085
|
-
};
|
|
1086
|
-
tslib.__decorate([
|
|
1087
|
-
antelope.Struct.field(antelope.UInt16)
|
|
1088
|
-
], location_item.prototype, "id", void 0);
|
|
1089
|
-
tslib.__decorate([
|
|
1090
|
-
antelope.Struct.field(antelope.UInt32)
|
|
1091
|
-
], location_item.prototype, "price", void 0);
|
|
1092
|
-
tslib.__decorate([
|
|
1093
|
-
antelope.Struct.field(antelope.UInt16)
|
|
1094
|
-
], location_item.prototype, "supply", void 0);
|
|
1095
|
-
tslib.__decorate([
|
|
1096
|
-
antelope.Struct.field(antelope.UInt32)
|
|
1097
|
-
], location_item.prototype, "rarity_multiplier", void 0);
|
|
1098
|
-
tslib.__decorate([
|
|
1099
|
-
antelope.Struct.field(antelope.UInt32)
|
|
1100
|
-
], location_item.prototype, "location_multiplier", void 0);
|
|
1101
|
-
location_item = tslib.__decorate([
|
|
1102
|
-
antelope.Struct.type('location_item')
|
|
1103
|
-
], location_item);
|
|
1104
|
-
Types.location_item = location_item;
|
|
1105
1081
|
let location_info = class location_info extends antelope.Struct {
|
|
1106
1082
|
};
|
|
1107
1083
|
tslib.__decorate([
|
|
@@ -1110,9 +1086,6 @@ var Types;
|
|
|
1110
1086
|
tslib.__decorate([
|
|
1111
1087
|
antelope.Struct.field('bool')
|
|
1112
1088
|
], location_info.prototype, "is_system", void 0);
|
|
1113
|
-
tslib.__decorate([
|
|
1114
|
-
antelope.Struct.field(location_item, { array: true })
|
|
1115
|
-
], location_info.prototype, "items", void 0);
|
|
1116
1089
|
location_info = tslib.__decorate([
|
|
1117
1090
|
antelope.Struct.type('location_info')
|
|
1118
1091
|
], location_info);
|
|
@@ -1222,18 +1195,6 @@ var Types;
|
|
|
1222
1195
|
antelope.Struct.type('notify')
|
|
1223
1196
|
], notify);
|
|
1224
1197
|
Types.notify = notify;
|
|
1225
|
-
let payloan = class payloan extends antelope.Struct {
|
|
1226
|
-
};
|
|
1227
|
-
tslib.__decorate([
|
|
1228
|
-
antelope.Struct.field(antelope.Name)
|
|
1229
|
-
], payloan.prototype, "account", void 0);
|
|
1230
|
-
tslib.__decorate([
|
|
1231
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1232
|
-
], payloan.prototype, "amount", void 0);
|
|
1233
|
-
payloan = tslib.__decorate([
|
|
1234
|
-
antelope.Struct.type('payloan')
|
|
1235
|
-
], payloan);
|
|
1236
|
-
Types.payloan = payloan;
|
|
1237
1198
|
let player_info = class player_info extends antelope.Struct {
|
|
1238
1199
|
};
|
|
1239
1200
|
tslib.__decorate([
|
|
@@ -1245,27 +1206,6 @@ var Types;
|
|
|
1245
1206
|
tslib.__decorate([
|
|
1246
1207
|
antelope.Struct.field('string')
|
|
1247
1208
|
], player_info.prototype, "company_name", void 0);
|
|
1248
|
-
tslib.__decorate([
|
|
1249
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1250
|
-
], player_info.prototype, "balance", void 0);
|
|
1251
|
-
tslib.__decorate([
|
|
1252
|
-
antelope.Struct.field(antelope.UInt32)
|
|
1253
|
-
], player_info.prototype, "debt", void 0);
|
|
1254
|
-
tslib.__decorate([
|
|
1255
|
-
antelope.Struct.field(antelope.Int64)
|
|
1256
|
-
], player_info.prototype, "networth", void 0);
|
|
1257
|
-
tslib.__decorate([
|
|
1258
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1259
|
-
], player_info.prototype, "available_loan", void 0);
|
|
1260
|
-
tslib.__decorate([
|
|
1261
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1262
|
-
], player_info.prototype, "next_ship_price", void 0);
|
|
1263
|
-
tslib.__decorate([
|
|
1264
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1265
|
-
], player_info.prototype, "next_warehouse_price", void 0);
|
|
1266
|
-
tslib.__decorate([
|
|
1267
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1268
|
-
], player_info.prototype, "next_container_price", void 0);
|
|
1269
1209
|
tslib.__decorate([
|
|
1270
1210
|
antelope.Struct.field(antelope.UInt64)
|
|
1271
1211
|
], player_info.prototype, "ship_count", void 0);
|
|
@@ -1284,28 +1224,10 @@ var Types;
|
|
|
1284
1224
|
tslib.__decorate([
|
|
1285
1225
|
antelope.Struct.field(antelope.Name)
|
|
1286
1226
|
], player_row.prototype, "owner", void 0);
|
|
1287
|
-
tslib.__decorate([
|
|
1288
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1289
|
-
], player_row.prototype, "balance", void 0);
|
|
1290
|
-
tslib.__decorate([
|
|
1291
|
-
antelope.Struct.field(antelope.UInt32)
|
|
1292
|
-
], player_row.prototype, "debt", void 0);
|
|
1293
|
-
tslib.__decorate([
|
|
1294
|
-
antelope.Struct.field(antelope.Int64)
|
|
1295
|
-
], player_row.prototype, "networth", void 0);
|
|
1296
1227
|
player_row = tslib.__decorate([
|
|
1297
1228
|
antelope.Struct.type('player_row')
|
|
1298
1229
|
], player_row);
|
|
1299
1230
|
Types.player_row = player_row;
|
|
1300
|
-
let purgesupply = class purgesupply extends antelope.Struct {
|
|
1301
|
-
};
|
|
1302
|
-
tslib.__decorate([
|
|
1303
|
-
antelope.Struct.field(antelope.UInt64, { optional: true })
|
|
1304
|
-
], purgesupply.prototype, "max_rows", void 0);
|
|
1305
|
-
purgesupply = tslib.__decorate([
|
|
1306
|
-
antelope.Struct.type('purgesupply')
|
|
1307
|
-
], purgesupply);
|
|
1308
|
-
Types.purgesupply = purgesupply;
|
|
1309
1231
|
let recharge = class recharge extends antelope.Struct {
|
|
1310
1232
|
};
|
|
1311
1233
|
tslib.__decorate([
|
|
@@ -1373,16 +1295,13 @@ var Types;
|
|
|
1373
1295
|
};
|
|
1374
1296
|
tslib.__decorate([
|
|
1375
1297
|
antelope.Struct.field(antelope.UInt16)
|
|
1376
|
-
], resource_stats.prototype, "
|
|
1377
|
-
tslib.__decorate([
|
|
1378
|
-
antelope.Struct.field(antelope.UInt16)
|
|
1379
|
-
], resource_stats.prototype, "density", void 0);
|
|
1298
|
+
], resource_stats.prototype, "stat1", void 0);
|
|
1380
1299
|
tslib.__decorate([
|
|
1381
1300
|
antelope.Struct.field(antelope.UInt16)
|
|
1382
|
-
], resource_stats.prototype, "
|
|
1301
|
+
], resource_stats.prototype, "stat2", void 0);
|
|
1383
1302
|
tslib.__decorate([
|
|
1384
1303
|
antelope.Struct.field(antelope.UInt16)
|
|
1385
|
-
], resource_stats.prototype, "
|
|
1304
|
+
], resource_stats.prototype, "stat3", void 0);
|
|
1386
1305
|
resource_stats = tslib.__decorate([
|
|
1387
1306
|
antelope.Struct.type('resource_stats')
|
|
1388
1307
|
], resource_stats);
|
|
@@ -1396,24 +1315,6 @@ var Types;
|
|
|
1396
1315
|
antelope.Struct.type('salt')
|
|
1397
1316
|
], salt);
|
|
1398
1317
|
Types.salt = salt;
|
|
1399
|
-
let sellitems = class sellitems extends antelope.Struct {
|
|
1400
|
-
};
|
|
1401
|
-
tslib.__decorate([
|
|
1402
|
-
antelope.Struct.field(antelope.Name)
|
|
1403
|
-
], sellitems.prototype, "entity_type", void 0);
|
|
1404
|
-
tslib.__decorate([
|
|
1405
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1406
|
-
], sellitems.prototype, "id", void 0);
|
|
1407
|
-
tslib.__decorate([
|
|
1408
|
-
antelope.Struct.field(antelope.UInt16)
|
|
1409
|
-
], sellitems.prototype, "item_id", void 0);
|
|
1410
|
-
tslib.__decorate([
|
|
1411
|
-
antelope.Struct.field(antelope.UInt32)
|
|
1412
|
-
], sellitems.prototype, "quantity", void 0);
|
|
1413
|
-
sellitems = tslib.__decorate([
|
|
1414
|
-
antelope.Struct.type('sellitems')
|
|
1415
|
-
], sellitems);
|
|
1416
|
-
Types.sellitems = sellitems;
|
|
1417
1318
|
let sequence_row = class sequence_row extends antelope.Struct {
|
|
1418
1319
|
};
|
|
1419
1320
|
tslib.__decorate([
|
|
@@ -1461,15 +1362,15 @@ var Types;
|
|
|
1461
1362
|
tslib.__decorate([
|
|
1462
1363
|
antelope.Struct.field(loader_stats)
|
|
1463
1364
|
], ship_row.prototype, "loaders", void 0);
|
|
1464
|
-
tslib.__decorate([
|
|
1465
|
-
antelope.Struct.field(trade_stats, { optional: true })
|
|
1466
|
-
], ship_row.prototype, "trade", void 0);
|
|
1467
1365
|
tslib.__decorate([
|
|
1468
1366
|
antelope.Struct.field(extractor_stats, { optional: true })
|
|
1469
1367
|
], ship_row.prototype, "extractor", void 0);
|
|
1470
1368
|
tslib.__decorate([
|
|
1471
1369
|
antelope.Struct.field(warp_stats, { optional: true })
|
|
1472
1370
|
], ship_row.prototype, "warp", void 0);
|
|
1371
|
+
tslib.__decorate([
|
|
1372
|
+
antelope.Struct.field(crafter_stats, { optional: true })
|
|
1373
|
+
], ship_row.prototype, "crafter", void 0);
|
|
1473
1374
|
tslib.__decorate([
|
|
1474
1375
|
antelope.Struct.field(schedule, { optional: true })
|
|
1475
1376
|
], ship_row.prototype, "schedule", void 0);
|
|
@@ -1477,14 +1378,23 @@ var Types;
|
|
|
1477
1378
|
antelope.Struct.type('ship_row')
|
|
1478
1379
|
], ship_row);
|
|
1479
1380
|
Types.ship_row = ship_row;
|
|
1480
|
-
let
|
|
1381
|
+
let spawncargo = class spawncargo extends antelope.Struct {
|
|
1481
1382
|
};
|
|
1482
1383
|
tslib.__decorate([
|
|
1483
1384
|
antelope.Struct.field(antelope.UInt64)
|
|
1484
|
-
],
|
|
1385
|
+
], spawncargo.prototype, "entity_id", void 0);
|
|
1386
|
+
tslib.__decorate([
|
|
1387
|
+
antelope.Struct.field(antelope.UInt64)
|
|
1388
|
+
], spawncargo.prototype, "item_id", void 0);
|
|
1485
1389
|
tslib.__decorate([
|
|
1486
1390
|
antelope.Struct.field(antelope.UInt64)
|
|
1487
|
-
],
|
|
1391
|
+
], spawncargo.prototype, "quantity", void 0);
|
|
1392
|
+
spawncargo = tslib.__decorate([
|
|
1393
|
+
antelope.Struct.type('spawncargo')
|
|
1394
|
+
], spawncargo);
|
|
1395
|
+
Types.spawncargo = spawncargo;
|
|
1396
|
+
let starter_info = class starter_info extends antelope.Struct {
|
|
1397
|
+
};
|
|
1488
1398
|
tslib.__decorate([
|
|
1489
1399
|
antelope.Struct.field(entity_info)
|
|
1490
1400
|
], starter_info.prototype, "ship", void 0);
|
|
@@ -1546,39 +1456,6 @@ var Types;
|
|
|
1546
1456
|
antelope.Struct.type('stratum_data')
|
|
1547
1457
|
], stratum_data);
|
|
1548
1458
|
Types.stratum_data = stratum_data;
|
|
1549
|
-
let supply_row = class supply_row extends antelope.Struct {
|
|
1550
|
-
};
|
|
1551
|
-
tslib.__decorate([
|
|
1552
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1553
|
-
], supply_row.prototype, "id", void 0);
|
|
1554
|
-
tslib.__decorate([
|
|
1555
|
-
antelope.Struct.field(coordinates)
|
|
1556
|
-
], supply_row.prototype, "coordinates", void 0);
|
|
1557
|
-
tslib.__decorate([
|
|
1558
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1559
|
-
], supply_row.prototype, "epoch", void 0);
|
|
1560
|
-
tslib.__decorate([
|
|
1561
|
-
antelope.Struct.field(antelope.UInt16)
|
|
1562
|
-
], supply_row.prototype, "item_id", void 0);
|
|
1563
|
-
tslib.__decorate([
|
|
1564
|
-
antelope.Struct.field(antelope.UInt16)
|
|
1565
|
-
], supply_row.prototype, "supply", void 0);
|
|
1566
|
-
supply_row = tslib.__decorate([
|
|
1567
|
-
antelope.Struct.type('supply_row')
|
|
1568
|
-
], supply_row);
|
|
1569
|
-
Types.supply_row = supply_row;
|
|
1570
|
-
let takeloan = class takeloan extends antelope.Struct {
|
|
1571
|
-
};
|
|
1572
|
-
tslib.__decorate([
|
|
1573
|
-
antelope.Struct.field(antelope.Name)
|
|
1574
|
-
], takeloan.prototype, "account", void 0);
|
|
1575
|
-
tslib.__decorate([
|
|
1576
|
-
antelope.Struct.field(antelope.UInt64)
|
|
1577
|
-
], takeloan.prototype, "amount", void 0);
|
|
1578
|
-
takeloan = tslib.__decorate([
|
|
1579
|
-
antelope.Struct.type('takeloan')
|
|
1580
|
-
], takeloan);
|
|
1581
|
-
Types.takeloan = takeloan;
|
|
1582
1459
|
let task_results = class task_results extends antelope.Struct {
|
|
1583
1460
|
};
|
|
1584
1461
|
tslib.__decorate([
|
|
@@ -1651,30 +1528,6 @@ var Types;
|
|
|
1651
1528
|
antelope.Struct.type('types_row')
|
|
1652
1529
|
], types_row);
|
|
1653
1530
|
Types.types_row = types_row;
|
|
1654
|
-
let updatecredit = class updatecredit extends antelope.Struct {
|
|
1655
|
-
};
|
|
1656
|
-
tslib.__decorate([
|
|
1657
|
-
antelope.Struct.field(antelope.Name)
|
|
1658
|
-
], updatecredit.prototype, "account", void 0);
|
|
1659
|
-
tslib.__decorate([
|
|
1660
|
-
antelope.Struct.field(antelope.Int64)
|
|
1661
|
-
], updatecredit.prototype, "amount", void 0);
|
|
1662
|
-
updatecredit = tslib.__decorate([
|
|
1663
|
-
antelope.Struct.type('updatecredit')
|
|
1664
|
-
], updatecredit);
|
|
1665
|
-
Types.updatecredit = updatecredit;
|
|
1666
|
-
let updatedebt = class updatedebt extends antelope.Struct {
|
|
1667
|
-
};
|
|
1668
|
-
tslib.__decorate([
|
|
1669
|
-
antelope.Struct.field(antelope.Name)
|
|
1670
|
-
], updatedebt.prototype, "account", void 0);
|
|
1671
|
-
tslib.__decorate([
|
|
1672
|
-
antelope.Struct.field(antelope.Int64)
|
|
1673
|
-
], updatedebt.prototype, "amount", void 0);
|
|
1674
|
-
updatedebt = tslib.__decorate([
|
|
1675
|
-
antelope.Struct.type('updatedebt')
|
|
1676
|
-
], updatedebt);
|
|
1677
|
-
Types.updatedebt = updatedebt;
|
|
1678
1531
|
let warehouse_row = class warehouse_row extends antelope.Struct {
|
|
1679
1532
|
};
|
|
1680
1533
|
tslib.__decorate([
|
|
@@ -1746,7 +1599,6 @@ const TableMap = {
|
|
|
1746
1599
|
sequence: Types.sequence_row,
|
|
1747
1600
|
ship: Types.ship_row,
|
|
1748
1601
|
state: Types.state_row,
|
|
1749
|
-
supply: Types.supply_row,
|
|
1750
1602
|
types: Types.types_row,
|
|
1751
1603
|
warehouse: Types.warehouse_row,
|
|
1752
1604
|
};
|
|
@@ -1855,6 +1707,8 @@ exports.TaskType = void 0;
|
|
|
1855
1707
|
TaskType[TaskType["UNLOAD"] = 4] = "UNLOAD";
|
|
1856
1708
|
TaskType[TaskType["EXTRACT"] = 5] = "EXTRACT";
|
|
1857
1709
|
TaskType[TaskType["WARP"] = 6] = "WARP";
|
|
1710
|
+
TaskType[TaskType["CRAFT"] = 7] = "CRAFT";
|
|
1711
|
+
TaskType[TaskType["DEPLOY"] = 8] = "DEPLOY";
|
|
1858
1712
|
})(exports.TaskType || (exports.TaskType = {}));
|
|
1859
1713
|
exports.LocationType = void 0;
|
|
1860
1714
|
(function (LocationType) {
|
|
@@ -1905,9 +1759,6 @@ tslib.__decorate([
|
|
|
1905
1759
|
tslib.__decorate([
|
|
1906
1760
|
antelope.Struct.field('string')
|
|
1907
1761
|
], exports.Item.prototype, "description", void 0);
|
|
1908
|
-
tslib.__decorate([
|
|
1909
|
-
antelope.Struct.field(antelope.UInt32)
|
|
1910
|
-
], exports.Item.prototype, "base_price", void 0);
|
|
1911
1762
|
tslib.__decorate([
|
|
1912
1763
|
antelope.Struct.field(antelope.UInt32)
|
|
1913
1764
|
], exports.Item.prototype, "mass", void 0);
|
|
@@ -1916,30 +1767,13 @@ tslib.__decorate([
|
|
|
1916
1767
|
], exports.Item.prototype, "category", void 0);
|
|
1917
1768
|
tslib.__decorate([
|
|
1918
1769
|
antelope.Struct.field('string')
|
|
1919
|
-
], exports.Item.prototype, "
|
|
1770
|
+
], exports.Item.prototype, "tier", void 0);
|
|
1920
1771
|
tslib.__decorate([
|
|
1921
1772
|
antelope.Struct.field('string')
|
|
1922
1773
|
], exports.Item.prototype, "color", void 0);
|
|
1923
1774
|
exports.Item = tslib.__decorate([
|
|
1924
1775
|
antelope.Struct.type('item')
|
|
1925
1776
|
], exports.Item);
|
|
1926
|
-
exports.ItemPrice = class ItemPrice extends antelope.Struct {
|
|
1927
|
-
};
|
|
1928
|
-
tslib.__decorate([
|
|
1929
|
-
antelope.Struct.field(antelope.UInt16)
|
|
1930
|
-
], exports.ItemPrice.prototype, "id", void 0);
|
|
1931
|
-
tslib.__decorate([
|
|
1932
|
-
antelope.Struct.field(exports.Item)
|
|
1933
|
-
], exports.ItemPrice.prototype, "item", void 0);
|
|
1934
|
-
tslib.__decorate([
|
|
1935
|
-
antelope.Struct.field(antelope.UInt32)
|
|
1936
|
-
], exports.ItemPrice.prototype, "price", void 0);
|
|
1937
|
-
tslib.__decorate([
|
|
1938
|
-
antelope.Struct.field(antelope.UInt16)
|
|
1939
|
-
], exports.ItemPrice.prototype, "supply", void 0);
|
|
1940
|
-
exports.ItemPrice = tslib.__decorate([
|
|
1941
|
-
antelope.Struct.type('ItemPrice')
|
|
1942
|
-
], exports.ItemPrice);
|
|
1943
1777
|
|
|
1944
1778
|
function getCurrentEpoch(game) {
|
|
1945
1779
|
const current = new Date().getTime();
|
|
@@ -1968,89 +1802,231 @@ function hash512(seed, string) {
|
|
|
1968
1802
|
return antelope.Checksum512.hash(bytes);
|
|
1969
1803
|
}
|
|
1970
1804
|
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
1805
|
+
const DEPTH_THRESHOLD_T1 = 0;
|
|
1806
|
+
const DEPTH_THRESHOLD_T2 = 2000;
|
|
1807
|
+
const DEPTH_THRESHOLD_T3 = 10000;
|
|
1808
|
+
const DEPTH_THRESHOLD_T4 = 30000;
|
|
1809
|
+
const DEPTH_THRESHOLD_T5 = 55000;
|
|
1810
|
+
const LOCATION_MIN_DEPTH = 500;
|
|
1811
|
+
const LOCATION_MAX_DEPTH = 65535;
|
|
1812
|
+
const YIELD_THRESHOLD = Math.floor(0.003 * 0xffffffff);
|
|
1813
|
+
const PLANET_SUBTYPE_GAS_GIANT = 0;
|
|
1814
|
+
const PLANET_SUBTYPE_ROCKY = 1;
|
|
1815
|
+
const PLANET_SUBTYPE_TERRESTRIAL = 2;
|
|
1816
|
+
const PLANET_SUBTYPE_ICY = 3;
|
|
1817
|
+
const PLANET_SUBTYPE_OCEAN = 4;
|
|
1818
|
+
const PLANET_SUBTYPE_INDUSTRIAL = 5;
|
|
1819
|
+
const RESOURCE_CATALOG = [
|
|
1820
|
+
{ id: 26, tier: 't1' },
|
|
1821
|
+
{ id: 13, tier: 't2' },
|
|
1822
|
+
{ id: 24, tier: 't3' },
|
|
1823
|
+
{ id: 29, tier: 't1' },
|
|
1824
|
+
{ id: 47, tier: 't2' },
|
|
1825
|
+
{ id: 79, tier: 't3' },
|
|
1826
|
+
{ id: 1, tier: 't1' },
|
|
1827
|
+
{ id: 2, tier: 't2' },
|
|
1828
|
+
{ id: 18, tier: 't3' },
|
|
1829
|
+
{ id: 14, tier: 't1' },
|
|
1830
|
+
{ id: 1000, tier: 't2' },
|
|
1831
|
+
{ id: 1001, tier: 't3' },
|
|
1832
|
+
{ id: 6, tier: 't1' },
|
|
1833
|
+
{ id: 1003, tier: 't2' },
|
|
1834
|
+
{ id: 1002, tier: 't3' },
|
|
1835
|
+
];
|
|
1836
|
+
function getDepthThreshold(tier) {
|
|
1837
|
+
switch (tier) {
|
|
1838
|
+
case 't1':
|
|
1839
|
+
return DEPTH_THRESHOLD_T1;
|
|
1840
|
+
case 't2':
|
|
1841
|
+
return DEPTH_THRESHOLD_T2;
|
|
1842
|
+
case 't3':
|
|
1843
|
+
return DEPTH_THRESHOLD_T3;
|
|
1844
|
+
case 't4':
|
|
1845
|
+
return DEPTH_THRESHOLD_T4;
|
|
1846
|
+
case 't5':
|
|
1847
|
+
return DEPTH_THRESHOLD_T5;
|
|
1848
|
+
}
|
|
1849
|
+
}
|
|
1850
|
+
function getResourceTier(itemId) {
|
|
1851
|
+
const entry = RESOURCE_CATALOG.find((r) => r.id === itemId);
|
|
1852
|
+
return entry ? entry.tier : 't5';
|
|
1853
|
+
}
|
|
1854
|
+
function getResourceWeight(itemId, stratum) {
|
|
1855
|
+
const tier = getResourceTier(itemId);
|
|
1856
|
+
const threshold = getDepthThreshold(tier);
|
|
1857
|
+
if (stratum < threshold)
|
|
1858
|
+
return 0;
|
|
1859
|
+
const depthAbove = stratum - threshold;
|
|
1860
|
+
switch (tier) {
|
|
1861
|
+
case 't1':
|
|
1862
|
+
if (stratum < 2000)
|
|
1863
|
+
return 100;
|
|
1864
|
+
if (stratum < 10000)
|
|
1865
|
+
return 80;
|
|
1866
|
+
if (stratum < 30000)
|
|
1867
|
+
return 50;
|
|
1868
|
+
return 30;
|
|
1869
|
+
case 't2':
|
|
1870
|
+
if (depthAbove < 3000)
|
|
1871
|
+
return 40;
|
|
1872
|
+
if (depthAbove < 8000)
|
|
1873
|
+
return 60;
|
|
1874
|
+
return 50;
|
|
1875
|
+
case 't3':
|
|
1876
|
+
if (depthAbove < 5000)
|
|
1877
|
+
return 20;
|
|
1878
|
+
if (depthAbove < 15000)
|
|
1879
|
+
return 35;
|
|
1880
|
+
return 40;
|
|
1881
|
+
case 't4':
|
|
1882
|
+
if (depthAbove < 10000)
|
|
1883
|
+
return 10;
|
|
1884
|
+
if (depthAbove < 25000)
|
|
1885
|
+
return 20;
|
|
1886
|
+
return 30;
|
|
1887
|
+
case 't5':
|
|
1888
|
+
return 10;
|
|
1889
|
+
}
|
|
1890
|
+
}
|
|
1891
|
+
const ASTEROID_RESOURCES = [26, 13, 24, 29, 47];
|
|
1892
|
+
const NEBULA_RESOURCES = [47, 79, 1, 2, 18];
|
|
1893
|
+
const GAS_GIANT_RESOURCES = [1, 2, 18, 14, 6];
|
|
1894
|
+
const ROCKY_RESOURCES = [26, 13, 24, 14, 1000, 1001, 1002];
|
|
1895
|
+
const TERRESTRIAL_RESOURCES = [29, 47, 14, 1000, 6, 1003, 1002];
|
|
1896
|
+
const ICY_RESOURCES = [26, 1, 2, 14, 1001, 6, 1003];
|
|
1897
|
+
const OCEAN_RESOURCES = [29, 79, 1, 18, 6, 1003, 1002];
|
|
1898
|
+
const INDUSTRIAL_RESOURCES = [26, 13, 24, 29, 79, 1000, 1001];
|
|
1899
|
+
function getLocationCandidates(locationType, subtype) {
|
|
1900
|
+
if (locationType === 2)
|
|
1901
|
+
return ASTEROID_RESOURCES;
|
|
1902
|
+
if (locationType === 3)
|
|
1903
|
+
return NEBULA_RESOURCES;
|
|
1904
|
+
if (locationType === 1) {
|
|
1905
|
+
switch (subtype) {
|
|
1906
|
+
case PLANET_SUBTYPE_GAS_GIANT:
|
|
1907
|
+
return GAS_GIANT_RESOURCES;
|
|
1908
|
+
case PLANET_SUBTYPE_ROCKY:
|
|
1909
|
+
return ROCKY_RESOURCES;
|
|
1910
|
+
case PLANET_SUBTYPE_TERRESTRIAL:
|
|
1911
|
+
return TERRESTRIAL_RESOURCES;
|
|
1912
|
+
case PLANET_SUBTYPE_ICY:
|
|
1913
|
+
return ICY_RESOURCES;
|
|
1914
|
+
case PLANET_SUBTYPE_OCEAN:
|
|
1915
|
+
return OCEAN_RESOURCES;
|
|
1916
|
+
case PLANET_SUBTYPE_INDUSTRIAL:
|
|
1917
|
+
return INDUSTRIAL_RESOURCES;
|
|
1918
|
+
}
|
|
1919
|
+
}
|
|
1920
|
+
return [];
|
|
1921
|
+
}
|
|
1922
|
+
function getEligibleResources(locationType, subtype, stratum) {
|
|
1923
|
+
const candidates = getLocationCandidates(locationType, subtype);
|
|
1924
|
+
return candidates.filter((itemId) => {
|
|
1925
|
+
const tier = getResourceTier(itemId);
|
|
1926
|
+
const threshold = getDepthThreshold(tier);
|
|
1927
|
+
return stratum >= threshold;
|
|
1928
|
+
});
|
|
1929
|
+
}
|
|
1930
|
+
function depthScaleFactor(stratum) {
|
|
1931
|
+
if (stratum <= 1)
|
|
1932
|
+
return 1.0;
|
|
1933
|
+
const logScale = Math.log(stratum) / Math.log(65535);
|
|
1934
|
+
return 1.0 + logScale * 2.0;
|
|
1935
|
+
}
|
|
1936
|
+
|
|
1937
|
+
function deriveLocationSize(loc) {
|
|
1938
|
+
if (loc.type.toNumber() === exports.LocationType.EMPTY)
|
|
1939
|
+
return 0;
|
|
1940
|
+
const raw = (loc.seed0.toNumber() << 8) | loc.seed1.toNumber();
|
|
1941
|
+
const normalized = raw / 65535;
|
|
1942
|
+
const curved = Math.pow(normalized, 3.0);
|
|
1943
|
+
const range = LOCATION_MAX_DEPTH - LOCATION_MIN_DEPTH;
|
|
1944
|
+
return Math.floor(LOCATION_MIN_DEPTH + curved * range);
|
|
1945
|
+
}
|
|
1946
|
+
|
|
1947
|
+
var syllables = [
|
|
1948
|
+
"A",
|
|
1949
|
+
"Ab",
|
|
1950
|
+
"Abl",
|
|
1951
|
+
"Abr",
|
|
1952
|
+
"Ach",
|
|
1953
|
+
"Acr",
|
|
1954
|
+
"Ad",
|
|
1955
|
+
"Ae",
|
|
1956
|
+
"Aed",
|
|
1957
|
+
"Aeg",
|
|
1958
|
+
"Aek",
|
|
1959
|
+
"Ael",
|
|
1960
|
+
"Aem",
|
|
1961
|
+
"Aen",
|
|
1962
|
+
"Aeon",
|
|
1963
|
+
"Aep",
|
|
1964
|
+
"Aer",
|
|
1965
|
+
"Aes",
|
|
1966
|
+
"Aesk",
|
|
1967
|
+
"Aet",
|
|
1968
|
+
"Aev",
|
|
1969
|
+
"Ag",
|
|
1970
|
+
"Agr",
|
|
1971
|
+
"Ahl",
|
|
1972
|
+
"Ai",
|
|
1973
|
+
"Ail",
|
|
1974
|
+
"Ain",
|
|
1975
|
+
"Ais",
|
|
1976
|
+
"Ak",
|
|
1977
|
+
"Aka",
|
|
1978
|
+
"Al",
|
|
1979
|
+
"Alb",
|
|
1980
|
+
"Ald",
|
|
1981
|
+
"Alg",
|
|
1982
|
+
"Alk",
|
|
1983
|
+
"Alm",
|
|
1984
|
+
"Alt",
|
|
1985
|
+
"Alv",
|
|
1986
|
+
"Am",
|
|
1987
|
+
"Amb",
|
|
1988
|
+
"Ami",
|
|
1989
|
+
"Amp",
|
|
1990
|
+
"An",
|
|
1991
|
+
"Anc",
|
|
1992
|
+
"Ang",
|
|
1993
|
+
"Ank",
|
|
1994
|
+
"Ann",
|
|
1995
|
+
"Ant",
|
|
1996
|
+
"Ap",
|
|
1997
|
+
"Aph",
|
|
1998
|
+
"Aqu",
|
|
1999
|
+
"Ar",
|
|
2000
|
+
"Ara",
|
|
2001
|
+
"Arb",
|
|
2002
|
+
"Arc",
|
|
2003
|
+
"Ard",
|
|
2004
|
+
"Arg",
|
|
2005
|
+
"Ari",
|
|
2006
|
+
"Arl",
|
|
2007
|
+
"Arm",
|
|
2008
|
+
"Arn",
|
|
2009
|
+
"Arr",
|
|
2010
|
+
"Ars",
|
|
2011
|
+
"Art",
|
|
2012
|
+
"As",
|
|
2013
|
+
"Asa",
|
|
2014
|
+
"Ash",
|
|
2015
|
+
"Asp",
|
|
2016
|
+
"Ast",
|
|
2017
|
+
"Astr",
|
|
2018
|
+
"At",
|
|
2019
|
+
"Ath",
|
|
2020
|
+
"Atr",
|
|
2021
|
+
"Aud",
|
|
2022
|
+
"Aug",
|
|
2023
|
+
"Aul",
|
|
2024
|
+
"Aum",
|
|
2025
|
+
"Aun",
|
|
2026
|
+
"Aur",
|
|
2027
|
+
"Aus",
|
|
2028
|
+
"Av",
|
|
2029
|
+
"Avn",
|
|
2054
2030
|
"Ax",
|
|
2055
2031
|
"Ayn",
|
|
2056
2032
|
"Az",
|
|
@@ -4214,9 +4190,7 @@ function deriveLocationStatic(gameSeed, coordinates) {
|
|
|
4214
4190
|
else {
|
|
4215
4191
|
loc.type = antelope.UInt8.from(exports.LocationType.NEBULA);
|
|
4216
4192
|
}
|
|
4217
|
-
loc.subtype = antelope.UInt8.from(Number(loc.type) === exports.LocationType.PLANET
|
|
4218
|
-
? hashResult.array[2] % 6
|
|
4219
|
-
: hashResult.array[2]);
|
|
4193
|
+
loc.subtype = antelope.UInt8.from(Number(loc.type) === exports.LocationType.PLANET ? hashResult.array[2] % 6 : hashResult.array[2]);
|
|
4220
4194
|
loc.seed0 = antelope.UInt8.from(hashResult.array[3]);
|
|
4221
4195
|
loc.seed1 = antelope.UInt8.from(hashResult.array[4]);
|
|
4222
4196
|
return loc;
|
|
@@ -4233,9 +4207,11 @@ function deriveLocationEpoch(epochSeed, coordinates) {
|
|
|
4233
4207
|
});
|
|
4234
4208
|
}
|
|
4235
4209
|
function deriveLocation(gameSeed, epochSeed, coordinates) {
|
|
4210
|
+
const staticProps = deriveLocationStatic(gameSeed, coordinates);
|
|
4236
4211
|
return Types.location_derived.from({
|
|
4237
|
-
static_props:
|
|
4212
|
+
static_props: staticProps,
|
|
4238
4213
|
epoch_props: deriveLocationEpoch(epochSeed, coordinates),
|
|
4214
|
+
size: deriveLocationSize(staticProps),
|
|
4239
4215
|
});
|
|
4240
4216
|
}
|
|
4241
4217
|
|
|
@@ -4333,145 +4309,140 @@ class BaseManager {
|
|
|
4333
4309
|
}
|
|
4334
4310
|
|
|
4335
4311
|
var itemsData = [
|
|
4312
|
+
{
|
|
4313
|
+
id: 26,
|
|
4314
|
+
name: "Iron",
|
|
4315
|
+
description: "A versatile metal used in hulls and structures.",
|
|
4316
|
+
mass: 40000,
|
|
4317
|
+
category: "metal",
|
|
4318
|
+
tier: "t1",
|
|
4319
|
+
color: "#B7410E"
|
|
4320
|
+
},
|
|
4321
|
+
{
|
|
4322
|
+
id: 13,
|
|
4323
|
+
name: "Aluminum",
|
|
4324
|
+
description: "A lightweight metal for structural components.",
|
|
4325
|
+
mass: 27000,
|
|
4326
|
+
category: "metal",
|
|
4327
|
+
tier: "t2",
|
|
4328
|
+
color: "#A8B5C2"
|
|
4329
|
+
},
|
|
4330
|
+
{
|
|
4331
|
+
id: 24,
|
|
4332
|
+
name: "Chromium",
|
|
4333
|
+
description: "A hard, corrosion-resistant alloy metal.",
|
|
4334
|
+
mass: 52000,
|
|
4335
|
+
category: "metal",
|
|
4336
|
+
tier: "t3",
|
|
4337
|
+
color: "#D4E6F1"
|
|
4338
|
+
},
|
|
4339
|
+
{
|
|
4340
|
+
id: 29,
|
|
4341
|
+
name: "Copper",
|
|
4342
|
+
description: "A conductive metal for electronics and wiring.",
|
|
4343
|
+
mass: 60000,
|
|
4344
|
+
category: "precious",
|
|
4345
|
+
tier: "t1",
|
|
4346
|
+
color: "#B87333"
|
|
4347
|
+
},
|
|
4348
|
+
{
|
|
4349
|
+
id: 47,
|
|
4350
|
+
name: "Silver",
|
|
4351
|
+
description: "A high-conductivity metal for precision components.",
|
|
4352
|
+
mass: 55000,
|
|
4353
|
+
category: "precious",
|
|
4354
|
+
tier: "t2",
|
|
4355
|
+
color: "#C0C0C0"
|
|
4356
|
+
},
|
|
4357
|
+
{
|
|
4358
|
+
id: 79,
|
|
4359
|
+
name: "Gold",
|
|
4360
|
+
description: "A corrosion-proof metal for advanced electronics.",
|
|
4361
|
+
mass: 70000,
|
|
4362
|
+
category: "precious",
|
|
4363
|
+
tier: "t3",
|
|
4364
|
+
color: "#FFD700"
|
|
4365
|
+
},
|
|
4336
4366
|
{
|
|
4337
4367
|
id: 1,
|
|
4338
4368
|
name: "Hydrogen",
|
|
4339
4369
|
description: "A lightweight gas used for fuel cells and propulsion.",
|
|
4340
|
-
base_price: 50,
|
|
4341
4370
|
mass: 15000,
|
|
4342
4371
|
category: "gas",
|
|
4343
|
-
|
|
4372
|
+
tier: "t1",
|
|
4344
4373
|
color: "#7EC8E3"
|
|
4345
4374
|
},
|
|
4346
4375
|
{
|
|
4347
4376
|
id: 2,
|
|
4348
4377
|
name: "Helium",
|
|
4349
4378
|
description: "An inert noble gas used in energy systems.",
|
|
4350
|
-
base_price: 75,
|
|
4351
4379
|
mass: 2000,
|
|
4352
4380
|
category: "gas",
|
|
4353
|
-
|
|
4381
|
+
tier: "t2",
|
|
4354
4382
|
color: "#F5E6CC"
|
|
4355
4383
|
},
|
|
4356
|
-
{
|
|
4357
|
-
id: 6,
|
|
4358
|
-
name: "Carbon",
|
|
4359
|
-
description: "A versatile element for life support and coatings.",
|
|
4360
|
-
base_price: 100,
|
|
4361
|
-
mass: 12000,
|
|
4362
|
-
category: "organic",
|
|
4363
|
-
rarity: "common",
|
|
4364
|
-
color: "#4A4A4A"
|
|
4365
|
-
},
|
|
4366
|
-
{
|
|
4367
|
-
id: 14,
|
|
4368
|
-
name: "Silicon",
|
|
4369
|
-
description: "A semiconductor used in sensors and computing.",
|
|
4370
|
-
base_price: 150,
|
|
4371
|
-
mass: 28000,
|
|
4372
|
-
category: "mineral",
|
|
4373
|
-
rarity: "common",
|
|
4374
|
-
color: "#B8A9C9"
|
|
4375
|
-
},
|
|
4376
4384
|
{
|
|
4377
4385
|
id: 18,
|
|
4378
4386
|
name: "Argon",
|
|
4379
4387
|
description: "A noble gas used in industrial and energy applications.",
|
|
4380
|
-
base_price: 60,
|
|
4381
4388
|
mass: 8000,
|
|
4382
4389
|
category: "gas",
|
|
4383
|
-
|
|
4390
|
+
tier: "t3",
|
|
4384
4391
|
color: "#9B59B6"
|
|
4385
4392
|
},
|
|
4386
4393
|
{
|
|
4387
|
-
id:
|
|
4388
|
-
name: "
|
|
4389
|
-
description: "A
|
|
4390
|
-
|
|
4391
|
-
|
|
4392
|
-
|
|
4393
|
-
|
|
4394
|
-
color: "#C0C0C0"
|
|
4395
|
-
},
|
|
4396
|
-
{
|
|
4397
|
-
id: 26,
|
|
4398
|
-
name: "Iron",
|
|
4399
|
-
description: "A versatile metal used in hulls and structures.",
|
|
4400
|
-
base_price: 125,
|
|
4401
|
-
mass: 40000,
|
|
4402
|
-
category: "metal",
|
|
4403
|
-
rarity: "common",
|
|
4404
|
-
color: "#B7410E"
|
|
4405
|
-
},
|
|
4406
|
-
{
|
|
4407
|
-
id: 29,
|
|
4408
|
-
name: "Copper",
|
|
4409
|
-
description: "A conductive metal for electronics and wiring.",
|
|
4410
|
-
base_price: 200,
|
|
4411
|
-
mass: 60000,
|
|
4412
|
-
category: "metal",
|
|
4413
|
-
rarity: "uncommon",
|
|
4414
|
-
color: "#B87333"
|
|
4415
|
-
},
|
|
4416
|
-
{
|
|
4417
|
-
id: 54,
|
|
4418
|
-
name: "Xenon",
|
|
4419
|
-
description: "A rare noble gas for advanced propulsion systems.",
|
|
4420
|
-
base_price: 175,
|
|
4421
|
-
mass: 20000,
|
|
4422
|
-
category: "gas",
|
|
4423
|
-
rarity: "epic",
|
|
4424
|
-
color: "#5B2C6F"
|
|
4425
|
-
},
|
|
4426
|
-
{
|
|
4427
|
-
id: 74,
|
|
4428
|
-
name: "Tungsten",
|
|
4429
|
-
description: "An extremely dense metal for heavy-duty applications.",
|
|
4430
|
-
base_price: 500,
|
|
4431
|
-
mass: 80000,
|
|
4432
|
-
category: "metal",
|
|
4433
|
-
rarity: "epic",
|
|
4434
|
-
color: "#708090"
|
|
4394
|
+
id: 14,
|
|
4395
|
+
name: "Silicon",
|
|
4396
|
+
description: "A semiconductor used in sensors and computing.",
|
|
4397
|
+
mass: 28000,
|
|
4398
|
+
category: "mineral",
|
|
4399
|
+
tier: "t1",
|
|
4400
|
+
color: "#B8A9C9"
|
|
4435
4401
|
},
|
|
4436
4402
|
{
|
|
4437
4403
|
id: 1000,
|
|
4438
4404
|
name: "Quartz",
|
|
4439
4405
|
description: "A crystalline mineral for sensors and optics.",
|
|
4440
|
-
base_price: 200,
|
|
4441
4406
|
mass: 35000,
|
|
4442
4407
|
category: "mineral",
|
|
4443
|
-
|
|
4408
|
+
tier: "t2",
|
|
4444
4409
|
color: "#E8D5B7"
|
|
4445
4410
|
},
|
|
4446
4411
|
{
|
|
4447
4412
|
id: 1001,
|
|
4448
4413
|
name: "Sapphire",
|
|
4449
4414
|
description: "A precious crystal for precision instruments.",
|
|
4450
|
-
base_price: 400,
|
|
4451
4415
|
mass: 45000,
|
|
4452
4416
|
category: "mineral",
|
|
4453
|
-
|
|
4417
|
+
tier: "t3",
|
|
4454
4418
|
color: "#0F52BA"
|
|
4455
4419
|
},
|
|
4456
4420
|
{
|
|
4457
|
-
id:
|
|
4458
|
-
name: "
|
|
4459
|
-
description: "
|
|
4460
|
-
|
|
4461
|
-
mass: 25000,
|
|
4421
|
+
id: 6,
|
|
4422
|
+
name: "Carbon",
|
|
4423
|
+
description: "A versatile element for life support and coatings.",
|
|
4424
|
+
mass: 12000,
|
|
4462
4425
|
category: "organic",
|
|
4463
|
-
|
|
4464
|
-
color: "#
|
|
4426
|
+
tier: "t1",
|
|
4427
|
+
color: "#4A4A4A"
|
|
4465
4428
|
},
|
|
4466
4429
|
{
|
|
4467
4430
|
id: 1003,
|
|
4468
4431
|
name: "Biomass",
|
|
4469
4432
|
description: "Organic matter for life support systems.",
|
|
4470
|
-
base_price: 100,
|
|
4471
4433
|
mass: 30000,
|
|
4472
4434
|
category: "organic",
|
|
4473
|
-
|
|
4435
|
+
tier: "t2",
|
|
4474
4436
|
color: "#8B4513"
|
|
4437
|
+
},
|
|
4438
|
+
{
|
|
4439
|
+
id: 1002,
|
|
4440
|
+
name: "Resin",
|
|
4441
|
+
description: "A fossilized organic compound for coatings and sealants.",
|
|
4442
|
+
mass: 25000,
|
|
4443
|
+
category: "organic",
|
|
4444
|
+
tier: "t3",
|
|
4445
|
+
color: "#DAA520"
|
|
4475
4446
|
}
|
|
4476
4447
|
];
|
|
4477
4448
|
|
|
@@ -4479,10 +4450,9 @@ const items = itemsData.map((g) => exports.Item.from({
|
|
|
4479
4450
|
id: g.id,
|
|
4480
4451
|
name: g.name,
|
|
4481
4452
|
description: g.description,
|
|
4482
|
-
base_price: g.base_price,
|
|
4483
4453
|
mass: g.mass,
|
|
4484
4454
|
category: g.category,
|
|
4485
|
-
|
|
4455
|
+
tier: g.tier,
|
|
4486
4456
|
color: g.color,
|
|
4487
4457
|
}));
|
|
4488
4458
|
const itemIds = items.map((i) => i.id);
|
|
@@ -4790,9 +4760,6 @@ function capsHasStorage(caps) {
|
|
|
4790
4760
|
function capsHasLoaders(caps) {
|
|
4791
4761
|
return caps.loaders !== undefined;
|
|
4792
4762
|
}
|
|
4793
|
-
function capsHasTrade(caps) {
|
|
4794
|
-
return caps.trade !== undefined;
|
|
4795
|
-
}
|
|
4796
4763
|
function capsHasExtractor(caps) {
|
|
4797
4764
|
return caps.extractor !== undefined;
|
|
4798
4765
|
}
|
|
@@ -4808,13 +4775,6 @@ function calcCargoMass(entity) {
|
|
|
4808
4775
|
}
|
|
4809
4776
|
return mass;
|
|
4810
4777
|
}
|
|
4811
|
-
function calcCargoValue(entity) {
|
|
4812
|
-
let value = antelope.UInt64.from(0);
|
|
4813
|
-
for (const item of entity.cargo) {
|
|
4814
|
-
value = value.adding(item.unit_cost.multiplying(item.quantity));
|
|
4815
|
-
}
|
|
4816
|
-
return value;
|
|
4817
|
-
}
|
|
4818
4778
|
function availableCapacity$1(entity) {
|
|
4819
4779
|
const cargoMass = calcCargoMass(entity);
|
|
4820
4780
|
return entity.capacity.gt(cargoMass)
|
|
@@ -5011,7 +4971,6 @@ function createProjectedEntity(entity) {
|
|
|
5011
4971
|
const loaders = entity.loaders;
|
|
5012
4972
|
const engines = entity.engines;
|
|
5013
4973
|
const generator = entity.generator;
|
|
5014
|
-
const trade = entity.trade;
|
|
5015
4974
|
const capacity = entity.capacity;
|
|
5016
4975
|
const projected = {
|
|
5017
4976
|
location: Coordinates.from(entity.coordinates),
|
|
@@ -5022,7 +4981,6 @@ function createProjectedEntity(entity) {
|
|
|
5022
4981
|
engines,
|
|
5023
4982
|
generator,
|
|
5024
4983
|
loaders,
|
|
5025
|
-
trade,
|
|
5026
4984
|
get totalMass() {
|
|
5027
4985
|
let mass = antelope.UInt64.from(this.shipMass).adding(this.cargoMass);
|
|
5028
4986
|
if (this.loaders) {
|
|
@@ -5039,9 +4997,6 @@ function createProjectedEntity(entity) {
|
|
|
5039
4997
|
hasLoaders() {
|
|
5040
4998
|
return capsHasLoaders(this.capabilities());
|
|
5041
4999
|
},
|
|
5042
|
-
hasTrade() {
|
|
5043
|
-
return this.trade !== undefined;
|
|
5044
|
-
},
|
|
5045
5000
|
capabilities() {
|
|
5046
5001
|
return {
|
|
5047
5002
|
hullmass: this.shipMass,
|
|
@@ -5049,7 +5004,6 @@ function createProjectedEntity(entity) {
|
|
|
5049
5004
|
engines: this.engines,
|
|
5050
5005
|
generator: this.generator,
|
|
5051
5006
|
loaders: this.loaders,
|
|
5052
|
-
trade: this.trade,
|
|
5053
5007
|
};
|
|
5054
5008
|
},
|
|
5055
5009
|
state() {
|
|
@@ -5224,17 +5178,6 @@ class Location {
|
|
|
5224
5178
|
isExtractableAt(gameSeed) {
|
|
5225
5179
|
return isExtractableLocation(this.getLocationTypeAt(gameSeed));
|
|
5226
5180
|
}
|
|
5227
|
-
setMarketPrices(prices) {
|
|
5228
|
-
this._marketPrices = prices;
|
|
5229
|
-
}
|
|
5230
|
-
get marketPrices() {
|
|
5231
|
-
return this._marketPrices;
|
|
5232
|
-
}
|
|
5233
|
-
getPrice(goodId) {
|
|
5234
|
-
if (!this._marketPrices)
|
|
5235
|
-
return undefined;
|
|
5236
|
-
return this._marketPrices.find((p) => p.id.equals(goodId));
|
|
5237
|
-
}
|
|
5238
5181
|
findNearby(gameSeed, maxDistance = 20) {
|
|
5239
5182
|
return findNearbyPlanets(antelope.Checksum256.from(gameSeed), this.coordinates, maxDistance);
|
|
5240
5183
|
}
|
|
@@ -5242,90 +5185,12 @@ class Location {
|
|
|
5242
5185
|
const otherCoords = other instanceof Location ? other.coordinates : Coordinates.from(other);
|
|
5243
5186
|
return this.coordinates.equals(otherCoords);
|
|
5244
5187
|
}
|
|
5245
|
-
setLocationRows(rows, epoch) {
|
|
5246
|
-
this._locationRows = rows;
|
|
5247
|
-
this._epoch = epoch;
|
|
5248
|
-
}
|
|
5249
|
-
get locationRows() {
|
|
5250
|
-
return this._locationRows;
|
|
5251
|
-
}
|
|
5252
|
-
getSupply(goodId) {
|
|
5253
|
-
if (!this._locationRows)
|
|
5254
|
-
return undefined;
|
|
5255
|
-
const row = this._locationRows.find((r) => r.item_id.equals(goodId) && this._epoch && r.epoch.equals(this._epoch));
|
|
5256
|
-
return row ? row.supply : undefined;
|
|
5257
|
-
}
|
|
5258
|
-
get availableGoods() {
|
|
5259
|
-
if (!this._locationRows)
|
|
5260
|
-
return undefined;
|
|
5261
|
-
return this._locationRows.filter((r) => this._epoch && r.epoch.equals(this._epoch) && r.supply.gt(antelope.UInt16.from(0)));
|
|
5262
|
-
}
|
|
5263
|
-
hasGood(goodId) {
|
|
5264
|
-
const supply = this.getSupply(goodId);
|
|
5265
|
-
return supply !== undefined && supply.gt(antelope.UInt16.from(0));
|
|
5266
|
-
}
|
|
5267
5188
|
get epoch() {
|
|
5268
5189
|
return this._epoch;
|
|
5269
5190
|
}
|
|
5270
|
-
get hasCachedData() {
|
|
5271
|
-
return this._marketPrices !== undefined || this._locationRows !== undefined;
|
|
5272
|
-
}
|
|
5273
|
-
get hasSupplyData() {
|
|
5274
|
-
return this._locationRows !== undefined;
|
|
5275
|
-
}
|
|
5276
5191
|
clearCache() {
|
|
5277
|
-
this._marketPrices = undefined;
|
|
5278
|
-
this._locationRows = undefined;
|
|
5279
5192
|
this._epoch = undefined;
|
|
5280
5193
|
}
|
|
5281
|
-
withUpdatedSupply(goodId, quantityDelta) {
|
|
5282
|
-
const newLocation = Location.from(this.coordinates);
|
|
5283
|
-
if (this._marketPrices) {
|
|
5284
|
-
newLocation._marketPrices = this._marketPrices.map((price) => {
|
|
5285
|
-
if (price.id.equals(goodId)) {
|
|
5286
|
-
const currentSupply = antelope.UInt16.from(price.supply);
|
|
5287
|
-
const delta = antelope.UInt16.from(Math.abs(quantityDelta));
|
|
5288
|
-
const newSupply = quantityDelta < 0
|
|
5289
|
-
? currentSupply.gte(delta)
|
|
5290
|
-
? currentSupply.subtracting(delta)
|
|
5291
|
-
: antelope.UInt16.from(0)
|
|
5292
|
-
: currentSupply.adding(quantityDelta);
|
|
5293
|
-
return exports.ItemPrice.from({
|
|
5294
|
-
id: price.id,
|
|
5295
|
-
item: price.item,
|
|
5296
|
-
price: price.price,
|
|
5297
|
-
supply: newSupply,
|
|
5298
|
-
});
|
|
5299
|
-
}
|
|
5300
|
-
return price;
|
|
5301
|
-
});
|
|
5302
|
-
}
|
|
5303
|
-
if (this._locationRows && this._epoch) {
|
|
5304
|
-
newLocation._locationRows = this._locationRows.map((row) => {
|
|
5305
|
-
if (row.item_id.equals(goodId) && row.epoch.equals(this._epoch)) {
|
|
5306
|
-
const currentSupply = antelope.UInt16.from(row.supply);
|
|
5307
|
-
const delta = antelope.UInt16.from(Math.abs(quantityDelta));
|
|
5308
|
-
const newSupply = quantityDelta < 0
|
|
5309
|
-
? currentSupply.gte(delta)
|
|
5310
|
-
? currentSupply.subtracting(delta)
|
|
5311
|
-
: antelope.UInt16.from(0)
|
|
5312
|
-
: currentSupply.adding(quantityDelta);
|
|
5313
|
-
return Types.supply_row.from({
|
|
5314
|
-
id: row.id,
|
|
5315
|
-
coordinates: row.coordinates,
|
|
5316
|
-
epoch: row.epoch,
|
|
5317
|
-
item_id: row.item_id,
|
|
5318
|
-
supply: newSupply,
|
|
5319
|
-
});
|
|
5320
|
-
}
|
|
5321
|
-
return row;
|
|
5322
|
-
});
|
|
5323
|
-
newLocation._epoch = this._epoch;
|
|
5324
|
-
}
|
|
5325
|
-
newLocation._gameSeed = this._gameSeed;
|
|
5326
|
-
newLocation._hasSystem = this._hasSystem;
|
|
5327
|
-
return newLocation;
|
|
5328
|
-
}
|
|
5329
5194
|
}
|
|
5330
5195
|
function toLocation(coords) {
|
|
5331
5196
|
if (coords instanceof Location) {
|
|
@@ -5413,9 +5278,6 @@ class EntityInventory extends Types.cargo_item {
|
|
|
5413
5278
|
get totalMass() {
|
|
5414
5279
|
return antelope.UInt64.from(this.unitMass).multiplying(this.quantity);
|
|
5415
5280
|
}
|
|
5416
|
-
get totalCost() {
|
|
5417
|
-
return this.unit_cost.multiplying(this.quantity);
|
|
5418
|
-
}
|
|
5419
5281
|
get hasCargo() {
|
|
5420
5282
|
return antelope.UInt32.from(this.quantity).gt(antelope.UInt32.from(0));
|
|
5421
5283
|
}
|
|
@@ -5437,9 +5299,6 @@ class InventoryAccessor {
|
|
|
5437
5299
|
get totalMass() {
|
|
5438
5300
|
return this.items.reduce((sum, c) => sum.adding(c.totalMass), antelope.UInt64.from(0));
|
|
5439
5301
|
}
|
|
5440
|
-
get totalValue() {
|
|
5441
|
-
return this.items.reduce((sum, c) => sum.adding(c.totalCost), antelope.UInt64.from(0));
|
|
5442
|
-
}
|
|
5443
5302
|
forItem(goodId) {
|
|
5444
5303
|
return this.items.find((c) => c.item_id.equals(goodId));
|
|
5445
5304
|
}
|
|
@@ -5476,106 +5335,6 @@ function needsRecharge(entity) {
|
|
|
5476
5335
|
return antelope.UInt64.from(entity.energy).lt(entity.generator.capacity);
|
|
5477
5336
|
}
|
|
5478
5337
|
|
|
5479
|
-
function totalCargoMass(cargo) {
|
|
5480
|
-
return cargo.reduce((sum, c) => {
|
|
5481
|
-
return sum.adding(c.totalMass);
|
|
5482
|
-
}, antelope.UInt64.from(0));
|
|
5483
|
-
}
|
|
5484
|
-
function cargoValue(cargo) {
|
|
5485
|
-
return cargo.reduce((sum, c) => {
|
|
5486
|
-
return sum.adding(c.totalCost);
|
|
5487
|
-
}, antelope.UInt64.from(0));
|
|
5488
|
-
}
|
|
5489
|
-
function getCargoForItem(cargo, goodId) {
|
|
5490
|
-
return cargo.find((c) => c.item_id.equals(goodId));
|
|
5491
|
-
}
|
|
5492
|
-
function hasSpace(currentMass, maxCapacity, goodMass, quantity) {
|
|
5493
|
-
const additionalMass = goodMass.multiplying(quantity);
|
|
5494
|
-
const totalMass = currentMass.adding(additionalMass);
|
|
5495
|
-
return totalMass.lte(maxCapacity);
|
|
5496
|
-
}
|
|
5497
|
-
function availableCapacity(currentMass, maxCapacity) {
|
|
5498
|
-
if (currentMass.gte(maxCapacity)) {
|
|
5499
|
-
return antelope.UInt64.from(0);
|
|
5500
|
-
}
|
|
5501
|
-
return maxCapacity.subtracting(currentMass);
|
|
5502
|
-
}
|
|
5503
|
-
function isFull(currentMass, maxCapacity) {
|
|
5504
|
-
return currentMass.gte(maxCapacity);
|
|
5505
|
-
}
|
|
5506
|
-
function calculateSaleValue(cargo, prices) {
|
|
5507
|
-
if (cargo.length === 0) {
|
|
5508
|
-
return { revenue: antelope.UInt64.from(0), profit: antelope.UInt64.from(0), cost: antelope.UInt64.from(0) };
|
|
5509
|
-
}
|
|
5510
|
-
let revenue = antelope.UInt64.from(0);
|
|
5511
|
-
let cost = antelope.UInt64.from(0);
|
|
5512
|
-
for (const item of cargo) {
|
|
5513
|
-
if (antelope.UInt32.from(item.quantity).equals(antelope.UInt32.from(0)))
|
|
5514
|
-
continue;
|
|
5515
|
-
const goodId = Number(item.item_id);
|
|
5516
|
-
const salePrice = prices.get(goodId);
|
|
5517
|
-
if (salePrice) {
|
|
5518
|
-
revenue = revenue.adding(salePrice.multiplying(item.quantity));
|
|
5519
|
-
}
|
|
5520
|
-
cost = cost.adding(item.unit_cost.multiplying(item.quantity));
|
|
5521
|
-
}
|
|
5522
|
-
const profit = revenue.gte(cost) ? revenue.subtracting(cost) : antelope.UInt64.from(0);
|
|
5523
|
-
return {
|
|
5524
|
-
revenue,
|
|
5525
|
-
profit,
|
|
5526
|
-
cost,
|
|
5527
|
-
};
|
|
5528
|
-
}
|
|
5529
|
-
function calculateSaleValueFromArray(cargo, prices) {
|
|
5530
|
-
const priceMap = new Map();
|
|
5531
|
-
prices.forEach((price, index) => {
|
|
5532
|
-
priceMap.set(index, price);
|
|
5533
|
-
});
|
|
5534
|
-
return calculateSaleValue(cargo, priceMap);
|
|
5535
|
-
}
|
|
5536
|
-
function afterSellItems(cargo, goodsToSell) {
|
|
5537
|
-
if (cargo.length === 0) {
|
|
5538
|
-
return [];
|
|
5539
|
-
}
|
|
5540
|
-
return cargo.map((item) => {
|
|
5541
|
-
const saleItem = goodsToSell.find((s) => Number(item.item_id) === s.goodId);
|
|
5542
|
-
if (!saleItem) {
|
|
5543
|
-
return new EntityInventory(item);
|
|
5544
|
-
}
|
|
5545
|
-
const currentQty = Number(item.quantity);
|
|
5546
|
-
const newQty = Math.max(0, currentQty - saleItem.quantity);
|
|
5547
|
-
return new EntityInventory(Types.cargo_item.from({
|
|
5548
|
-
item_id: item.item_id,
|
|
5549
|
-
quantity: antelope.UInt32.from(newQty),
|
|
5550
|
-
unit_cost: item.unit_cost,
|
|
5551
|
-
}));
|
|
5552
|
-
});
|
|
5553
|
-
}
|
|
5554
|
-
function afterSellAllItems(cargo) {
|
|
5555
|
-
if (cargo.length === 0) {
|
|
5556
|
-
return [];
|
|
5557
|
-
}
|
|
5558
|
-
return cargo.map((item) => new EntityInventory(Types.cargo_item.from({
|
|
5559
|
-
item_id: item.item_id,
|
|
5560
|
-
quantity: antelope.UInt32.from(0),
|
|
5561
|
-
unit_cost: item.unit_cost,
|
|
5562
|
-
})));
|
|
5563
|
-
}
|
|
5564
|
-
|
|
5565
|
-
var cargoUtils = /*#__PURE__*/Object.freeze({
|
|
5566
|
-
__proto__: null,
|
|
5567
|
-
totalCargoMass: totalCargoMass,
|
|
5568
|
-
cargoValue: cargoValue,
|
|
5569
|
-
getCargoForItem: getCargoForItem,
|
|
5570
|
-
hasSpace: hasSpace,
|
|
5571
|
-
availableCapacity: availableCapacity,
|
|
5572
|
-
isFull: isFull,
|
|
5573
|
-
calculateSaleValue: calculateSaleValue,
|
|
5574
|
-
calculateSaleValueFromArray: calculateSaleValueFromArray,
|
|
5575
|
-
afterSellItems: afterSellItems,
|
|
5576
|
-
afterSellAllItems: afterSellAllItems
|
|
5577
|
-
});
|
|
5578
|
-
|
|
5579
5338
|
class Ship extends Types.entity_info {
|
|
5580
5339
|
get name() {
|
|
5581
5340
|
return this.entity_name;
|
|
@@ -5642,9 +5401,6 @@ class Ship extends Types.entity_info {
|
|
|
5642
5401
|
get totalCargoMass() {
|
|
5643
5402
|
return this.inv.totalMass;
|
|
5644
5403
|
}
|
|
5645
|
-
get cargoValue() {
|
|
5646
|
-
return this.inv.totalValue;
|
|
5647
|
-
}
|
|
5648
5404
|
get totalMass() {
|
|
5649
5405
|
let mass = antelope.UInt64.from(this.hullmass ?? 0).adding(this.totalCargoMass);
|
|
5650
5406
|
if (this.loaders) {
|
|
@@ -5693,18 +5449,6 @@ class Ship extends Types.entity_info {
|
|
|
5693
5449
|
return false;
|
|
5694
5450
|
return hasEnergyForDistance(this, distance);
|
|
5695
5451
|
}
|
|
5696
|
-
calculateSaleValue(prices) {
|
|
5697
|
-
return calculateSaleValue(this.cargo, prices);
|
|
5698
|
-
}
|
|
5699
|
-
calculateSaleValueFromArray(prices) {
|
|
5700
|
-
return calculateSaleValueFromArray(this.cargo, prices);
|
|
5701
|
-
}
|
|
5702
|
-
afterSellItems(goodsToSell) {
|
|
5703
|
-
return afterSellItems(this.cargo, goodsToSell);
|
|
5704
|
-
}
|
|
5705
|
-
afterSellAllItems() {
|
|
5706
|
-
return afterSellAllItems(this.cargo);
|
|
5707
|
-
}
|
|
5708
5452
|
}
|
|
5709
5453
|
|
|
5710
5454
|
class Warehouse extends Types.entity_info {
|
|
@@ -5735,9 +5479,6 @@ class Warehouse extends Types.entity_info {
|
|
|
5735
5479
|
get totalCargoMass() {
|
|
5736
5480
|
return this.inv.totalMass;
|
|
5737
5481
|
}
|
|
5738
|
-
get cargoValue() {
|
|
5739
|
-
return this.inv.totalValue;
|
|
5740
|
-
}
|
|
5741
5482
|
get maxCapacity() {
|
|
5742
5483
|
return antelope.UInt64.from(this.capacity);
|
|
5743
5484
|
}
|
|
@@ -5798,6 +5539,17 @@ class Container extends Types.entity_info {
|
|
|
5798
5539
|
return this.coordinates.z?.toNumber() || 0;
|
|
5799
5540
|
}
|
|
5800
5541
|
}
|
|
5542
|
+
function computeContainerCapabilities(stats) {
|
|
5543
|
+
const density = stats['density'] ?? 500;
|
|
5544
|
+
const strength = stats['strength'] ?? 500;
|
|
5545
|
+
const ductility = stats['ductility'] ?? 500;
|
|
5546
|
+
const purity = stats['purity'] ?? 500;
|
|
5547
|
+
const hullmass = 25000 + 75 * density;
|
|
5548
|
+
const statSum = strength + ductility + purity;
|
|
5549
|
+
const exponent = statSum / 2997;
|
|
5550
|
+
const capacity = Math.floor(1000000 * Math.pow(10, exponent));
|
|
5551
|
+
return { hullmass, capacity };
|
|
5552
|
+
}
|
|
5801
5553
|
|
|
5802
5554
|
class EntitiesManager extends BaseManager {
|
|
5803
5555
|
async getEntity(type, id) {
|
|
@@ -5875,134 +5627,10 @@ class Player extends Types.player_row {
|
|
|
5875
5627
|
static fromState(state) {
|
|
5876
5628
|
const playerRow = Types.player_row.from({
|
|
5877
5629
|
owner: antelope.Name.from(state.owner),
|
|
5878
|
-
balance: antelope.UInt64.from(state.balance),
|
|
5879
|
-
debt: antelope.UInt32.from(state.debt),
|
|
5880
|
-
networth: antelope.Int64.from(state.networth),
|
|
5881
5630
|
});
|
|
5882
5631
|
return new Player(playerRow);
|
|
5883
5632
|
}
|
|
5884
|
-
setShipCount(count) {
|
|
5885
|
-
this._shipCount = count;
|
|
5886
|
-
}
|
|
5887
|
-
get shipCount() {
|
|
5888
|
-
return this._shipCount;
|
|
5889
|
-
}
|
|
5890
|
-
getNextShipCost(shipCount) {
|
|
5891
|
-
const count = shipCount ?? this._shipCount ?? 0;
|
|
5892
|
-
const cost = Math.pow(Player.SHIP_COST_MULTIPLIER, count) * Player.BASE_SHIP_COST;
|
|
5893
|
-
return antelope.UInt64.from(Math.floor(cost));
|
|
5894
|
-
}
|
|
5895
|
-
get nextShipCost() {
|
|
5896
|
-
return this.getNextShipCost();
|
|
5897
|
-
}
|
|
5898
|
-
canBuyShip(shipCount) {
|
|
5899
|
-
return antelope.UInt64.from(this.balance).gte(this.getNextShipCost(shipCount));
|
|
5900
|
-
}
|
|
5901
|
-
get availableLoan() {
|
|
5902
|
-
const maxLoan = antelope.UInt64.from(Player.MAX_LOAN);
|
|
5903
|
-
if (antelope.UInt64.from(this.debt).gte(maxLoan)) {
|
|
5904
|
-
return antelope.UInt64.from(0);
|
|
5905
|
-
}
|
|
5906
|
-
return maxLoan.subtracting(this.debt);
|
|
5907
|
-
}
|
|
5908
|
-
get canTakeLoan() {
|
|
5909
|
-
return this.availableLoan.gt(antelope.UInt64.zero);
|
|
5910
|
-
}
|
|
5911
|
-
get canPayLoan() {
|
|
5912
|
-
return antelope.UInt64.from(this.debt).gt(antelope.UInt64.zero) && antelope.UInt64.from(this.balance).gt(antelope.UInt64.zero);
|
|
5913
|
-
}
|
|
5914
|
-
get maxPayback() {
|
|
5915
|
-
return antelope.UInt64.from(this.debt).lt(this.balance) ? this.debt : this.balance;
|
|
5916
|
-
}
|
|
5917
|
-
static get MAX_LOAN_LIMIT() {
|
|
5918
|
-
return Player.MAX_LOAN;
|
|
5919
|
-
}
|
|
5920
|
-
get hasDebt() {
|
|
5921
|
-
return antelope.UInt64.from(this.debt).gt(antelope.UInt64.zero);
|
|
5922
|
-
}
|
|
5923
|
-
get isSolvent() {
|
|
5924
|
-
return this.networth.gte(antelope.Int64.zero);
|
|
5925
|
-
}
|
|
5926
|
-
withBalanceChange(delta) {
|
|
5927
|
-
const newPlayer = Player.from(this);
|
|
5928
|
-
const amount = typeof delta === 'number' ? antelope.UInt64.from(Math.abs(delta)) : delta;
|
|
5929
|
-
if (typeof delta === 'number' && delta < 0) {
|
|
5930
|
-
newPlayer.balance = antelope.UInt64.from(this.balance).gte(amount)
|
|
5931
|
-
? this.balance.subtracting(amount)
|
|
5932
|
-
: antelope.UInt64.from(0);
|
|
5933
|
-
}
|
|
5934
|
-
else {
|
|
5935
|
-
newPlayer.balance = this.balance.adding(amount);
|
|
5936
|
-
}
|
|
5937
|
-
const balanceInt = antelope.Int64.from(newPlayer.balance);
|
|
5938
|
-
const debtInt = antelope.Int64.from(newPlayer.debt);
|
|
5939
|
-
newPlayer.networth = balanceInt.subtracting(debtInt);
|
|
5940
|
-
return newPlayer;
|
|
5941
|
-
}
|
|
5942
|
-
withDebtChange(delta) {
|
|
5943
|
-
const newPlayer = Player.from(this);
|
|
5944
|
-
const amount = typeof delta === 'number' ? antelope.UInt64.from(Math.abs(delta)) : delta;
|
|
5945
|
-
if (typeof delta === 'number' && delta < 0) {
|
|
5946
|
-
newPlayer.debt = antelope.UInt64.from(this.debt).gte(amount)
|
|
5947
|
-
? this.debt.subtracting(amount)
|
|
5948
|
-
: antelope.UInt64.from(0);
|
|
5949
|
-
}
|
|
5950
|
-
else {
|
|
5951
|
-
newPlayer.debt = this.debt.adding(amount);
|
|
5952
|
-
}
|
|
5953
|
-
const balanceInt = antelope.Int64.from(newPlayer.balance);
|
|
5954
|
-
const debtInt = antelope.Int64.from(newPlayer.debt);
|
|
5955
|
-
newPlayer.networth = balanceInt.subtracting(debtInt);
|
|
5956
|
-
return newPlayer;
|
|
5957
|
-
}
|
|
5958
|
-
withLoan(amount) {
|
|
5959
|
-
const newPlayer = Player.from(this);
|
|
5960
|
-
newPlayer.balance = this.balance.adding(amount);
|
|
5961
|
-
newPlayer.debt = this.debt.adding(amount);
|
|
5962
|
-
const balanceInt = antelope.Int64.from(newPlayer.balance);
|
|
5963
|
-
const debtInt = antelope.Int64.from(newPlayer.debt);
|
|
5964
|
-
newPlayer.networth = balanceInt.subtracting(debtInt);
|
|
5965
|
-
return newPlayer;
|
|
5966
|
-
}
|
|
5967
|
-
withLoanPayment(amount) {
|
|
5968
|
-
const actualPayment = this.maxPayback.lt(amount) ? this.maxPayback : amount;
|
|
5969
|
-
const newPlayer = Player.from(this);
|
|
5970
|
-
newPlayer.balance = this.balance.subtracting(actualPayment);
|
|
5971
|
-
newPlayer.debt = this.debt.subtracting(actualPayment);
|
|
5972
|
-
const balanceInt = antelope.Int64.from(newPlayer.balance);
|
|
5973
|
-
const debtInt = antelope.Int64.from(newPlayer.debt);
|
|
5974
|
-
newPlayer.networth = balanceInt.subtracting(debtInt);
|
|
5975
|
-
return newPlayer;
|
|
5976
|
-
}
|
|
5977
|
-
withSaleNetworth(sellPrice, paidPerUnit, quantity) {
|
|
5978
|
-
const cost = paidPerUnit.multiplying(quantity);
|
|
5979
|
-
const profit = sellPrice.gte(cost) ? sellPrice.subtracting(cost) : antelope.Int64.from(0);
|
|
5980
|
-
const newPlayer = Player.from(this);
|
|
5981
|
-
newPlayer.networth = antelope.Int64.from(this.networth).adding(profit);
|
|
5982
|
-
return newPlayer;
|
|
5983
|
-
}
|
|
5984
|
-
withSellGoods(sellPrice, paidPerUnit, quantity) {
|
|
5985
|
-
const cost = paidPerUnit.multiplying(quantity);
|
|
5986
|
-
const profit = sellPrice.gte(cost) ? sellPrice.subtracting(cost) : antelope.Int64.from(0);
|
|
5987
|
-
const newPlayer = Player.from(this);
|
|
5988
|
-
newPlayer.balance = this.balance.adding(sellPrice);
|
|
5989
|
-
newPlayer.networth = antelope.Int64.from(this.networth).adding(profit);
|
|
5990
|
-
return newPlayer;
|
|
5991
|
-
}
|
|
5992
|
-
withBuyGoods(purchaseCost) {
|
|
5993
|
-
const newPlayer = Player.from(this);
|
|
5994
|
-
newPlayer.balance = antelope.UInt64.from(this.balance).gte(purchaseCost)
|
|
5995
|
-
? this.balance.subtracting(purchaseCost)
|
|
5996
|
-
: antelope.UInt64.from(0);
|
|
5997
|
-
const balanceInt = antelope.Int64.from(newPlayer.balance);
|
|
5998
|
-
const debtInt = antelope.Int64.from(newPlayer.debt);
|
|
5999
|
-
newPlayer.networth = balanceInt.subtracting(debtInt);
|
|
6000
|
-
return newPlayer;
|
|
6001
|
-
}
|
|
6002
5633
|
}
|
|
6003
|
-
Player.MAX_LOAN = 1000000;
|
|
6004
|
-
Player.BASE_SHIP_COST = 500;
|
|
6005
|
-
Player.SHIP_COST_MULTIPLIER = 5;
|
|
6006
5634
|
|
|
6007
5635
|
class PlayersManager extends BaseManager {
|
|
6008
5636
|
async getPlayer(account) {
|
|
@@ -6014,211 +5642,7 @@ class PlayersManager extends BaseManager {
|
|
|
6014
5642
|
}
|
|
6015
5643
|
}
|
|
6016
5644
|
|
|
6017
|
-
function roll(gameSeed, rollSeed) {
|
|
6018
|
-
const hash = hash512(gameSeed, rollSeed);
|
|
6019
|
-
return (hash.array[0] << 8) | hash.array[1];
|
|
6020
|
-
}
|
|
6021
|
-
|
|
6022
|
-
exports.Rarities = void 0;
|
|
6023
|
-
(function (Rarities) {
|
|
6024
|
-
Rarities["legendary"] = "LEGENDARY";
|
|
6025
|
-
Rarities["epic"] = "EPIC";
|
|
6026
|
-
Rarities["rare"] = "RARE";
|
|
6027
|
-
Rarities["uncommon"] = "UNCOMMON";
|
|
6028
|
-
Rarities["common"] = "COMMON";
|
|
6029
|
-
Rarities["trash"] = "TRASH";
|
|
6030
|
-
})(exports.Rarities || (exports.Rarities = {}));
|
|
6031
|
-
function getRarity(gameSeed, epochSeed, location, goodId) {
|
|
6032
|
-
const seed = `${epochSeed}${location.x}${location.y}${goodId}rarity`;
|
|
6033
|
-
const rarityRoll = roll(gameSeed, seed);
|
|
6034
|
-
if (rarityRoll < 13) {
|
|
6035
|
-
return {
|
|
6036
|
-
rarity: exports.Rarities.legendary,
|
|
6037
|
-
minMultiplier: 2.25,
|
|
6038
|
-
maxMultiplier: 3.0,
|
|
6039
|
-
};
|
|
6040
|
-
}
|
|
6041
|
-
else if (rarityRoll < 176) {
|
|
6042
|
-
return {
|
|
6043
|
-
rarity: exports.Rarities.epic,
|
|
6044
|
-
minMultiplier: 1.75,
|
|
6045
|
-
maxMultiplier: 2.25,
|
|
6046
|
-
};
|
|
6047
|
-
}
|
|
6048
|
-
else if (rarityRoll < 996) {
|
|
6049
|
-
return {
|
|
6050
|
-
rarity: exports.Rarities.rare,
|
|
6051
|
-
minMultiplier: 1.4,
|
|
6052
|
-
maxMultiplier: 1.75,
|
|
6053
|
-
};
|
|
6054
|
-
}
|
|
6055
|
-
else if (rarityRoll < 2966) {
|
|
6056
|
-
return {
|
|
6057
|
-
rarity: exports.Rarities.uncommon,
|
|
6058
|
-
minMultiplier: 1.225,
|
|
6059
|
-
maxMultiplier: 1.4,
|
|
6060
|
-
};
|
|
6061
|
-
}
|
|
6062
|
-
else if (rarityRoll < 19568) {
|
|
6063
|
-
return {
|
|
6064
|
-
rarity: exports.Rarities.common,
|
|
6065
|
-
minMultiplier: 1.07,
|
|
6066
|
-
maxMultiplier: 1.225,
|
|
6067
|
-
};
|
|
6068
|
-
}
|
|
6069
|
-
else if (rarityRoll < 45988) {
|
|
6070
|
-
return {
|
|
6071
|
-
rarity: exports.Rarities.trash,
|
|
6072
|
-
minMultiplier: 1,
|
|
6073
|
-
maxMultiplier: 1.07,
|
|
6074
|
-
};
|
|
6075
|
-
}
|
|
6076
|
-
else if (rarityRoll < 62508) {
|
|
6077
|
-
return {
|
|
6078
|
-
rarity: exports.Rarities.common,
|
|
6079
|
-
minMultiplier: 0.925,
|
|
6080
|
-
maxMultiplier: 1,
|
|
6081
|
-
};
|
|
6082
|
-
}
|
|
6083
|
-
else if (rarityRoll < 64518) {
|
|
6084
|
-
return {
|
|
6085
|
-
rarity: exports.Rarities.uncommon,
|
|
6086
|
-
minMultiplier: 0.77,
|
|
6087
|
-
maxMultiplier: 0.925,
|
|
6088
|
-
};
|
|
6089
|
-
}
|
|
6090
|
-
else if (rarityRoll < 65437) {
|
|
6091
|
-
return {
|
|
6092
|
-
rarity: exports.Rarities.rare,
|
|
6093
|
-
minMultiplier: 0.595,
|
|
6094
|
-
maxMultiplier: 0.77,
|
|
6095
|
-
};
|
|
6096
|
-
}
|
|
6097
|
-
else if (rarityRoll < 65523) {
|
|
6098
|
-
return {
|
|
6099
|
-
rarity: exports.Rarities.epic,
|
|
6100
|
-
minMultiplier: 0.41,
|
|
6101
|
-
maxMultiplier: 0.595,
|
|
6102
|
-
};
|
|
6103
|
-
}
|
|
6104
|
-
else {
|
|
6105
|
-
return {
|
|
6106
|
-
rarity: exports.Rarities.legendary,
|
|
6107
|
-
minMultiplier: 0.285,
|
|
6108
|
-
maxMultiplier: 0.41,
|
|
6109
|
-
};
|
|
6110
|
-
}
|
|
6111
|
-
}
|
|
6112
|
-
function getRarityMultiplier(gameSeed, epochSeed, location, goodId) {
|
|
6113
|
-
const rarity = getRarity(gameSeed, epochSeed, location, goodId);
|
|
6114
|
-
const range = rarity.maxMultiplier - rarity.minMultiplier;
|
|
6115
|
-
const seed = `${epochSeed}${location.x}${location.y}${goodId}raritymultiplier`;
|
|
6116
|
-
const r = roll(gameSeed, seed);
|
|
6117
|
-
return rarity.minMultiplier + (r / 65535) * range;
|
|
6118
|
-
}
|
|
6119
|
-
function getLocationMultiplier(gameSeed, location, goodId) {
|
|
6120
|
-
const seed = `${location.x}${location.y}${goodId}locationmultiplier`;
|
|
6121
|
-
const r = roll(gameSeed, seed);
|
|
6122
|
-
if (r < 13) {
|
|
6123
|
-
return 0.75;
|
|
6124
|
-
}
|
|
6125
|
-
else if (r < 176) {
|
|
6126
|
-
return 0.8;
|
|
6127
|
-
}
|
|
6128
|
-
else if (r < 996) {
|
|
6129
|
-
return 0.85;
|
|
6130
|
-
}
|
|
6131
|
-
else if (r < 2966) {
|
|
6132
|
-
return 0.9;
|
|
6133
|
-
}
|
|
6134
|
-
else if (r < 19568) {
|
|
6135
|
-
return 0.95;
|
|
6136
|
-
}
|
|
6137
|
-
else if (r < 45988) {
|
|
6138
|
-
return 1;
|
|
6139
|
-
}
|
|
6140
|
-
else if (r < 62508) {
|
|
6141
|
-
return 1.05;
|
|
6142
|
-
}
|
|
6143
|
-
else if (r < 64518) {
|
|
6144
|
-
return 1.1;
|
|
6145
|
-
}
|
|
6146
|
-
else if (r < 65437) {
|
|
6147
|
-
return 1.15;
|
|
6148
|
-
}
|
|
6149
|
-
else if (r < 65523) {
|
|
6150
|
-
return 1.2;
|
|
6151
|
-
}
|
|
6152
|
-
else {
|
|
6153
|
-
return 1.25;
|
|
6154
|
-
}
|
|
6155
|
-
}
|
|
6156
|
-
function getSupply(gameSeed, state, location, goodId) {
|
|
6157
|
-
const seed = `${state.seed}${location.x}${location.y}${goodId}supply`;
|
|
6158
|
-
const r = roll(gameSeed, seed);
|
|
6159
|
-
const percent = r / 65535;
|
|
6160
|
-
const epoch = 1 + Number(state.epoch) / 90;
|
|
6161
|
-
const ship = 1;
|
|
6162
|
-
const goodIdNum = Number(goodId);
|
|
6163
|
-
const base = Math.floor(128 / goodIdNum);
|
|
6164
|
-
return Math.floor(base * percent * ship * epoch);
|
|
6165
|
-
}
|
|
6166
|
-
function marketPrice(location, goodId, gameSeed, state) {
|
|
6167
|
-
const item = getItem(goodId);
|
|
6168
|
-
let price = Number(item.base_price);
|
|
6169
|
-
const rarityMultiplier = getRarityMultiplier(gameSeed, state.seed, location, goodId);
|
|
6170
|
-
price *= rarityMultiplier;
|
|
6171
|
-
const locationMultiplier = getLocationMultiplier(gameSeed, location, goodId);
|
|
6172
|
-
price *= locationMultiplier;
|
|
6173
|
-
const supply = getSupply(gameSeed, state, location, goodId);
|
|
6174
|
-
return exports.ItemPrice.from({
|
|
6175
|
-
id: goodId,
|
|
6176
|
-
item,
|
|
6177
|
-
price: antelope.UInt32.from(price),
|
|
6178
|
-
supply: antelope.UInt16.from(supply),
|
|
6179
|
-
});
|
|
6180
|
-
}
|
|
6181
|
-
function marketPrices(location, gameSeed, state) {
|
|
6182
|
-
return getItems().map((item) => marketPrice(location, item.id, gameSeed, state));
|
|
6183
|
-
}
|
|
6184
|
-
|
|
6185
5645
|
class LocationsManager extends BaseManager {
|
|
6186
|
-
async getMarketPrice(location, goodId) {
|
|
6187
|
-
const game = await this.getGame();
|
|
6188
|
-
const state = await this.getState();
|
|
6189
|
-
return marketPrice(location, goodId, game.config.seed, state);
|
|
6190
|
-
}
|
|
6191
|
-
async getMarketPrices(location) {
|
|
6192
|
-
const game = await this.getGame();
|
|
6193
|
-
const state = await this.getState();
|
|
6194
|
-
return marketPrices(location, game.config.seed, state);
|
|
6195
|
-
}
|
|
6196
|
-
async getMarketPricesWithSupply(location) {
|
|
6197
|
-
const [game, state, supplyRows] = await Promise.all([
|
|
6198
|
-
this.getGame(),
|
|
6199
|
-
this.getState(),
|
|
6200
|
-
this.getSupplyRows(location),
|
|
6201
|
-
]);
|
|
6202
|
-
const prices = marketPrices(location, game.config.seed, state);
|
|
6203
|
-
const supplyMap = new Map();
|
|
6204
|
-
for (const row of supplyRows) {
|
|
6205
|
-
if (antelope.UInt64.from(row.epoch).equals(state.epoch)) {
|
|
6206
|
-
supplyMap.set(Number(row.item_id), Number(row.supply));
|
|
6207
|
-
}
|
|
6208
|
-
}
|
|
6209
|
-
return prices.map((price) => {
|
|
6210
|
-
const actualSupply = supplyMap.get(Number(price.id));
|
|
6211
|
-
if (actualSupply !== undefined) {
|
|
6212
|
-
return exports.ItemPrice.from({
|
|
6213
|
-
id: price.id,
|
|
6214
|
-
item: price.item,
|
|
6215
|
-
price: price.price,
|
|
6216
|
-
supply: antelope.UInt64.from(actualSupply),
|
|
6217
|
-
});
|
|
6218
|
-
}
|
|
6219
|
-
return price;
|
|
6220
|
-
});
|
|
6221
|
-
}
|
|
6222
5646
|
async hasSystem(location) {
|
|
6223
5647
|
const game = await this.getGame();
|
|
6224
5648
|
return hasSystem(game.config.seed, location);
|
|
@@ -6227,40 +5651,6 @@ class LocationsManager extends BaseManager {
|
|
|
6227
5651
|
const game = await this.getGame();
|
|
6228
5652
|
return findNearbyPlanets(game.config.seed, origin, maxDistance);
|
|
6229
5653
|
}
|
|
6230
|
-
async getSupplyRows(location) {
|
|
6231
|
-
const hash = antelope.Checksum256.hash(antelope.Bytes.from(`${location.x}-${location.y}`, 'utf8'));
|
|
6232
|
-
return this.server.table('supply').all({
|
|
6233
|
-
index_position: 'secondary',
|
|
6234
|
-
from: hash,
|
|
6235
|
-
to: hash,
|
|
6236
|
-
});
|
|
6237
|
-
}
|
|
6238
|
-
async getLocationWithPrices(coords) {
|
|
6239
|
-
const location = toLocation(coords);
|
|
6240
|
-
const prices = await this.getMarketPrices(location.coordinates);
|
|
6241
|
-
location.setMarketPrices(prices);
|
|
6242
|
-
return location;
|
|
6243
|
-
}
|
|
6244
|
-
async getLocationWithSupply(coords) {
|
|
6245
|
-
const location = toLocation(coords);
|
|
6246
|
-
const [rows, state] = await Promise.all([
|
|
6247
|
-
this.getSupplyRows(location.coordinates),
|
|
6248
|
-
this.getState(),
|
|
6249
|
-
]);
|
|
6250
|
-
location.setLocationRows(rows, state.epoch);
|
|
6251
|
-
return location;
|
|
6252
|
-
}
|
|
6253
|
-
async getLocationComplete(coords) {
|
|
6254
|
-
const location = toLocation(coords);
|
|
6255
|
-
const [prices, rows, state] = await Promise.all([
|
|
6256
|
-
this.getMarketPrices(location.coordinates),
|
|
6257
|
-
this.getSupplyRows(location.coordinates),
|
|
6258
|
-
this.getState(),
|
|
6259
|
-
]);
|
|
6260
|
-
location.setMarketPrices(prices);
|
|
6261
|
-
location.setLocationRows(rows, state.epoch);
|
|
6262
|
-
return location;
|
|
6263
|
-
}
|
|
6264
5654
|
async getLocationEntity(id) {
|
|
6265
5655
|
const row = await this.server.table('location').get(antelope.UInt64.from(id));
|
|
6266
5656
|
return row ?? undefined;
|
|
@@ -6274,778 +5664,55 @@ class LocationsManager extends BaseManager {
|
|
|
6274
5664
|
}
|
|
6275
5665
|
}
|
|
6276
5666
|
|
|
6277
|
-
|
|
6278
|
-
|
|
6279
|
-
|
|
6280
|
-
|
|
6281
|
-
}
|
|
6282
|
-
function calculateMaxTradeQuantity(ship, player, goodPrice) {
|
|
6283
|
-
const pricePerUnit = antelope.UInt32.from(goodPrice.price);
|
|
6284
|
-
const massPerUnit = antelope.UInt32.from(goodPrice.item.mass);
|
|
6285
|
-
const spaceForQuantity = ship.availableCapacity.dividing(massPerUnit);
|
|
6286
|
-
const affordableQuantity = player.balance.dividing(pricePerUnit);
|
|
6287
|
-
const maxQuantity = spaceForQuantity.lt(affordableQuantity)
|
|
6288
|
-
? spaceForQuantity
|
|
6289
|
-
: affordableQuantity;
|
|
6290
|
-
return {
|
|
6291
|
-
maxQuantity: Number(maxQuantity),
|
|
6292
|
-
totalCost: Number(maxQuantity.multiplying(pricePerUnit)),
|
|
6293
|
-
totalMass: antelope.UInt64.from(maxQuantity.multiplying(massPerUnit)),
|
|
6294
|
-
affordableQuantity: Number(affordableQuantity),
|
|
6295
|
-
spaceForQuantity: Number(spaceForQuantity),
|
|
6296
|
-
};
|
|
6297
|
-
}
|
|
6298
|
-
function calculateTradeProfit(quantity, buyPrice, sellPrice) {
|
|
6299
|
-
const qty = antelope.UInt32.from(quantity);
|
|
6300
|
-
const buy = antelope.UInt32.from(buyPrice);
|
|
6301
|
-
const sell = antelope.UInt32.from(sellPrice);
|
|
6302
|
-
const cost = antelope.UInt64.from(qty).multiplying(buy);
|
|
6303
|
-
const revenue = antelope.UInt64.from(qty).multiplying(sell);
|
|
6304
|
-
const profit = antelope.Int64.from(revenue).subtracting(cost);
|
|
6305
|
-
const margin = cost.gt(antelope.UInt64.zero) ? (Number(profit) / Number(cost)) * 100 : 0;
|
|
6306
|
-
return { revenue, cost, profit, margin };
|
|
6307
|
-
}
|
|
6308
|
-
function calculateProfitPerMass(quantity, buyPrice, sellPrice, massPerUnit) {
|
|
6309
|
-
const profit = (sellPrice - buyPrice) * quantity;
|
|
6310
|
-
const totalMass = quantity * massPerUnit;
|
|
6311
|
-
return totalMass > 0 ? profit / totalMass : 0;
|
|
6312
|
-
}
|
|
6313
|
-
function calculateProfitPerSecond(profit, travelTimeSeconds) {
|
|
6314
|
-
const t = antelope.UInt32.from(travelTimeSeconds);
|
|
6315
|
-
return t.gt(antelope.UInt32.zero) ? Number(profit) / Number(t) : 0;
|
|
6316
|
-
}
|
|
6317
|
-
function findBestItemToTrade(ship, player, originPrices, destPrices, travelTimeSeconds) {
|
|
6318
|
-
let bestTrade = null;
|
|
6319
|
-
let bestProfitPerSecond = 0;
|
|
6320
|
-
for (const originPrice of originPrices) {
|
|
6321
|
-
const destPrice = destPrices.find((p) => p.id.equals(originPrice.id));
|
|
6322
|
-
if (!destPrice)
|
|
6323
|
-
continue;
|
|
6324
|
-
if (!isProfitable(originPrice.price, destPrice.price))
|
|
6325
|
-
continue;
|
|
6326
|
-
const calc = calculateMaxTradeQuantity(ship, player, originPrice);
|
|
6327
|
-
if (calc.maxQuantity === 0)
|
|
6328
|
-
continue;
|
|
6329
|
-
const tradeResult = calculateTradeProfit(calc.maxQuantity, originPrice.price, destPrice.price);
|
|
6330
|
-
const profitPerSecond = calculateProfitPerSecond(tradeResult.profit, travelTimeSeconds);
|
|
6331
|
-
if (profitPerSecond > bestProfitPerSecond) {
|
|
6332
|
-
bestProfitPerSecond = profitPerSecond;
|
|
6333
|
-
bestTrade = {
|
|
6334
|
-
item: originPrice,
|
|
6335
|
-
quantity: calc.maxQuantity,
|
|
6336
|
-
profit: Number(tradeResult.profit),
|
|
6337
|
-
profitPerSecond,
|
|
6338
|
-
margin: tradeResult.margin,
|
|
6339
|
-
};
|
|
6340
|
-
}
|
|
5667
|
+
class EpochsManager extends BaseManager {
|
|
5668
|
+
async getCurrentHeight() {
|
|
5669
|
+
const game = await this.getGame();
|
|
5670
|
+
return getCurrentEpoch(game);
|
|
6341
5671
|
}
|
|
6342
|
-
|
|
6343
|
-
|
|
6344
|
-
|
|
6345
|
-
|
|
6346
|
-
}
|
|
6347
|
-
function isProfitable(buyPrice, sellPrice) {
|
|
6348
|
-
return antelope.UInt32.from(sellPrice).gt(antelope.UInt32.from(buyPrice));
|
|
6349
|
-
}
|
|
6350
|
-
function calculateROI(cost, profit) {
|
|
6351
|
-
return cost > 0 ? (profit / cost) * 100 : 0;
|
|
6352
|
-
}
|
|
6353
|
-
|
|
6354
|
-
async function findDealsForShip(ship, originLocation, getNearbyLocations, getMarketPrices, options = {}) {
|
|
6355
|
-
const { maxDeals = 10, maxDistance = 20 * PRECISION, playerBalance, minProfitPerSecond = 0, minMarginPercent = 0, availableSpace, } = options;
|
|
6356
|
-
const balance = playerBalance !== undefined ? antelope.UInt64.from(playerBalance) : undefined;
|
|
6357
|
-
const origin = Location.from(originLocation);
|
|
6358
|
-
const originPrices = await getMarketPrices(originLocation);
|
|
6359
|
-
origin.setMarketPrices(originPrices);
|
|
6360
|
-
const nearbyLocations = await getNearbyLocations(originLocation, maxDistance);
|
|
6361
|
-
const deals = [];
|
|
6362
|
-
const currentMass = ship.totalMass;
|
|
6363
|
-
const shipCapacity = ship.maxCapacity;
|
|
6364
|
-
const effectiveAvailableMass = availableSpace !== undefined
|
|
6365
|
-
? antelope.UInt64.from(availableSpace)
|
|
6366
|
-
: currentMass.lt(shipCapacity)
|
|
6367
|
-
? shipCapacity.subtracting(currentMass)
|
|
6368
|
-
: antelope.UInt64.zero;
|
|
6369
|
-
for (const destLocation of nearbyLocations) {
|
|
6370
|
-
const destinationPrices = await getMarketPrices(destLocation.coordinates);
|
|
6371
|
-
destLocation.setMarketPrices(destinationPrices);
|
|
6372
|
-
const distance = distanceBetweenCoordinates(originLocation, destLocation.coordinates);
|
|
6373
|
-
for (const originGood of originPrices) {
|
|
6374
|
-
const destGood = destinationPrices.find((g) => g.id.equals(originGood.id));
|
|
6375
|
-
if (!destGood)
|
|
6376
|
-
continue;
|
|
6377
|
-
if (!isProfitable(originGood.price, destGood.price) ||
|
|
6378
|
-
originGood.supply.equals(antelope.UInt16.from(0))) {
|
|
6379
|
-
continue;
|
|
6380
|
-
}
|
|
6381
|
-
const canAfford = balance !== undefined
|
|
6382
|
-
? balance.dividing(originGood.price)
|
|
6383
|
-
: antelope.UInt64.from(Number.MAX_SAFE_INTEGER);
|
|
6384
|
-
const canHaul = effectiveAvailableMass.dividing(originGood.item.mass);
|
|
6385
|
-
const supplyLimit = antelope.UInt64.from(originGood.supply);
|
|
6386
|
-
let maxQuantity = canAfford;
|
|
6387
|
-
if (canHaul.lt(maxQuantity))
|
|
6388
|
-
maxQuantity = canHaul;
|
|
6389
|
-
if (supplyLimit.lt(maxQuantity))
|
|
6390
|
-
maxQuantity = supplyLimit;
|
|
6391
|
-
if (maxQuantity.equals(antelope.UInt64.zero))
|
|
6392
|
-
continue;
|
|
6393
|
-
const cargoMass = originGood.item.mass.multiplying(maxQuantity);
|
|
6394
|
-
const availableSpaceUInt = antelope.UInt64.from(availableSpace);
|
|
6395
|
-
const baseMass = availableSpace !== undefined
|
|
6396
|
-
? shipCapacity.gte(availableSpaceUInt)
|
|
6397
|
-
? shipCapacity.subtracting(availableSpaceUInt)
|
|
6398
|
-
: antelope.UInt64.zero
|
|
6399
|
-
: currentMass;
|
|
6400
|
-
const totalMass = baseMass.adding(cargoMass);
|
|
6401
|
-
const needsRecharge = !ship.hasEnergyFor(distance);
|
|
6402
|
-
const travelEstimate = estimateTravelTime(ship, totalMass, distance, {
|
|
6403
|
-
needsRecharge,
|
|
6404
|
-
loadMass: Number(cargoMass),
|
|
6405
|
-
});
|
|
6406
|
-
const tradeCalc = calculateTradeProfit(maxQuantity, originGood.price, destGood.price);
|
|
6407
|
-
const profitPerUnit = destGood.price.subtracting(originGood.price);
|
|
6408
|
-
const profitPerSecond = calculateProfitPerSecond(tradeCalc.profit, travelEstimate.total);
|
|
6409
|
-
if (profitPerSecond < minProfitPerSecond)
|
|
6410
|
-
continue;
|
|
6411
|
-
if (tradeCalc.margin < minMarginPercent)
|
|
6412
|
-
continue;
|
|
6413
|
-
deals.push({
|
|
6414
|
-
origin,
|
|
6415
|
-
destination: destLocation,
|
|
6416
|
-
item: originGood,
|
|
6417
|
-
distance,
|
|
6418
|
-
supply: originGood.supply,
|
|
6419
|
-
buyPrice: originGood.price,
|
|
6420
|
-
sellPrice: destGood.price,
|
|
6421
|
-
profitPerUnit,
|
|
6422
|
-
maxQuantity: antelope.UInt32.from(maxQuantity),
|
|
6423
|
-
totalProfit: tradeCalc.profit,
|
|
6424
|
-
travelTime: travelEstimate.total,
|
|
6425
|
-
travelTimeBreakdown: travelEstimate,
|
|
6426
|
-
profitPerSecond,
|
|
6427
|
-
marginPercent: tradeCalc.margin,
|
|
6428
|
-
});
|
|
6429
|
-
}
|
|
5672
|
+
async getCurrent() {
|
|
5673
|
+
const game = await this.getGame();
|
|
5674
|
+
const epoch = await this.getCurrentHeight();
|
|
5675
|
+
return getEpochInfo(game, epoch);
|
|
6430
5676
|
}
|
|
6431
|
-
|
|
6432
|
-
|
|
6433
|
-
|
|
6434
|
-
async function findBestDeal(ship, originLocation, getNearbyLocations, getMarketPrices, options = {}) {
|
|
6435
|
-
const deals = await findDealsForShip(ship, originLocation, getNearbyLocations, getMarketPrices, {
|
|
6436
|
-
...options,
|
|
6437
|
-
maxDeals: 1,
|
|
6438
|
-
});
|
|
6439
|
-
return deals[0];
|
|
6440
|
-
}
|
|
6441
|
-
|
|
6442
|
-
function calculateCargoMass(cargo) {
|
|
6443
|
-
let mass = antelope.UInt32.from(0);
|
|
6444
|
-
for (const c of cargo) {
|
|
6445
|
-
if (antelope.UInt64.from(c.quantity).gt(antelope.UInt64.zero)) {
|
|
6446
|
-
const goodMass = getItem(c.item_id).mass;
|
|
6447
|
-
mass = mass.adding(goodMass.multiplying(c.quantity));
|
|
6448
|
-
}
|
|
5677
|
+
async getByHeight(height) {
|
|
5678
|
+
const game = await this.getGame();
|
|
5679
|
+
return getEpochInfo(game, antelope.UInt64.from(height));
|
|
6449
5680
|
}
|
|
6450
|
-
|
|
6451
|
-
|
|
6452
|
-
|
|
6453
|
-
|
|
6454
|
-
|
|
6455
|
-
!ship.loaders ||
|
|
6456
|
-
ship.loaders.quantity.equals(antelope.UInt32.zero)) {
|
|
6457
|
-
return antelope.UInt32.zero;
|
|
5681
|
+
async getTimeRemaining() {
|
|
5682
|
+
const epochInfo = await this.getCurrent();
|
|
5683
|
+
const now = Date.now();
|
|
5684
|
+
const endTime = epochInfo.end.getTime();
|
|
5685
|
+
return Math.max(0, endTime - now);
|
|
6458
5686
|
}
|
|
6459
|
-
|
|
6460
|
-
|
|
6461
|
-
|
|
6462
|
-
|
|
6463
|
-
|
|
6464
|
-
|
|
6465
|
-
|
|
6466
|
-
if (
|
|
6467
|
-
|
|
6468
|
-
|
|
6469
|
-
|
|
6470
|
-
|
|
6471
|
-
|
|
6472
|
-
|
|
6473
|
-
|
|
5687
|
+
async getProgress() {
|
|
5688
|
+
const epochInfo = await this.getCurrent();
|
|
5689
|
+
const now = Date.now();
|
|
5690
|
+
const startTime = epochInfo.start.getTime();
|
|
5691
|
+
const endTime = epochInfo.end.getTime();
|
|
5692
|
+
const duration = endTime - startTime;
|
|
5693
|
+
const elapsed = now - startTime;
|
|
5694
|
+
if (elapsed <= 0)
|
|
5695
|
+
return 0;
|
|
5696
|
+
if (elapsed >= duration)
|
|
5697
|
+
return 1;
|
|
5698
|
+
return elapsed / duration;
|
|
5699
|
+
}
|
|
5700
|
+
async fitsInCurrentEpoch(durationMs) {
|
|
5701
|
+
const remaining = await this.getTimeRemaining();
|
|
5702
|
+
return durationMs <= remaining;
|
|
6474
5703
|
}
|
|
6475
|
-
return {
|
|
6476
|
-
revenue,
|
|
6477
|
-
cost,
|
|
6478
|
-
profit: antelope.Int64.from(revenue).subtracting(cost),
|
|
6479
|
-
};
|
|
6480
5704
|
}
|
|
6481
|
-
|
|
6482
|
-
|
|
6483
|
-
|
|
6484
|
-
|
|
6485
|
-
|
|
6486
|
-
|
|
6487
|
-
|
|
6488
|
-
|
|
6489
|
-
|
|
6490
|
-
|
|
6491
|
-
|
|
6492
|
-
items.push({
|
|
6493
|
-
goodId: c.item_id,
|
|
6494
|
-
goodName: c.item?.name ?? `Item #${goodId}`,
|
|
6495
|
-
quantity: antelope.UInt32.from(c.quantity),
|
|
6496
|
-
pricePerUnit,
|
|
6497
|
-
revenue,
|
|
6498
|
-
costPerUnit: c.unit_cost,
|
|
6499
|
-
profit,
|
|
6500
|
-
});
|
|
6501
|
-
}
|
|
6502
|
-
return items;
|
|
6503
|
-
}
|
|
6504
|
-
function createSellAndTradeOption(saleRevenue, saleCost, deal, cargoSale, unloadTime) {
|
|
6505
|
-
const saleProfit = antelope.Int64.from(saleRevenue).subtracting(saleCost);
|
|
6506
|
-
const totalProfit = saleProfit.adding(deal.totalProfit);
|
|
6507
|
-
const profitPerSecond = deal.travelTime.gt(antelope.UInt32.zero)
|
|
6508
|
-
? Number(totalProfit) / Number(deal.travelTime)
|
|
6509
|
-
: Number(totalProfit);
|
|
6510
|
-
const unload = unloadTime ?? antelope.UInt32.zero;
|
|
6511
|
-
const breakdown = deal.travelTimeBreakdown
|
|
6512
|
-
? {
|
|
6513
|
-
unloadTime: unload,
|
|
6514
|
-
loadTime: deal.travelTimeBreakdown.loadTime,
|
|
6515
|
-
rechargeTime: deal.travelTimeBreakdown.rechargeTime,
|
|
6516
|
-
flightTime: deal.travelTimeBreakdown.flightTime,
|
|
6517
|
-
total: unload
|
|
6518
|
-
.adding(deal.travelTimeBreakdown.loadTime)
|
|
6519
|
-
.adding(deal.travelTimeBreakdown.rechargeTime)
|
|
6520
|
-
.adding(deal.travelTimeBreakdown.flightTime),
|
|
6521
|
-
}
|
|
6522
|
-
: undefined;
|
|
6523
|
-
return {
|
|
6524
|
-
id: `sell-trade-${deal.destination.coordinates.x}-${deal.destination.coordinates.y}-${deal.item.id}`,
|
|
6525
|
-
type: 'sell-and-trade',
|
|
6526
|
-
title: `Trade ${deal.item.item.name}`,
|
|
6527
|
-
description: `Sell cargo, buy ${deal.maxQuantity} ${deal.item.item.name}, deliver to (${deal.destination.coordinates.x}, ${deal.destination.coordinates.y})`,
|
|
6528
|
-
reason: `${deal.marginPercent.toFixed(0)}% margin, ${deal.profitPerSecond.toFixed(1)}/s profit rate`,
|
|
6529
|
-
recommended: false,
|
|
6530
|
-
highestProfit: false,
|
|
6531
|
-
estimatedProfit: saleProfit,
|
|
6532
|
-
saleRevenue,
|
|
6533
|
-
purchaseCost: antelope.UInt64.from(deal.buyPrice).multiplying(deal.maxQuantity),
|
|
6534
|
-
nextTradeProfit: deal.totalProfit,
|
|
6535
|
-
profitPerSecond,
|
|
6536
|
-
marginPercent: deal.marginPercent,
|
|
6537
|
-
destination: deal.destination,
|
|
6538
|
-
deal,
|
|
6539
|
-
travelTime: breakdown?.total ?? deal.travelTime,
|
|
6540
|
-
travelTimeBreakdown: breakdown,
|
|
6541
|
-
cargoSale,
|
|
6542
|
-
cargoProfitLoss: saleProfit,
|
|
6543
|
-
};
|
|
6544
|
-
}
|
|
6545
|
-
function createTravelToSellOption(currentRevenue, cargoCost, betterSale, cargo, destPrices) {
|
|
6546
|
-
const totalQuantity = cargo.reduce((s, c) => s.adding(antelope.UInt64.from(c.quantity)), antelope.UInt64.zero);
|
|
6547
|
-
const currentPrice = totalQuantity.gt(antelope.UInt64.zero)
|
|
6548
|
-
? antelope.UInt32.from(currentRevenue.dividing(totalQuantity))
|
|
6549
|
-
: antelope.UInt32.zero;
|
|
6550
|
-
const priceIncrease = betterSale.price.gte(currentPrice)
|
|
6551
|
-
? betterSale.price.subtracting(currentPrice)
|
|
6552
|
-
: antelope.UInt32.zero;
|
|
6553
|
-
const hasDealAfter = !!betterSale.bestDealAfterSale;
|
|
6554
|
-
const cargoSale = destPrices ? buildCargoSaleItems(cargo, destPrices) : undefined;
|
|
6555
|
-
const cargoProfitLoss = cargoSale?.reduce((sum, item) => sum.adding(item.profit), antelope.Int64.zero);
|
|
6556
|
-
const saleProfit = antelope.Int64.from(betterSale.revenue).subtracting(cargoCost);
|
|
6557
|
-
const profitPerSecond = betterSale.travelTime.gt(antelope.UInt32.zero)
|
|
6558
|
-
? Number(saleProfit) / Number(betterSale.travelTime)
|
|
6559
|
-
: Number(saleProfit);
|
|
6560
|
-
return {
|
|
6561
|
-
id: `travel-sell-${betterSale.location.coordinates.x}-${betterSale.location.coordinates.y}`,
|
|
6562
|
-
type: 'travel-to-sell',
|
|
6563
|
-
title: 'Move to Sell Nearby',
|
|
6564
|
-
description: `Keep cargo, travel to better market${hasDealAfter ? ', then trade' : ''}`,
|
|
6565
|
-
reason: `+${Number(priceIncrease).toLocaleString()}/unit better price${hasDealAfter ? ', good deals available there' : ''}`,
|
|
6566
|
-
recommended: false,
|
|
6567
|
-
highestProfit: false,
|
|
6568
|
-
estimatedProfit: betterSale.improvement,
|
|
6569
|
-
saleRevenue: betterSale.revenue,
|
|
6570
|
-
profitPerSecond,
|
|
6571
|
-
saleLocation: betterSale.location,
|
|
6572
|
-
salePrice: betterSale.price,
|
|
6573
|
-
currentPrice,
|
|
6574
|
-
destination: betterSale.location,
|
|
6575
|
-
deal: betterSale.bestDealAfterSale,
|
|
6576
|
-
travelTime: betterSale.travelTime,
|
|
6577
|
-
travelTimeBreakdown: betterSale.travelTimeBreakdown,
|
|
6578
|
-
cargoSale,
|
|
6579
|
-
cargoProfitLoss,
|
|
6580
|
-
};
|
|
6581
|
-
}
|
|
6582
|
-
function createSellAndRepositionOption(saleRevenue, saleCost, reposition, cargoSale) {
|
|
6583
|
-
const saleProfit = antelope.Int64.from(saleRevenue).subtracting(saleCost);
|
|
6584
|
-
const deal = reposition.bestDeal;
|
|
6585
|
-
return {
|
|
6586
|
-
id: `sell-reposition-${reposition.location.coordinates.x}-${reposition.location.coordinates.y}`,
|
|
6587
|
-
type: 'sell-and-reposition',
|
|
6588
|
-
title: 'Sell & Move',
|
|
6589
|
-
description: `Sell cargo here, travel empty to buy ${deal.item.item.name}`,
|
|
6590
|
-
reason: `No good trades here — ${deal.marginPercent.toFixed(0)}% margin trade available at destination`,
|
|
6591
|
-
recommended: false,
|
|
6592
|
-
highestProfit: false,
|
|
6593
|
-
estimatedProfit: saleProfit,
|
|
6594
|
-
saleRevenue,
|
|
6595
|
-
nextTradeProfit: deal.totalProfit,
|
|
6596
|
-
profitPerSecond: deal.profitPerSecond,
|
|
6597
|
-
marginPercent: deal.marginPercent,
|
|
6598
|
-
destination: reposition.location,
|
|
6599
|
-
deal: reposition.bestDeal,
|
|
6600
|
-
travelTime: reposition.travelTime,
|
|
6601
|
-
travelTimeBreakdown: reposition.travelTimeBreakdown,
|
|
6602
|
-
cargoSale,
|
|
6603
|
-
cargoProfitLoss: saleProfit,
|
|
6604
|
-
};
|
|
6605
|
-
}
|
|
6606
|
-
function createOrbitOption() {
|
|
6607
|
-
return {
|
|
6608
|
-
id: 'orbit',
|
|
6609
|
-
type: 'orbit',
|
|
6610
|
-
title: 'Enter Orbit',
|
|
6611
|
-
description: 'Arrive at this location, keep cargo',
|
|
6612
|
-
reason: 'Keep cargo, decide later',
|
|
6613
|
-
recommended: false,
|
|
6614
|
-
highestProfit: false,
|
|
6615
|
-
estimatedProfit: antelope.UInt64.zero,
|
|
6616
|
-
};
|
|
6617
|
-
}
|
|
6618
|
-
function createSellAndStayOption(saleRevenue, saleCost, cargoSale, unloadTime) {
|
|
6619
|
-
const saleProfit = antelope.Int64.from(saleRevenue).subtracting(saleCost);
|
|
6620
|
-
return {
|
|
6621
|
-
id: 'sell-stay',
|
|
6622
|
-
type: 'sell-and-stay',
|
|
6623
|
-
title: 'Sell & Enter Orbit',
|
|
6624
|
-
description: `Sell cargo, remain docked at this location`,
|
|
6625
|
-
reason: 'Collect profits now, decide next move later',
|
|
6626
|
-
recommended: false,
|
|
6627
|
-
highestProfit: false,
|
|
6628
|
-
estimatedProfit: saleProfit,
|
|
6629
|
-
saleRevenue,
|
|
6630
|
-
cargoSale,
|
|
6631
|
-
cargoProfitLoss: saleProfit,
|
|
6632
|
-
travelTimeBreakdown: unloadTime !== undefined
|
|
6633
|
-
? {
|
|
6634
|
-
unloadTime,
|
|
6635
|
-
loadTime: antelope.UInt32.zero,
|
|
6636
|
-
rechargeTime: antelope.UInt32.zero,
|
|
6637
|
-
flightTime: antelope.UInt32.zero,
|
|
6638
|
-
total: unloadTime,
|
|
6639
|
-
}
|
|
6640
|
-
: undefined,
|
|
6641
|
-
};
|
|
6642
|
-
}
|
|
6643
|
-
function createExploreOption(destination, travelTime, discountedGood, travelTimeBreakdown, potentialDeals) {
|
|
6644
|
-
let description = 'Travel to look for trading opportunities';
|
|
6645
|
-
let reason = 'No profitable trades found nearby';
|
|
6646
|
-
if (potentialDeals && potentialDeals.length > 0) {
|
|
6647
|
-
const bestDeal = potentialDeals[0];
|
|
6648
|
-
description = `${potentialDeals.length} deal${potentialDeals.length > 1 ? 's' : ''} available — best: ${bestDeal.goodName}`;
|
|
6649
|
-
reason = `${bestDeal.marginPercent.toFixed(0)}% margin, ${bestDeal.profitPerSecond.toFixed(1)}/s`;
|
|
6650
|
-
}
|
|
6651
|
-
else if (discountedGood) {
|
|
6652
|
-
const { name, discountPercent } = discountedGood;
|
|
6653
|
-
if (discountPercent >= 60) {
|
|
6654
|
-
description = `${name} at ${discountPercent}% off`;
|
|
6655
|
-
reason = 'Legendary find — extremely rare opportunity';
|
|
6656
|
-
}
|
|
6657
|
-
else if (discountPercent >= 40) {
|
|
6658
|
-
description = `${name} at ${discountPercent}% off`;
|
|
6659
|
-
reason = 'Epic deal — exceptional prices';
|
|
6660
|
-
}
|
|
6661
|
-
else if (discountPercent >= 23) {
|
|
6662
|
-
description = `${name} at ${discountPercent}% off`;
|
|
6663
|
-
reason = 'Rare discount — well below market';
|
|
6664
|
-
}
|
|
6665
|
-
else if (discountPercent >= 8) {
|
|
6666
|
-
description = `${name} at ${discountPercent}% off`;
|
|
6667
|
-
reason = `Good prices on ${name}`;
|
|
6668
|
-
}
|
|
6669
|
-
else {
|
|
6670
|
-
description = `${name} slightly discounted`;
|
|
6671
|
-
reason = 'Minor savings available';
|
|
6672
|
-
}
|
|
6673
|
-
}
|
|
6674
|
-
return {
|
|
6675
|
-
id: `explore-${destination.coordinates.x}-${destination.coordinates.y}`,
|
|
6676
|
-
type: 'explore',
|
|
6677
|
-
title: 'Move',
|
|
6678
|
-
description,
|
|
6679
|
-
reason,
|
|
6680
|
-
recommended: false,
|
|
6681
|
-
highestProfit: false,
|
|
6682
|
-
estimatedProfit: antelope.UInt64.zero,
|
|
6683
|
-
destination,
|
|
6684
|
-
travelTime,
|
|
6685
|
-
travelTimeBreakdown,
|
|
6686
|
-
discountedGood,
|
|
6687
|
-
potentialDeals,
|
|
6688
|
-
};
|
|
6689
|
-
}
|
|
6690
|
-
async function analyzeCollectOptions(ship, arrivedAt, callbacks, options = {}) {
|
|
6691
|
-
const { playerBalance = Infinity, minSaleImprovement = 100 } = options;
|
|
6692
|
-
const cargo = ship.sellableCargo;
|
|
6693
|
-
const hasCargo = cargo.length > 0;
|
|
6694
|
-
const originPrices = await callbacks.getMarketPrices(arrivedAt);
|
|
6695
|
-
const priceMap = new Map(originPrices.map((p) => [Number(p.id), p.price]));
|
|
6696
|
-
const { revenue: cargoValueHere, cost: cargoCost } = analyzeCargoSale(cargo, priceMap);
|
|
6697
|
-
const cargoSaleHere = buildCargoSaleItems(cargo, priceMap);
|
|
6698
|
-
const collectOptions = [];
|
|
6699
|
-
const maxDistance = options.maxDistance ?? Number(ship.maxDistance);
|
|
6700
|
-
const nearbyLocations = await callbacks.getNearbyLocations(arrivedAt, maxDistance);
|
|
6701
|
-
const dealsAtOrigin = await findDealsForShip(ship, arrivedAt, callbacks.getNearbyLocations, callbacks.getMarketPrices, {
|
|
6702
|
-
maxDeals: 5,
|
|
6703
|
-
maxDistance,
|
|
6704
|
-
playerBalance: playerBalance + Number(cargoValueHere),
|
|
6705
|
-
availableSpace: Number(ship.maxCapacity),
|
|
6706
|
-
});
|
|
6707
|
-
if (hasCargo && dealsAtOrigin.length > 0) {
|
|
6708
|
-
const cargoGoodIds = new Set(cargo.map((c) => Number(c.item_id)));
|
|
6709
|
-
for (const deal of dealsAtOrigin.slice(0, 3)) {
|
|
6710
|
-
const dealGoodId = Number(deal.item.id);
|
|
6711
|
-
if (cargoGoodIds.has(dealGoodId)) {
|
|
6712
|
-
continue;
|
|
6713
|
-
}
|
|
6714
|
-
const unloadTime = calculateUnloadTime(ship, cargo);
|
|
6715
|
-
const option = createSellAndTradeOption(cargoValueHere, cargoCost, deal, cargoSaleHere, unloadTime);
|
|
6716
|
-
collectOptions.push(option);
|
|
6717
|
-
}
|
|
6718
|
-
}
|
|
6719
|
-
if (hasCargo) {
|
|
6720
|
-
const locationsToCheck = nearbyLocations.slice(0, 10);
|
|
6721
|
-
const allDestPrices = await Promise.all(locationsToCheck.map((loc) => callbacks.getMarketPrices(loc.coordinates)));
|
|
6722
|
-
const candidateLocations = [];
|
|
6723
|
-
for (let i = 0; i < locationsToCheck.length; i++) {
|
|
6724
|
-
const destLocation = locationsToCheck[i];
|
|
6725
|
-
const destPrices = allDestPrices[i];
|
|
6726
|
-
const destPriceMap = new Map(destPrices.map((p) => [Number(p.id), p.price]));
|
|
6727
|
-
const { revenue: destRevenue } = analyzeCargoSale(cargo, destPriceMap);
|
|
6728
|
-
const improvement = antelope.Int64.from(destRevenue).subtracting(cargoValueHere);
|
|
6729
|
-
if (improvement.gt(antelope.Int64.from(minSaleImprovement))) {
|
|
6730
|
-
candidateLocations.push({ destLocation, destPriceMap, destRevenue, improvement });
|
|
6731
|
-
}
|
|
6732
|
-
}
|
|
6733
|
-
const betterSaleResults = await Promise.all(candidateLocations.map(async ({ destLocation, destPriceMap, destRevenue, improvement }) => {
|
|
6734
|
-
const distance = distanceBetweenCoordinates(arrivedAt, destLocation.coordinates);
|
|
6735
|
-
const needsRecharge = !ship.hasEnergyFor(distance);
|
|
6736
|
-
const travelEstimate = estimateTravelTime(ship, ship.totalMass, distance, {
|
|
6737
|
-
needsRecharge,
|
|
6738
|
-
});
|
|
6739
|
-
const dealsAfterSale = await findDealsForShip(ship, destLocation.coordinates, callbacks.getNearbyLocations, callbacks.getMarketPrices, {
|
|
6740
|
-
maxDeals: 1,
|
|
6741
|
-
maxDistance,
|
|
6742
|
-
playerBalance: destRevenue,
|
|
6743
|
-
availableSpace: Number(ship.maxCapacity),
|
|
6744
|
-
});
|
|
6745
|
-
return {
|
|
6746
|
-
better: {
|
|
6747
|
-
location: destLocation,
|
|
6748
|
-
price: antelope.UInt32.from(destRevenue.dividing(cargo.reduce((s, c) => s.adding(c.quantity), antelope.UInt64.zero))),
|
|
6749
|
-
revenue: destRevenue,
|
|
6750
|
-
improvement,
|
|
6751
|
-
bestDealAfterSale: dealsAfterSale[0],
|
|
6752
|
-
distance,
|
|
6753
|
-
travelTime: travelEstimate.total,
|
|
6754
|
-
travelTimeBreakdown: travelEstimate,
|
|
6755
|
-
},
|
|
6756
|
-
destPriceMap,
|
|
6757
|
-
};
|
|
6758
|
-
}));
|
|
6759
|
-
const betterSaleLocations = betterSaleResults.sort((a, b) => Number(b.better.improvement) - Number(a.better.improvement));
|
|
6760
|
-
for (const { better, destPriceMap } of betterSaleLocations.slice(0, 2)) {
|
|
6761
|
-
const option = createTravelToSellOption(cargoValueHere, cargoCost, better, cargo, destPriceMap);
|
|
6762
|
-
collectOptions.push(option);
|
|
6763
|
-
}
|
|
6764
|
-
}
|
|
6765
|
-
if (hasCargo && dealsAtOrigin.length === 0) {
|
|
6766
|
-
const locationsToCheck = nearbyLocations.slice(0, 10);
|
|
6767
|
-
const allDealsAtDest = await Promise.all(locationsToCheck.map((destLocation) => findDealsForShip(ship, destLocation.coordinates, callbacks.getNearbyLocations, callbacks.getMarketPrices, {
|
|
6768
|
-
maxDeals: 1,
|
|
6769
|
-
maxDistance,
|
|
6770
|
-
playerBalance: antelope.UInt64.from(playerBalance).adding(cargoValueHere),
|
|
6771
|
-
availableSpace: Number(ship.maxCapacity),
|
|
6772
|
-
})));
|
|
6773
|
-
const repositionLocations = [];
|
|
6774
|
-
for (let i = 0; i < locationsToCheck.length; i++) {
|
|
6775
|
-
const destLocation = locationsToCheck[i];
|
|
6776
|
-
const dealsAtDest = allDealsAtDest[i];
|
|
6777
|
-
if (dealsAtDest.length > 0) {
|
|
6778
|
-
const distance = distanceBetweenCoordinates(arrivedAt, destLocation.coordinates);
|
|
6779
|
-
const needsRecharge = !ship.hasEnergyFor(distance);
|
|
6780
|
-
const travelEstimate = estimateTravelTime(ship, ship.totalMass, distance, {
|
|
6781
|
-
needsRecharge,
|
|
6782
|
-
unloadMass: calculateCargoMass(cargo),
|
|
6783
|
-
});
|
|
6784
|
-
repositionLocations.push({
|
|
6785
|
-
location: destLocation,
|
|
6786
|
-
bestDeal: dealsAtDest[0],
|
|
6787
|
-
distance,
|
|
6788
|
-
travelTime: travelEstimate.total,
|
|
6789
|
-
travelTimeBreakdown: travelEstimate,
|
|
6790
|
-
});
|
|
6791
|
-
}
|
|
6792
|
-
}
|
|
6793
|
-
repositionLocations.sort((a, b) => b.bestDeal.profitPerSecond - a.bestDeal.profitPerSecond);
|
|
6794
|
-
for (const reposition of repositionLocations.slice(0, 2)) {
|
|
6795
|
-
const option = createSellAndRepositionOption(cargoValueHere, cargoCost, reposition, cargoSaleHere);
|
|
6796
|
-
collectOptions.push(option);
|
|
6797
|
-
}
|
|
6798
|
-
}
|
|
6799
|
-
if (hasCargo) {
|
|
6800
|
-
const unloadTime = calculateUnloadTime(ship, cargo);
|
|
6801
|
-
const sellAndStay = createSellAndStayOption(cargoValueHere, cargoCost, cargoSaleHere, unloadTime);
|
|
6802
|
-
collectOptions.push(sellAndStay);
|
|
6803
|
-
}
|
|
6804
|
-
if (!hasCargo && dealsAtOrigin.length > 0) {
|
|
6805
|
-
for (const deal of dealsAtOrigin.slice(0, 3)) {
|
|
6806
|
-
const option = {
|
|
6807
|
-
id: `trade-${deal.destination.coordinates.x}-${deal.destination.coordinates.y}-${deal.item.id}`,
|
|
6808
|
-
type: 'sell-and-trade',
|
|
6809
|
-
title: `Trade ${deal.item.item.name}`,
|
|
6810
|
-
description: `Buy ${deal.maxQuantity} ${deal.item.item.name}, deliver to (${deal.destination.coordinates.x}, ${deal.destination.coordinates.y})`,
|
|
6811
|
-
reason: `${deal.marginPercent.toFixed(0)}% margin, ${deal.profitPerSecond.toFixed(1)}/s profit rate`,
|
|
6812
|
-
recommended: false,
|
|
6813
|
-
highestProfit: false,
|
|
6814
|
-
estimatedProfit: deal.totalProfit,
|
|
6815
|
-
purchaseCost: antelope.UInt64.from(deal.buyPrice).multiplying(deal.maxQuantity),
|
|
6816
|
-
nextTradeProfit: deal.totalProfit,
|
|
6817
|
-
profitPerSecond: deal.profitPerSecond,
|
|
6818
|
-
marginPercent: deal.marginPercent,
|
|
6819
|
-
destination: deal.destination,
|
|
6820
|
-
deal,
|
|
6821
|
-
travelTime: deal.travelTime,
|
|
6822
|
-
travelTimeBreakdown: {
|
|
6823
|
-
unloadTime: antelope.UInt32.zero,
|
|
6824
|
-
loadTime: deal.travelTimeBreakdown.loadTime,
|
|
6825
|
-
rechargeTime: deal.travelTimeBreakdown.rechargeTime,
|
|
6826
|
-
flightTime: deal.travelTimeBreakdown.flightTime,
|
|
6827
|
-
total: deal.travelTimeBreakdown.total,
|
|
6828
|
-
},
|
|
6829
|
-
};
|
|
6830
|
-
collectOptions.push(option);
|
|
6831
|
-
}
|
|
6832
|
-
}
|
|
6833
|
-
if (collectOptions.length === 0) {
|
|
6834
|
-
const gameSeed = callbacks.getGameSeed?.();
|
|
6835
|
-
const state = callbacks.getState?.();
|
|
6836
|
-
const exploreCandidates = [];
|
|
6837
|
-
for (const dest of nearbyLocations.slice(0, 10)) {
|
|
6838
|
-
const distance = distanceBetweenCoordinates(arrivedAt, dest.coordinates);
|
|
6839
|
-
const needsRecharge = !ship.hasEnergyFor(distance);
|
|
6840
|
-
const unloadMass = hasCargo ? calculateCargoMass(cargo) : antelope.UInt32.zero;
|
|
6841
|
-
const travelEstimate = estimateTravelTime(ship, ship.totalMass, distance, {
|
|
6842
|
-
needsRecharge,
|
|
6843
|
-
unloadMass,
|
|
6844
|
-
});
|
|
6845
|
-
let discountedGood;
|
|
6846
|
-
let bestDiscount = 0;
|
|
6847
|
-
if (gameSeed && state) {
|
|
6848
|
-
const allGoods = getItems();
|
|
6849
|
-
for (const good of allGoods) {
|
|
6850
|
-
const rarity = getRarity(gameSeed, state.seed, dest.coordinates, good.id);
|
|
6851
|
-
if (rarity.minMultiplier < 1.0) {
|
|
6852
|
-
const discountPercent = Math.round((1 - rarity.minMultiplier) * 100);
|
|
6853
|
-
if (discountPercent > bestDiscount) {
|
|
6854
|
-
bestDiscount = discountPercent;
|
|
6855
|
-
const rarityName = rarity.rarity === exports.Rarities.legendary
|
|
6856
|
-
? 'Legendary'
|
|
6857
|
-
: rarity.rarity === exports.Rarities.epic
|
|
6858
|
-
? 'Epic'
|
|
6859
|
-
: rarity.rarity === exports.Rarities.rare
|
|
6860
|
-
? 'Rare'
|
|
6861
|
-
: rarity.rarity === exports.Rarities.uncommon
|
|
6862
|
-
? 'Uncommon'
|
|
6863
|
-
: 'Common';
|
|
6864
|
-
discountedGood = {
|
|
6865
|
-
goodId: Number(good.id),
|
|
6866
|
-
name: good.name,
|
|
6867
|
-
rarity: rarityName,
|
|
6868
|
-
discountPercent,
|
|
6869
|
-
};
|
|
6870
|
-
}
|
|
6871
|
-
}
|
|
6872
|
-
}
|
|
6873
|
-
}
|
|
6874
|
-
const destDeals = await findDealsForShip(ship, dest.coordinates, callbacks.getNearbyLocations, callbacks.getMarketPrices, { maxDeals: 2 });
|
|
6875
|
-
const potentialDeals = destDeals.map((d) => ({
|
|
6876
|
-
goodId: Number(d.item.id),
|
|
6877
|
-
goodName: d.item.item.name,
|
|
6878
|
-
destinationCoords: d.destination.coordinates,
|
|
6879
|
-
marginPercent: d.marginPercent,
|
|
6880
|
-
profitPerSecond: d.profitPerSecond,
|
|
6881
|
-
}));
|
|
6882
|
-
let score = 0;
|
|
6883
|
-
if (potentialDeals.length > 0) {
|
|
6884
|
-
score = potentialDeals[0].profitPerSecond;
|
|
6885
|
-
}
|
|
6886
|
-
else if (bestDiscount > 0) {
|
|
6887
|
-
score = bestDiscount * 0.01;
|
|
6888
|
-
}
|
|
6889
|
-
exploreCandidates.push({
|
|
6890
|
-
dest,
|
|
6891
|
-
travelTime: travelEstimate.total,
|
|
6892
|
-
travelTimeBreakdown: travelEstimate,
|
|
6893
|
-
discountedGood,
|
|
6894
|
-
bestDiscount,
|
|
6895
|
-
potentialDeals: potentialDeals.length > 0 ? potentialDeals : undefined,
|
|
6896
|
-
score,
|
|
6897
|
-
});
|
|
6898
|
-
}
|
|
6899
|
-
exploreCandidates.sort((a, b) => b.score - a.score);
|
|
6900
|
-
for (const candidate of exploreCandidates.slice(0, 3)) {
|
|
6901
|
-
const option = createExploreOption(candidate.dest, candidate.travelTime, candidate.discountedGood, candidate.travelTimeBreakdown, candidate.potentialDeals);
|
|
6902
|
-
collectOptions.push(option);
|
|
6903
|
-
}
|
|
6904
|
-
}
|
|
6905
|
-
const orbitOption = createOrbitOption();
|
|
6906
|
-
collectOptions.push(orbitOption);
|
|
6907
|
-
const MIN_MARGIN_THRESHOLD = 15;
|
|
6908
|
-
const MIN_PROFIT_PER_SECOND_THRESHOLD = 0.5;
|
|
6909
|
-
collectOptions.sort((a, b) => (b.profitPerSecond ?? 0) - (a.profitPerSecond ?? 0));
|
|
6910
|
-
if (collectOptions.length > 0) {
|
|
6911
|
-
const bestByProfitPerSecond = collectOptions[0];
|
|
6912
|
-
const meetsQualityThreshold = (bestByProfitPerSecond.marginPercent ?? 0) > MIN_MARGIN_THRESHOLD ||
|
|
6913
|
-
(bestByProfitPerSecond.profitPerSecond ?? 0) > MIN_PROFIT_PER_SECOND_THRESHOLD;
|
|
6914
|
-
if (meetsQualityThreshold) {
|
|
6915
|
-
bestByProfitPerSecond.recommended = true;
|
|
6916
|
-
}
|
|
6917
|
-
const bestByProfit = collectOptions.reduce((best, opt) => opt.estimatedProfit > best.estimatedProfit ? opt : best);
|
|
6918
|
-
if (bestByProfit.id !== bestByProfitPerSecond.id || !meetsQualityThreshold) {
|
|
6919
|
-
bestByProfit.highestProfit = true;
|
|
6920
|
-
}
|
|
6921
|
-
}
|
|
6922
|
-
return {
|
|
6923
|
-
arrivedAt,
|
|
6924
|
-
ship,
|
|
6925
|
-
cargo,
|
|
6926
|
-
cargoValueHere,
|
|
6927
|
-
options: collectOptions,
|
|
6928
|
-
hasProfitableOptions: collectOptions.some((o) => o.estimatedProfit.gt(antelope.UInt64.zero)),
|
|
6929
|
-
};
|
|
6930
|
-
}
|
|
6931
|
-
|
|
6932
|
-
class TradesManager extends BaseManager {
|
|
6933
|
-
constructor() {
|
|
6934
|
-
super(...arguments);
|
|
6935
|
-
this.priceCache = new Map();
|
|
6936
|
-
}
|
|
6937
|
-
makePriceCacheKey(location) {
|
|
6938
|
-
return `${location.x},${location.y}`;
|
|
6939
|
-
}
|
|
6940
|
-
async createCallbacks() {
|
|
6941
|
-
const game = await this.getGame();
|
|
6942
|
-
const serverState = await this.getState();
|
|
6943
|
-
const currentEpoch = getCurrentEpoch(game);
|
|
6944
|
-
if (!this.priceCacheEpoch || !this.priceCacheEpoch.equals(currentEpoch)) {
|
|
6945
|
-
this.priceCache.clear();
|
|
6946
|
-
this.priceCacheEpoch = currentEpoch;
|
|
6947
|
-
}
|
|
6948
|
-
const getNearbyLocations = async (origin, maxDistance) => {
|
|
6949
|
-
const nearby = findNearbyPlanets(game.config.seed, origin, maxDistance);
|
|
6950
|
-
return nearby.map((d) => toLocation(d.destination));
|
|
6951
|
-
};
|
|
6952
|
-
const getMarketPrices = async (location) => {
|
|
6953
|
-
const cacheKey = this.makePriceCacheKey(location);
|
|
6954
|
-
const cached = this.priceCache.get(cacheKey);
|
|
6955
|
-
if (cached) {
|
|
6956
|
-
return cached;
|
|
6957
|
-
}
|
|
6958
|
-
const locationWithSupply = await this.context.locations.getLocationComplete(location);
|
|
6959
|
-
const prices = locationWithSupply.marketPrices || [];
|
|
6960
|
-
const result = prices.map((price) => {
|
|
6961
|
-
const actualSupply = locationWithSupply.getSupply(price.id);
|
|
6962
|
-
if (actualSupply !== undefined) {
|
|
6963
|
-
return exports.ItemPrice.from({
|
|
6964
|
-
id: price.id,
|
|
6965
|
-
item: price.item,
|
|
6966
|
-
price: price.price,
|
|
6967
|
-
supply: actualSupply,
|
|
6968
|
-
});
|
|
6969
|
-
}
|
|
6970
|
-
return price;
|
|
6971
|
-
});
|
|
6972
|
-
this.priceCache.set(cacheKey, result);
|
|
6973
|
-
return result;
|
|
6974
|
-
};
|
|
6975
|
-
const getGameSeed = () => game.config.seed;
|
|
6976
|
-
const getState = () => serverState;
|
|
6977
|
-
return { getNearbyLocations, getMarketPrices, getGameSeed, getState };
|
|
6978
|
-
}
|
|
6979
|
-
clearPriceCache() {
|
|
6980
|
-
this.priceCache.clear();
|
|
6981
|
-
this.priceCacheEpoch = undefined;
|
|
6982
|
-
}
|
|
6983
|
-
async findDeals(ship, originLocation, options = {}) {
|
|
6984
|
-
const origin = originLocation || Coordinates.from(ship.coordinates);
|
|
6985
|
-
const callbacks = await this.createCallbacks();
|
|
6986
|
-
const deals = await findDealsForShip(ship, origin, callbacks.getNearbyLocations, callbacks.getMarketPrices, options);
|
|
6987
|
-
return deals;
|
|
6988
|
-
}
|
|
6989
|
-
async findBestDeal(ship, originLocation, options = {}) {
|
|
6990
|
-
const deals = await this.findDeals(ship, originLocation, { ...options, maxDeals: 1 });
|
|
6991
|
-
return deals[0];
|
|
6992
|
-
}
|
|
6993
|
-
async getCollectOptions(ship, arrivedAt, options = {}) {
|
|
6994
|
-
const location = arrivedAt || Coordinates.from(ship.coordinates);
|
|
6995
|
-
const callbacks = await this.createCallbacks();
|
|
6996
|
-
return analyzeCollectOptions(ship, location, callbacks, options);
|
|
6997
|
-
}
|
|
6998
|
-
}
|
|
6999
|
-
|
|
7000
|
-
class EpochsManager extends BaseManager {
|
|
7001
|
-
async getCurrentHeight() {
|
|
7002
|
-
const game = await this.getGame();
|
|
7003
|
-
return getCurrentEpoch(game);
|
|
7004
|
-
}
|
|
7005
|
-
async getCurrent() {
|
|
7006
|
-
const game = await this.getGame();
|
|
7007
|
-
const epoch = await this.getCurrentHeight();
|
|
7008
|
-
return getEpochInfo(game, epoch);
|
|
7009
|
-
}
|
|
7010
|
-
async getByHeight(height) {
|
|
7011
|
-
const game = await this.getGame();
|
|
7012
|
-
return getEpochInfo(game, antelope.UInt64.from(height));
|
|
7013
|
-
}
|
|
7014
|
-
async getTimeRemaining() {
|
|
7015
|
-
const epochInfo = await this.getCurrent();
|
|
7016
|
-
const now = Date.now();
|
|
7017
|
-
const endTime = epochInfo.end.getTime();
|
|
7018
|
-
return Math.max(0, endTime - now);
|
|
7019
|
-
}
|
|
7020
|
-
async getProgress() {
|
|
7021
|
-
const epochInfo = await this.getCurrent();
|
|
7022
|
-
const now = Date.now();
|
|
7023
|
-
const startTime = epochInfo.start.getTime();
|
|
7024
|
-
const endTime = epochInfo.end.getTime();
|
|
7025
|
-
const duration = endTime - startTime;
|
|
7026
|
-
const elapsed = now - startTime;
|
|
7027
|
-
if (elapsed <= 0)
|
|
7028
|
-
return 0;
|
|
7029
|
-
if (elapsed >= duration)
|
|
7030
|
-
return 1;
|
|
7031
|
-
return elapsed / duration;
|
|
7032
|
-
}
|
|
7033
|
-
async fitsInCurrentEpoch(durationMs) {
|
|
7034
|
-
const remaining = await this.getTimeRemaining();
|
|
7035
|
-
return durationMs <= remaining;
|
|
7036
|
-
}
|
|
7037
|
-
}
|
|
7038
|
-
|
|
7039
|
-
class ActionsManager extends BaseManager {
|
|
7040
|
-
travel(shipId, destination, recharge = true) {
|
|
7041
|
-
const x = antelope.Int64.from(destination.x);
|
|
7042
|
-
const y = antelope.Int64.from(destination.y);
|
|
7043
|
-
return this.server.action('travel', {
|
|
7044
|
-
entity_type: EntityType.SHIP,
|
|
7045
|
-
id: antelope.UInt64.from(shipId),
|
|
7046
|
-
x,
|
|
7047
|
-
y,
|
|
7048
|
-
recharge,
|
|
5705
|
+
|
|
5706
|
+
class ActionsManager extends BaseManager {
|
|
5707
|
+
travel(shipId, destination, recharge = true) {
|
|
5708
|
+
const x = antelope.Int64.from(destination.x);
|
|
5709
|
+
const y = antelope.Int64.from(destination.y);
|
|
5710
|
+
return this.server.action('travel', {
|
|
5711
|
+
entity_type: EntityType.SHIP,
|
|
5712
|
+
id: antelope.UInt64.from(shipId),
|
|
5713
|
+
x,
|
|
5714
|
+
y,
|
|
5715
|
+
recharge,
|
|
7049
5716
|
});
|
|
7050
5717
|
}
|
|
7051
5718
|
grouptravel(entities, destination, recharge = true) {
|
|
@@ -7091,54 +5758,6 @@ class ActionsManager extends BaseManager {
|
|
|
7091
5758
|
quantity: antelope.UInt32.from(quantity),
|
|
7092
5759
|
});
|
|
7093
5760
|
}
|
|
7094
|
-
buyItems(entityId, goodId, quantity, entityType = EntityType.SHIP) {
|
|
7095
|
-
return this.server.action('buyitems', {
|
|
7096
|
-
entity_type: entityType,
|
|
7097
|
-
id: antelope.UInt64.from(entityId),
|
|
7098
|
-
item_id: antelope.UInt16.from(goodId),
|
|
7099
|
-
quantity: antelope.UInt32.from(quantity),
|
|
7100
|
-
});
|
|
7101
|
-
}
|
|
7102
|
-
sellItems(entityId, goodId, quantity, entityType = EntityType.SHIP) {
|
|
7103
|
-
return this.server.action('sellitems', {
|
|
7104
|
-
entity_type: entityType,
|
|
7105
|
-
id: antelope.UInt64.from(entityId),
|
|
7106
|
-
item_id: antelope.UInt16.from(goodId),
|
|
7107
|
-
quantity: antelope.UInt32.from(quantity),
|
|
7108
|
-
});
|
|
7109
|
-
}
|
|
7110
|
-
buyShip(account, name) {
|
|
7111
|
-
return this.server.action('buyship', {
|
|
7112
|
-
account: antelope.Name.from(account),
|
|
7113
|
-
name,
|
|
7114
|
-
});
|
|
7115
|
-
}
|
|
7116
|
-
buyWarehouse(account, shipId, name) {
|
|
7117
|
-
return this.server.action('buywarehouse', {
|
|
7118
|
-
account: antelope.Name.from(account),
|
|
7119
|
-
ship_id: antelope.UInt64.from(shipId),
|
|
7120
|
-
name,
|
|
7121
|
-
});
|
|
7122
|
-
}
|
|
7123
|
-
buyContainer(account, shipId, name) {
|
|
7124
|
-
return this.server.action('buycontainer', {
|
|
7125
|
-
account: antelope.Name.from(account),
|
|
7126
|
-
ship_id: antelope.UInt64.from(shipId),
|
|
7127
|
-
name,
|
|
7128
|
-
});
|
|
7129
|
-
}
|
|
7130
|
-
takeLoan(account, amount) {
|
|
7131
|
-
return this.server.action('takeloan', {
|
|
7132
|
-
account: antelope.Name.from(account),
|
|
7133
|
-
amount: antelope.UInt64.from(amount),
|
|
7134
|
-
});
|
|
7135
|
-
}
|
|
7136
|
-
payLoan(account, amount) {
|
|
7137
|
-
return this.server.action('payloan', {
|
|
7138
|
-
account: antelope.Name.from(account),
|
|
7139
|
-
amount: antelope.UInt64.from(amount),
|
|
7140
|
-
});
|
|
7141
|
-
}
|
|
7142
5761
|
foundCompany(account, name) {
|
|
7143
5762
|
return this.platform.action('foundcompany', {
|
|
7144
5763
|
account: antelope.Name.from(account),
|
|
@@ -7165,25 +5784,32 @@ class ActionsManager extends BaseManager {
|
|
|
7165
5784
|
y,
|
|
7166
5785
|
});
|
|
7167
5786
|
}
|
|
5787
|
+
craft(entityType, entityId, recipeId, quantity, inputs) {
|
|
5788
|
+
const cargoInputs = inputs.map((i) => Types.cargo_item.from({
|
|
5789
|
+
item_id: antelope.UInt16.from(i.itemId),
|
|
5790
|
+
quantity: antelope.UInt32.from(i.quantity),
|
|
5791
|
+
seed: i.seed !== undefined ? antelope.UInt64.from(i.seed) : null,
|
|
5792
|
+
}));
|
|
5793
|
+
return this.server.action('craft', {
|
|
5794
|
+
entity_type: entityType,
|
|
5795
|
+
id: antelope.UInt64.from(entityId),
|
|
5796
|
+
recipe_id: antelope.UInt16.from(recipeId),
|
|
5797
|
+
quantity: antelope.UInt32.from(quantity),
|
|
5798
|
+
inputs: cargoInputs,
|
|
5799
|
+
});
|
|
5800
|
+
}
|
|
5801
|
+
deploy(entityType, entityId, packedItemId, seed, entityName) {
|
|
5802
|
+
return this.server.action('deploy', {
|
|
5803
|
+
entity_type: entityType,
|
|
5804
|
+
id: antelope.UInt64.from(entityId),
|
|
5805
|
+
packed_item_id: antelope.UInt16.from(packedItemId),
|
|
5806
|
+
seed: antelope.UInt64.from(seed),
|
|
5807
|
+
entity_name: entityName,
|
|
5808
|
+
});
|
|
5809
|
+
}
|
|
7168
5810
|
joinGame(account, companyName) {
|
|
7169
5811
|
return [this.foundCompany(account, companyName), this.join(account)];
|
|
7170
5812
|
}
|
|
7171
|
-
sellAllCargo(ship, cargo) {
|
|
7172
|
-
let shipCargo;
|
|
7173
|
-
if (ship instanceof Ship) {
|
|
7174
|
-
shipCargo = cargo || ship.inventory;
|
|
7175
|
-
}
|
|
7176
|
-
else {
|
|
7177
|
-
if (!cargo) {
|
|
7178
|
-
throw new Error('cargo parameter required when ship is a UInt64Type');
|
|
7179
|
-
}
|
|
7180
|
-
shipCargo = cargo;
|
|
7181
|
-
}
|
|
7182
|
-
const shipId = ship instanceof Ship ? ship.id : antelope.UInt64.from(ship);
|
|
7183
|
-
return shipCargo
|
|
7184
|
-
.filter((c) => c.hasCargo)
|
|
7185
|
-
.map((c) => this.sellItems(shipId, c.item_id, c.quantity, EntityType.SHIP));
|
|
7186
|
-
}
|
|
7187
5813
|
}
|
|
7188
5814
|
|
|
7189
5815
|
class GameContext {
|
|
@@ -7210,12 +5836,6 @@ class GameContext {
|
|
|
7210
5836
|
}
|
|
7211
5837
|
return this._locations;
|
|
7212
5838
|
}
|
|
7213
|
-
get trades() {
|
|
7214
|
-
if (!this._trades) {
|
|
7215
|
-
this._trades = new TradesManager(this);
|
|
7216
|
-
}
|
|
7217
|
-
return this._trades;
|
|
7218
|
-
}
|
|
7219
5839
|
get epochs() {
|
|
7220
5840
|
if (!this._epochs) {
|
|
7221
5841
|
this._epochs = new EpochsManager(this);
|
|
@@ -7312,9 +5932,6 @@ class Shipload {
|
|
|
7312
5932
|
get locations() {
|
|
7313
5933
|
return this._context.locations;
|
|
7314
5934
|
}
|
|
7315
|
-
get trades() {
|
|
7316
|
-
return this._context.trades;
|
|
7317
|
-
}
|
|
7318
5935
|
get epochs() {
|
|
7319
5936
|
return this._context.epochs;
|
|
7320
5937
|
}
|
|
@@ -7391,137 +6008,6 @@ function makeContainer(state) {
|
|
|
7391
6008
|
return new Container(entityInfo);
|
|
7392
6009
|
}
|
|
7393
6010
|
|
|
7394
|
-
const DEPTH_THRESHOLD_COMMON = 0;
|
|
7395
|
-
const DEPTH_THRESHOLD_UNCOMMON = 2000;
|
|
7396
|
-
const DEPTH_THRESHOLD_RARE = 10000;
|
|
7397
|
-
const DEPTH_THRESHOLD_EPIC = 30000;
|
|
7398
|
-
const DEPTH_THRESHOLD_LEGENDARY = 55000;
|
|
7399
|
-
const LOCATION_MIN_DEPTH = 500;
|
|
7400
|
-
const LOCATION_MAX_DEPTH = 65535;
|
|
7401
|
-
const YIELD_THRESHOLD = Math.floor(0.003 * 0xffffffff);
|
|
7402
|
-
const PLANET_SUBTYPE_GAS_GIANT = 0;
|
|
7403
|
-
const PLANET_SUBTYPE_ROCKY = 1;
|
|
7404
|
-
const PLANET_SUBTYPE_TERRESTRIAL = 2;
|
|
7405
|
-
const PLANET_SUBTYPE_ICY = 3;
|
|
7406
|
-
const PLANET_SUBTYPE_OCEAN = 4;
|
|
7407
|
-
const PLANET_SUBTYPE_INDUSTRIAL = 5;
|
|
7408
|
-
const RESOURCE_CATALOG = [
|
|
7409
|
-
{ id: 26, rarity: 'common' },
|
|
7410
|
-
{ id: 1, rarity: 'common' },
|
|
7411
|
-
{ id: 14, rarity: 'common' },
|
|
7412
|
-
{ id: 6, rarity: 'common' },
|
|
7413
|
-
{ id: 29, rarity: 'uncommon' },
|
|
7414
|
-
{ id: 2, rarity: 'uncommon' },
|
|
7415
|
-
{ id: 1000, rarity: 'uncommon' },
|
|
7416
|
-
{ id: 1003, rarity: 'uncommon' },
|
|
7417
|
-
{ id: 22, rarity: 'rare' },
|
|
7418
|
-
{ id: 18, rarity: 'rare' },
|
|
7419
|
-
{ id: 1001, rarity: 'rare' },
|
|
7420
|
-
{ id: 1002, rarity: 'rare' },
|
|
7421
|
-
{ id: 74, rarity: 'epic' },
|
|
7422
|
-
{ id: 54, rarity: 'epic' },
|
|
7423
|
-
];
|
|
7424
|
-
function getDepthThreshold(rarity) {
|
|
7425
|
-
switch (rarity) {
|
|
7426
|
-
case 'common':
|
|
7427
|
-
return DEPTH_THRESHOLD_COMMON;
|
|
7428
|
-
case 'uncommon':
|
|
7429
|
-
return DEPTH_THRESHOLD_UNCOMMON;
|
|
7430
|
-
case 'rare':
|
|
7431
|
-
return DEPTH_THRESHOLD_RARE;
|
|
7432
|
-
case 'epic':
|
|
7433
|
-
return DEPTH_THRESHOLD_EPIC;
|
|
7434
|
-
case 'legendary':
|
|
7435
|
-
return DEPTH_THRESHOLD_LEGENDARY;
|
|
7436
|
-
}
|
|
7437
|
-
}
|
|
7438
|
-
function getResourceRarity(itemId) {
|
|
7439
|
-
const entry = RESOURCE_CATALOG.find((r) => r.id === itemId);
|
|
7440
|
-
return entry ? entry.rarity : 'legendary';
|
|
7441
|
-
}
|
|
7442
|
-
function getResourceWeight(itemId, stratum) {
|
|
7443
|
-
const rarity = getResourceRarity(itemId);
|
|
7444
|
-
const threshold = getDepthThreshold(rarity);
|
|
7445
|
-
if (stratum < threshold)
|
|
7446
|
-
return 0;
|
|
7447
|
-
const depthAbove = stratum - threshold;
|
|
7448
|
-
switch (rarity) {
|
|
7449
|
-
case 'common':
|
|
7450
|
-
if (stratum < 2000)
|
|
7451
|
-
return 100;
|
|
7452
|
-
if (stratum < 10000)
|
|
7453
|
-
return 80;
|
|
7454
|
-
if (stratum < 30000)
|
|
7455
|
-
return 50;
|
|
7456
|
-
return 30;
|
|
7457
|
-
case 'uncommon':
|
|
7458
|
-
if (depthAbove < 3000)
|
|
7459
|
-
return 40;
|
|
7460
|
-
if (depthAbove < 8000)
|
|
7461
|
-
return 60;
|
|
7462
|
-
return 50;
|
|
7463
|
-
case 'rare':
|
|
7464
|
-
if (depthAbove < 5000)
|
|
7465
|
-
return 20;
|
|
7466
|
-
if (depthAbove < 15000)
|
|
7467
|
-
return 35;
|
|
7468
|
-
return 40;
|
|
7469
|
-
case 'epic':
|
|
7470
|
-
if (depthAbove < 10000)
|
|
7471
|
-
return 10;
|
|
7472
|
-
if (depthAbove < 25000)
|
|
7473
|
-
return 20;
|
|
7474
|
-
return 30;
|
|
7475
|
-
case 'legendary':
|
|
7476
|
-
return 10;
|
|
7477
|
-
}
|
|
7478
|
-
}
|
|
7479
|
-
const ASTEROID_RESOURCES = [26, 29, 22, 74, 14, 1000, 1001];
|
|
7480
|
-
const NEBULA_RESOURCES = [1, 2, 18, 54];
|
|
7481
|
-
const GAS_GIANT_RESOURCES = [1, 2, 18, 54];
|
|
7482
|
-
const ROCKY_RESOURCES = [26, 29, 22, 74, 6, 1003, 1002];
|
|
7483
|
-
const TERRESTRIAL_RESOURCES = [6, 1003, 1002, 1001];
|
|
7484
|
-
const ICY_RESOURCES = [6, 14, 1000, 1001, 18];
|
|
7485
|
-
const OCEAN_RESOURCES = [1, 2, 1003, 1002];
|
|
7486
|
-
const INDUSTRIAL_RESOURCES = [26, 29, 22, 74, 14, 1000, 54];
|
|
7487
|
-
function getLocationCandidates(locationType, subtype) {
|
|
7488
|
-
if (locationType === 2)
|
|
7489
|
-
return ASTEROID_RESOURCES;
|
|
7490
|
-
if (locationType === 3)
|
|
7491
|
-
return NEBULA_RESOURCES;
|
|
7492
|
-
if (locationType === 1) {
|
|
7493
|
-
switch (subtype) {
|
|
7494
|
-
case PLANET_SUBTYPE_GAS_GIANT:
|
|
7495
|
-
return GAS_GIANT_RESOURCES;
|
|
7496
|
-
case PLANET_SUBTYPE_ROCKY:
|
|
7497
|
-
return ROCKY_RESOURCES;
|
|
7498
|
-
case PLANET_SUBTYPE_TERRESTRIAL:
|
|
7499
|
-
return TERRESTRIAL_RESOURCES;
|
|
7500
|
-
case PLANET_SUBTYPE_ICY:
|
|
7501
|
-
return ICY_RESOURCES;
|
|
7502
|
-
case PLANET_SUBTYPE_OCEAN:
|
|
7503
|
-
return OCEAN_RESOURCES;
|
|
7504
|
-
case PLANET_SUBTYPE_INDUSTRIAL:
|
|
7505
|
-
return INDUSTRIAL_RESOURCES;
|
|
7506
|
-
}
|
|
7507
|
-
}
|
|
7508
|
-
return [];
|
|
7509
|
-
}
|
|
7510
|
-
function getEligibleResources(locationType, subtype, stratum) {
|
|
7511
|
-
const candidates = getLocationCandidates(locationType, subtype);
|
|
7512
|
-
return candidates.filter((itemId) => {
|
|
7513
|
-
const rarity = getResourceRarity(itemId);
|
|
7514
|
-
const threshold = getDepthThreshold(rarity);
|
|
7515
|
-
return stratum >= threshold;
|
|
7516
|
-
});
|
|
7517
|
-
}
|
|
7518
|
-
function depthScaleFactor(stratum) {
|
|
7519
|
-
if (stratum <= 1)
|
|
7520
|
-
return 1.0;
|
|
7521
|
-
const logScale = Math.log(stratum) / Math.log(65535);
|
|
7522
|
-
return 1.0 + logScale * 2.0;
|
|
7523
|
-
}
|
|
7524
|
-
|
|
7525
6011
|
function deriveStratum(epochSeed, coords, stratum, locationType, subtype, _maxDepth) {
|
|
7526
6012
|
const seed = antelope.Checksum256.from(epochSeed);
|
|
7527
6013
|
const c = Coordinates.from(coords);
|
|
@@ -7570,19 +6056,21 @@ function deriveStratum(epochSeed, coords, stratum, locationType, subtype, _maxDe
|
|
|
7570
6056
|
const baseRichness = Math.floor(normalized * normalized * 999) + 1;
|
|
7571
6057
|
let depthBonus = 0;
|
|
7572
6058
|
if (stratum > 1) {
|
|
7573
|
-
depthBonus = 50 * Math.log(stratum) / Math.log(65535);
|
|
6059
|
+
depthBonus = (50 * Math.log(stratum)) / Math.log(65535);
|
|
7574
6060
|
}
|
|
7575
6061
|
const richness = Math.min(Math.floor(baseRichness + depthBonus), 1000);
|
|
7576
6062
|
return { itemId: selectedItemId, seed: seedBigInt, richness, reserve };
|
|
7577
6063
|
}
|
|
7578
6064
|
function deriveResourceStats(seed) {
|
|
7579
|
-
const
|
|
7580
|
-
|
|
7581
|
-
|
|
7582
|
-
|
|
6065
|
+
const seedBytes = new Uint8Array(8);
|
|
6066
|
+
for (let i = 7; i >= 0; i--) {
|
|
6067
|
+
seedBytes[i] = Number(seed & 0xffn);
|
|
6068
|
+
seed >>= 8n;
|
|
6069
|
+
}
|
|
6070
|
+
const hashResult = antelope.Checksum256.hash(antelope.Bytes.from(seedBytes));
|
|
7583
6071
|
const hashBytes = hashResult.array;
|
|
7584
6072
|
const extractU16 = (offset) => (hashBytes[offset] << 8) | hashBytes[offset + 1];
|
|
7585
|
-
const
|
|
6073
|
+
const weibull = (raw) => {
|
|
7586
6074
|
const u = raw / 65536;
|
|
7587
6075
|
let x = 0.27 * Math.sqrt(-Math.log(1 - u));
|
|
7588
6076
|
if (x > 1)
|
|
@@ -7590,22 +6078,357 @@ function deriveResourceStats(seed) {
|
|
|
7590
6078
|
return Math.floor(x * 999) + 1;
|
|
7591
6079
|
};
|
|
7592
6080
|
return {
|
|
7593
|
-
|
|
7594
|
-
|
|
7595
|
-
|
|
7596
|
-
resonance: weibullStat(extractU16(6)),
|
|
6081
|
+
stat1: weibull(extractU16(0)),
|
|
6082
|
+
stat2: weibull(extractU16(2)),
|
|
6083
|
+
stat3: weibull(extractU16(4)),
|
|
7597
6084
|
};
|
|
7598
6085
|
}
|
|
7599
6086
|
|
|
7600
|
-
|
|
7601
|
-
|
|
6087
|
+
const METAL_STATS = [
|
|
6088
|
+
{
|
|
6089
|
+
key: 'strength',
|
|
6090
|
+
label: 'Strength',
|
|
6091
|
+
abbreviation: 'STR',
|
|
6092
|
+
purpose: 'Raw structural/mechanical force',
|
|
6093
|
+
},
|
|
6094
|
+
{
|
|
6095
|
+
key: 'tolerance',
|
|
6096
|
+
label: 'Tolerance',
|
|
6097
|
+
abbreviation: 'TOL',
|
|
6098
|
+
purpose: 'Ability to withstand heat, pressure, and stress extremes',
|
|
6099
|
+
},
|
|
6100
|
+
{
|
|
6101
|
+
key: 'density',
|
|
6102
|
+
label: 'Density',
|
|
6103
|
+
abbreviation: 'DEN',
|
|
6104
|
+
purpose: 'Mass per unit',
|
|
6105
|
+
inverted: true,
|
|
6106
|
+
},
|
|
6107
|
+
];
|
|
6108
|
+
const PRECIOUS_STATS = [
|
|
6109
|
+
{
|
|
6110
|
+
key: 'conductivity',
|
|
6111
|
+
label: 'Conductivity',
|
|
6112
|
+
abbreviation: 'CON',
|
|
6113
|
+
purpose: 'Efficiency of energy/signal transfer',
|
|
6114
|
+
},
|
|
6115
|
+
{
|
|
6116
|
+
key: 'ductility',
|
|
6117
|
+
label: 'Ductility',
|
|
6118
|
+
abbreviation: 'DUC',
|
|
6119
|
+
purpose: 'Ability to be worked into fine, precise shapes',
|
|
6120
|
+
},
|
|
6121
|
+
{
|
|
6122
|
+
key: 'reflectivity',
|
|
6123
|
+
label: 'Reflectivity',
|
|
6124
|
+
abbreviation: 'REF',
|
|
6125
|
+
purpose: 'Surface quality for heat management and precision optics',
|
|
6126
|
+
},
|
|
6127
|
+
];
|
|
6128
|
+
const GAS_STATS = [
|
|
6129
|
+
{
|
|
6130
|
+
key: 'volatility',
|
|
6131
|
+
label: 'Volatility',
|
|
6132
|
+
abbreviation: 'VOL',
|
|
6133
|
+
purpose: 'Energy release potential for propulsion and force',
|
|
6134
|
+
},
|
|
6135
|
+
{
|
|
6136
|
+
key: 'reactivity',
|
|
6137
|
+
label: 'Reactivity',
|
|
6138
|
+
abbreviation: 'REA',
|
|
6139
|
+
purpose: 'Chemical interaction speed for processing and penetration',
|
|
6140
|
+
},
|
|
6141
|
+
{
|
|
6142
|
+
key: 'thermal',
|
|
6143
|
+
label: 'Thermal',
|
|
6144
|
+
abbreviation: 'THM',
|
|
6145
|
+
purpose: 'Heat capacity for thermal management',
|
|
6146
|
+
},
|
|
6147
|
+
];
|
|
6148
|
+
const MINERAL_STATS = [
|
|
6149
|
+
{
|
|
6150
|
+
key: 'resonance',
|
|
6151
|
+
label: 'Resonance',
|
|
6152
|
+
abbreviation: 'RES',
|
|
6153
|
+
purpose: 'Energy field interaction — storage, focusing, projection',
|
|
6154
|
+
},
|
|
6155
|
+
{
|
|
6156
|
+
key: 'hardness',
|
|
6157
|
+
label: 'Hardness',
|
|
6158
|
+
abbreviation: 'HRD',
|
|
6159
|
+
purpose: 'Resistance to wear — cutting surfaces, penetration',
|
|
6160
|
+
},
|
|
6161
|
+
{
|
|
6162
|
+
key: 'clarity',
|
|
6163
|
+
label: 'Clarity',
|
|
6164
|
+
abbreviation: 'CLR',
|
|
6165
|
+
purpose: 'Crystalline perfection — precision optics',
|
|
6166
|
+
},
|
|
6167
|
+
];
|
|
6168
|
+
const ORGANIC_STATS = [
|
|
6169
|
+
{
|
|
6170
|
+
key: 'plasticity',
|
|
6171
|
+
label: 'Plasticity',
|
|
6172
|
+
abbreviation: 'PLA',
|
|
6173
|
+
purpose: 'Ease of reshaping — speeds processing',
|
|
6174
|
+
},
|
|
6175
|
+
{
|
|
6176
|
+
key: 'insulation',
|
|
6177
|
+
label: 'Insulation',
|
|
6178
|
+
abbreviation: 'INS',
|
|
6179
|
+
purpose: 'Energy containment — reduces energy loss',
|
|
6180
|
+
},
|
|
6181
|
+
{
|
|
6182
|
+
key: 'purity',
|
|
6183
|
+
label: 'Purity',
|
|
6184
|
+
abbreviation: 'PUR',
|
|
6185
|
+
purpose: 'Biological cleanliness — better composites and lubricants',
|
|
6186
|
+
},
|
|
6187
|
+
];
|
|
6188
|
+
const STAT_MAP = {
|
|
6189
|
+
metal: METAL_STATS,
|
|
6190
|
+
precious: PRECIOUS_STATS,
|
|
6191
|
+
gas: GAS_STATS,
|
|
6192
|
+
mineral: MINERAL_STATS,
|
|
6193
|
+
organic: ORGANIC_STATS,
|
|
6194
|
+
};
|
|
6195
|
+
function getStatDefinitions(category) {
|
|
6196
|
+
return STAT_MAP[category];
|
|
6197
|
+
}
|
|
6198
|
+
function getStatName(category, index) {
|
|
6199
|
+
return STAT_MAP[category][index];
|
|
6200
|
+
}
|
|
6201
|
+
function resolveStats(category, stats) {
|
|
6202
|
+
return {
|
|
6203
|
+
definitions: STAT_MAP[category],
|
|
6204
|
+
values: [stats.stat1, stats.stat2, stats.stat3],
|
|
6205
|
+
};
|
|
6206
|
+
}
|
|
6207
|
+
|
|
6208
|
+
const ITEM_HULL_PLATES = 10001;
|
|
6209
|
+
const ITEM_CARGO_LINING = 10002;
|
|
6210
|
+
const ITEM_CONTAINER_PACKED = 10003;
|
|
6211
|
+
const components = [
|
|
6212
|
+
{
|
|
6213
|
+
id: ITEM_HULL_PLATES,
|
|
6214
|
+
name: 'Hull Plates',
|
|
6215
|
+
description: 'Structural plating formed from metal. Used in hulls, containers, and frames.',
|
|
6216
|
+
color: '#7B8D9E',
|
|
6217
|
+
mass: 50000,
|
|
6218
|
+
stats: [
|
|
6219
|
+
{ key: 'strength', source: 'metal' },
|
|
6220
|
+
{ key: 'density', source: 'metal' },
|
|
6221
|
+
],
|
|
6222
|
+
recipe: [{ category: 'metal', quantity: 40 }],
|
|
6223
|
+
usedIn: [{ type: 'entity', name: 'Container' }],
|
|
6224
|
+
},
|
|
6225
|
+
{
|
|
6226
|
+
id: ITEM_CARGO_LINING,
|
|
6227
|
+
name: 'Cargo Lining',
|
|
6228
|
+
description: 'Precision-formed composite lining for cargo storage. Combines precious metal shaping with organic sealing.',
|
|
6229
|
+
color: '#D4A843',
|
|
6230
|
+
mass: 30000,
|
|
6231
|
+
stats: [
|
|
6232
|
+
{ key: 'ductility', source: 'precious' },
|
|
6233
|
+
{ key: 'purity', source: 'organic' },
|
|
6234
|
+
],
|
|
6235
|
+
recipe: [
|
|
6236
|
+
{ category: 'precious', quantity: 10 },
|
|
6237
|
+
{ category: 'organic', quantity: 20 },
|
|
6238
|
+
],
|
|
6239
|
+
usedIn: [{ type: 'entity', name: 'Container' }],
|
|
6240
|
+
},
|
|
6241
|
+
];
|
|
6242
|
+
const entityRecipes = [
|
|
6243
|
+
{
|
|
6244
|
+
id: 'container',
|
|
6245
|
+
name: 'Container',
|
|
6246
|
+
description: 'Passive floating cargo storage in space. Towed by ships.',
|
|
6247
|
+
color: '#7B8D9E',
|
|
6248
|
+
packedItemId: ITEM_CONTAINER_PACKED,
|
|
6249
|
+
recipe: [
|
|
6250
|
+
{ itemId: ITEM_HULL_PLATES, quantity: 6 },
|
|
6251
|
+
{ itemId: ITEM_CARGO_LINING, quantity: 2 },
|
|
6252
|
+
],
|
|
6253
|
+
stats: [
|
|
6254
|
+
{ key: 'strength', sourceComponentId: ITEM_HULL_PLATES, sourceStatKey: 'strength' },
|
|
6255
|
+
{ key: 'density', sourceComponentId: ITEM_HULL_PLATES, sourceStatKey: 'density' },
|
|
6256
|
+
{ key: 'ductility', sourceComponentId: ITEM_CARGO_LINING, sourceStatKey: 'ductility' },
|
|
6257
|
+
{ key: 'purity', sourceComponentId: ITEM_CARGO_LINING, sourceStatKey: 'purity' },
|
|
6258
|
+
],
|
|
6259
|
+
},
|
|
6260
|
+
];
|
|
6261
|
+
function getComponentById(id) {
|
|
6262
|
+
return components.find((c) => c.id === id);
|
|
6263
|
+
}
|
|
6264
|
+
function getEntityRecipe(id) {
|
|
6265
|
+
return entityRecipes.find((r) => r.id === id);
|
|
6266
|
+
}
|
|
6267
|
+
function getEntityRecipeByItemId(itemId) {
|
|
6268
|
+
return entityRecipes.find((r) => r.packedItemId === itemId);
|
|
6269
|
+
}
|
|
6270
|
+
function getAllCraftableItems() {
|
|
6271
|
+
const items = [];
|
|
6272
|
+
for (const comp of components) {
|
|
6273
|
+
items.push({ type: 'component', id: comp.id, name: comp.name, description: comp.description, color: comp.color });
|
|
6274
|
+
}
|
|
6275
|
+
for (const entity of entityRecipes) {
|
|
6276
|
+
items.push({ type: 'entity', id: entity.id, name: entity.name, description: entity.description, color: entity.color });
|
|
6277
|
+
}
|
|
6278
|
+
return items;
|
|
6279
|
+
}
|
|
6280
|
+
function getComponentsForCategory(category) {
|
|
6281
|
+
return components.filter((c) => c.recipe.some((r) => r.category === category));
|
|
6282
|
+
}
|
|
6283
|
+
function getComponentsForStat(statKey) {
|
|
6284
|
+
return components.filter((c) => c.stats.some((s) => s.key === statKey));
|
|
6285
|
+
}
|
|
6286
|
+
|
|
6287
|
+
function encodeStats(values) {
|
|
6288
|
+
let seed = 0n;
|
|
6289
|
+
for (let i = 0; i < values.length && i < 6; i++) {
|
|
6290
|
+
seed |= BigInt(values[i] & 0x3ff) << BigInt(i * 10);
|
|
6291
|
+
}
|
|
6292
|
+
return seed;
|
|
6293
|
+
}
|
|
6294
|
+
function decodeStats(seed, count) {
|
|
6295
|
+
const stats = [];
|
|
6296
|
+
for (let i = 0; i < count; i++) {
|
|
6297
|
+
stats.push(Number((seed >> BigInt(i * 10)) & 0x3ffn));
|
|
6298
|
+
}
|
|
6299
|
+
return stats;
|
|
6300
|
+
}
|
|
6301
|
+
function decodeCraftedItemStats(itemId, seed) {
|
|
6302
|
+
const comp = getComponentById(itemId);
|
|
6303
|
+
if (comp) {
|
|
6304
|
+
const values = decodeStats(seed, comp.stats.length);
|
|
6305
|
+
const result = {};
|
|
6306
|
+
for (let i = 0; i < comp.stats.length; i++) {
|
|
6307
|
+
result[comp.stats[i].key] = values[i];
|
|
6308
|
+
}
|
|
6309
|
+
return result;
|
|
6310
|
+
}
|
|
6311
|
+
const entityRecipe = entityRecipes.find((r) => r.packedItemId === itemId);
|
|
6312
|
+
if (entityRecipe) {
|
|
6313
|
+
const values = decodeStats(seed, entityRecipe.stats.length);
|
|
6314
|
+
const result = {};
|
|
6315
|
+
for (let i = 0; i < entityRecipe.stats.length; i++) {
|
|
6316
|
+
result[entityRecipe.stats[i].key] = values[i];
|
|
6317
|
+
}
|
|
6318
|
+
return result;
|
|
6319
|
+
}
|
|
6320
|
+
return {};
|
|
6321
|
+
}
|
|
6322
|
+
function blendStacks(stacks, statKey) {
|
|
6323
|
+
let totalQty = 0;
|
|
6324
|
+
let weightedSum = 0;
|
|
6325
|
+
for (const stack of stacks) {
|
|
6326
|
+
const val = stack.stats[statKey] ?? 0;
|
|
6327
|
+
weightedSum += val * stack.quantity;
|
|
6328
|
+
totalQty += stack.quantity;
|
|
6329
|
+
}
|
|
6330
|
+
if (totalQty === 0)
|
|
7602
6331
|
return 0;
|
|
7603
|
-
|
|
7604
|
-
|
|
7605
|
-
|
|
7606
|
-
const
|
|
7607
|
-
|
|
6332
|
+
return Math.round(weightedSum / totalQty);
|
|
6333
|
+
}
|
|
6334
|
+
function computeComponentStats(componentId, categoryStacks) {
|
|
6335
|
+
const comp = getComponentById(componentId);
|
|
6336
|
+
if (!comp)
|
|
6337
|
+
return [];
|
|
6338
|
+
return comp.stats.map((statDef) => {
|
|
6339
|
+
const matching = categoryStacks.find((cs) => cs.category === statDef.source);
|
|
6340
|
+
const value = matching ? blendStacks(matching.stacks, statDef.key) : 0;
|
|
6341
|
+
return { key: statDef.key, value: Math.max(1, Math.min(999, value)) };
|
|
6342
|
+
});
|
|
6343
|
+
}
|
|
6344
|
+
function blendComponentStacks(stacks) {
|
|
6345
|
+
if (stacks.length === 0)
|
|
6346
|
+
return {};
|
|
6347
|
+
const allKeys = new Set();
|
|
6348
|
+
for (const s of stacks) {
|
|
6349
|
+
for (const k of Object.keys(s.stats))
|
|
6350
|
+
allKeys.add(k);
|
|
6351
|
+
}
|
|
6352
|
+
const result = {};
|
|
6353
|
+
for (const key of allKeys) {
|
|
6354
|
+
result[key] = blendStacks(stacks.map((s) => ({ quantity: s.quantity, stats: s.stats })), key);
|
|
6355
|
+
}
|
|
6356
|
+
return result;
|
|
6357
|
+
}
|
|
6358
|
+
function computeEntityStats(entityRecipeId, componentStacks) {
|
|
6359
|
+
const recipe = getEntityRecipe(entityRecipeId);
|
|
6360
|
+
if (!recipe)
|
|
6361
|
+
return [];
|
|
6362
|
+
const blendedByComponent = {};
|
|
6363
|
+
for (const [compId, stacks] of Object.entries(componentStacks)) {
|
|
6364
|
+
blendedByComponent[Number(compId)] = blendComponentStacks(stacks);
|
|
6365
|
+
}
|
|
6366
|
+
return recipe.stats.map((stat) => {
|
|
6367
|
+
const blended = blendedByComponent[stat.sourceComponentId] ?? {};
|
|
6368
|
+
const value = blended[stat.sourceStatKey] ?? 0;
|
|
6369
|
+
return { key: stat.key, value: Math.max(1, Math.min(999, value)) };
|
|
6370
|
+
});
|
|
6371
|
+
}
|
|
6372
|
+
|
|
6373
|
+
function totalCargoMass(cargo) {
|
|
6374
|
+
return cargo.reduce((sum, c) => {
|
|
6375
|
+
return sum.adding(c.totalMass);
|
|
6376
|
+
}, antelope.UInt64.from(0));
|
|
6377
|
+
}
|
|
6378
|
+
function getCargoForItem(cargo, goodId) {
|
|
6379
|
+
return cargo.find((c) => c.item_id.equals(goodId));
|
|
6380
|
+
}
|
|
6381
|
+
function hasSpace(currentMass, maxCapacity, goodMass, quantity) {
|
|
6382
|
+
const additionalMass = goodMass.multiplying(quantity);
|
|
6383
|
+
const totalMass = currentMass.adding(additionalMass);
|
|
6384
|
+
return totalMass.lte(maxCapacity);
|
|
6385
|
+
}
|
|
6386
|
+
function availableCapacity(currentMass, maxCapacity) {
|
|
6387
|
+
if (currentMass.gte(maxCapacity)) {
|
|
6388
|
+
return antelope.UInt64.from(0);
|
|
6389
|
+
}
|
|
6390
|
+
return maxCapacity.subtracting(currentMass);
|
|
6391
|
+
}
|
|
6392
|
+
function isFull(currentMass, maxCapacity) {
|
|
6393
|
+
return currentMass.gte(maxCapacity);
|
|
6394
|
+
}
|
|
6395
|
+
function afterRemoveItems(cargo, goodsToRemove) {
|
|
6396
|
+
if (cargo.length === 0) {
|
|
6397
|
+
return [];
|
|
6398
|
+
}
|
|
6399
|
+
return cargo.map((item) => {
|
|
6400
|
+
const removeItem = goodsToRemove.find((s) => Number(item.item_id) === s.goodId);
|
|
6401
|
+
if (!removeItem) {
|
|
6402
|
+
return new EntityInventory(item);
|
|
6403
|
+
}
|
|
6404
|
+
const currentQty = Number(item.quantity);
|
|
6405
|
+
const newQty = Math.max(0, currentQty - removeItem.quantity);
|
|
6406
|
+
return new EntityInventory(Types.cargo_item.from({
|
|
6407
|
+
item_id: item.item_id,
|
|
6408
|
+
quantity: antelope.UInt32.from(newQty),
|
|
6409
|
+
}));
|
|
6410
|
+
});
|
|
7608
6411
|
}
|
|
6412
|
+
function afterRemoveAllItems(cargo) {
|
|
6413
|
+
if (cargo.length === 0) {
|
|
6414
|
+
return [];
|
|
6415
|
+
}
|
|
6416
|
+
return cargo.map((item) => new EntityInventory(Types.cargo_item.from({
|
|
6417
|
+
item_id: item.item_id,
|
|
6418
|
+
quantity: antelope.UInt32.from(0),
|
|
6419
|
+
})));
|
|
6420
|
+
}
|
|
6421
|
+
|
|
6422
|
+
var cargoUtils = /*#__PURE__*/Object.freeze({
|
|
6423
|
+
__proto__: null,
|
|
6424
|
+
totalCargoMass: totalCargoMass,
|
|
6425
|
+
getCargoForItem: getCargoForItem,
|
|
6426
|
+
hasSpace: hasSpace,
|
|
6427
|
+
availableCapacity: availableCapacity,
|
|
6428
|
+
isFull: isFull,
|
|
6429
|
+
afterRemoveItems: afterRemoveItems,
|
|
6430
|
+
afterRemoveAllItems: afterRemoveAllItems
|
|
6431
|
+
});
|
|
7609
6432
|
|
|
7610
6433
|
function canMove(e) {
|
|
7611
6434
|
return 'engines' in e && 'generator' in e && 'energy' in e;
|
|
@@ -7619,9 +6442,6 @@ function hasStorage(e) {
|
|
|
7619
6442
|
function hasLoaders(e) {
|
|
7620
6443
|
return 'loaders' in e && e.loaders !== undefined;
|
|
7621
6444
|
}
|
|
7622
|
-
function hasTrade(e) {
|
|
7623
|
-
return 'trade' in e && e.trade !== undefined;
|
|
7624
|
-
}
|
|
7625
6445
|
function hasMass(e) {
|
|
7626
6446
|
return 'hullmass' in e;
|
|
7627
6447
|
}
|
|
@@ -7655,6 +6475,10 @@ function calc_extraction_energy(extractor, duration) {
|
|
|
7655
6475
|
return antelope.UInt16.from(energy);
|
|
7656
6476
|
}
|
|
7657
6477
|
|
|
6478
|
+
function capsHasCrafter(caps) {
|
|
6479
|
+
return caps.crafter !== undefined;
|
|
6480
|
+
}
|
|
6481
|
+
|
|
7658
6482
|
exports.ActionsManager = ActionsManager;
|
|
7659
6483
|
exports.COMMIT_ALREADY_SET = COMMIT_ALREADY_SET;
|
|
7660
6484
|
exports.COMMIT_CANNOT_MATCH = COMMIT_CANNOT_MATCH;
|
|
@@ -7663,11 +6487,11 @@ exports.COMPANY_NOT_FOUND = COMPANY_NOT_FOUND;
|
|
|
7663
6487
|
exports.CONTAINER_Z = CONTAINER_Z;
|
|
7664
6488
|
exports.Container = Container;
|
|
7665
6489
|
exports.Coordinates = Coordinates;
|
|
7666
|
-
exports.
|
|
7667
|
-
exports.
|
|
7668
|
-
exports.
|
|
7669
|
-
exports.
|
|
7670
|
-
exports.
|
|
6490
|
+
exports.DEPTH_THRESHOLD_T1 = DEPTH_THRESHOLD_T1;
|
|
6491
|
+
exports.DEPTH_THRESHOLD_T2 = DEPTH_THRESHOLD_T2;
|
|
6492
|
+
exports.DEPTH_THRESHOLD_T3 = DEPTH_THRESHOLD_T3;
|
|
6493
|
+
exports.DEPTH_THRESHOLD_T4 = DEPTH_THRESHOLD_T4;
|
|
6494
|
+
exports.DEPTH_THRESHOLD_T5 = DEPTH_THRESHOLD_T5;
|
|
7671
6495
|
exports.EPOCH_NON_ZERO = EPOCH_NON_ZERO;
|
|
7672
6496
|
exports.EPOCH_NOT_READY = EPOCH_NOT_READY;
|
|
7673
6497
|
exports.ERROR_SYSTEM_ALREADY_INITIALIZED = ERROR_SYSTEM_ALREADY_INITIALIZED;
|
|
@@ -7702,7 +6526,10 @@ exports.INSUFFICIENT_BALANCE = INSUFFICIENT_BALANCE;
|
|
|
7702
6526
|
exports.INSUFFICIENT_ITEM_QUANTITY = INSUFFICIENT_ITEM_QUANTITY;
|
|
7703
6527
|
exports.INSUFFICIENT_ITEM_SUPPLY = INSUFFICIENT_ITEM_SUPPLY;
|
|
7704
6528
|
exports.INVALID_AMOUNT = INVALID_AMOUNT;
|
|
6529
|
+
exports.ITEM_CARGO_LINING = ITEM_CARGO_LINING;
|
|
6530
|
+
exports.ITEM_CONTAINER_PACKED = ITEM_CONTAINER_PACKED;
|
|
7705
6531
|
exports.ITEM_DOES_NOT_EXIST = ITEM_DOES_NOT_EXIST;
|
|
6532
|
+
exports.ITEM_HULL_PLATES = ITEM_HULL_PLATES;
|
|
7706
6533
|
exports.ITEM_NOT_AVAILABLE_AT_LOCATION = ITEM_NOT_AVAILABLE_AT_LOCATION;
|
|
7707
6534
|
exports.InventoryAccessor = InventoryAccessor;
|
|
7708
6535
|
exports.LOCATION_MAX_DEPTH = LOCATION_MAX_DEPTH;
|
|
@@ -7749,18 +6576,16 @@ exports.ServerContract = server;
|
|
|
7749
6576
|
exports.Ship = Ship;
|
|
7750
6577
|
exports.Shipload = Shipload;
|
|
7751
6578
|
exports.TRAVEL_MAX_DURATION = TRAVEL_MAX_DURATION;
|
|
7752
|
-
exports.TradesManager = TradesManager;
|
|
7753
6579
|
exports.WAREHOUSE_ALREADY_AT_LOCATION = WAREHOUSE_ALREADY_AT_LOCATION;
|
|
7754
6580
|
exports.WAREHOUSE_CAPACITY_EXCEEDED = WAREHOUSE_CAPACITY_EXCEEDED;
|
|
7755
6581
|
exports.WAREHOUSE_NOT_FOUND = WAREHOUSE_NOT_FOUND;
|
|
7756
6582
|
exports.WAREHOUSE_Z = WAREHOUSE_Z;
|
|
7757
6583
|
exports.Warehouse = Warehouse;
|
|
7758
|
-
exports.analyzeCargoSale = analyzeCargoSale;
|
|
7759
|
-
exports.analyzeCollectOptions = analyzeCollectOptions;
|
|
7760
6584
|
exports.availableCapacity = availableCapacity$1;
|
|
7761
6585
|
exports.availableCapacityFromMass = availableCapacityFromMass;
|
|
6586
|
+
exports.blendComponentStacks = blendComponentStacks;
|
|
6587
|
+
exports.blendStacks = blendStacks;
|
|
7762
6588
|
exports.calcCargoMass = calcCargoMass;
|
|
7763
|
-
exports.calcCargoValue = calcCargoValue;
|
|
7764
6589
|
exports.calcEnergyUsage = calcEnergyUsage;
|
|
7765
6590
|
exports.calcLoadDuration = calcLoadDuration;
|
|
7766
6591
|
exports.calc_acceleration = calc_acceleration;
|
|
@@ -7777,34 +6602,28 @@ exports.calc_ship_flighttime = calc_ship_flighttime;
|
|
|
7777
6602
|
exports.calc_ship_mass = calc_ship_mass;
|
|
7778
6603
|
exports.calc_ship_rechargetime = calc_ship_rechargetime;
|
|
7779
6604
|
exports.calc_transfer_duration = calc_transfer_duration;
|
|
7780
|
-
exports.calculateBreakEvenPrice = calculateBreakEvenPrice;
|
|
7781
6605
|
exports.calculateFlightTime = calculateFlightTime;
|
|
7782
6606
|
exports.calculateLoadTimeBreakdown = calculateLoadTimeBreakdown;
|
|
7783
|
-
exports.calculateMaxTradeQuantity = calculateMaxTradeQuantity;
|
|
7784
|
-
exports.calculateProfitPerMass = calculateProfitPerMass;
|
|
7785
|
-
exports.calculateProfitPerSecond = calculateProfitPerSecond;
|
|
7786
|
-
exports.calculateROI = calculateROI;
|
|
7787
6607
|
exports.calculateRefuelingTime = calculateRefuelingTime;
|
|
7788
|
-
exports.calculateTradeProfit = calculateTradeProfit;
|
|
7789
6608
|
exports.calculateTransferTime = calculateTransferTime;
|
|
7790
|
-
exports.calculateUpdatedCargoCost = calculateUpdatedCargoCost;
|
|
7791
6609
|
exports.canMove = canMove;
|
|
6610
|
+
exports.capsHasCrafter = capsHasCrafter;
|
|
7792
6611
|
exports.capsHasExtractor = capsHasExtractor;
|
|
7793
6612
|
exports.capsHasLoaders = capsHasLoaders;
|
|
7794
6613
|
exports.capsHasMass = capsHasMass;
|
|
7795
6614
|
exports.capsHasMovement = capsHasMovement;
|
|
7796
6615
|
exports.capsHasStorage = capsHasStorage;
|
|
7797
|
-
exports.capsHasTrade = capsHasTrade;
|
|
7798
6616
|
exports.cargoUtils = cargoUtils;
|
|
6617
|
+
exports.components = components;
|
|
6618
|
+
exports.computeComponentStats = computeComponentStats;
|
|
6619
|
+
exports.computeContainerCapabilities = computeContainerCapabilities;
|
|
6620
|
+
exports.computeEntityStats = computeEntityStats;
|
|
7799
6621
|
exports.coordsToLocationId = coordsToLocationId;
|
|
7800
|
-
exports.createExploreOption = createExploreOption;
|
|
7801
6622
|
exports.createInventoryAccessor = createInventoryAccessor;
|
|
7802
6623
|
exports.createProjectedEntity = createProjectedEntity;
|
|
7803
6624
|
exports.createScheduleAccessor = createScheduleAccessor;
|
|
7804
|
-
exports.
|
|
7805
|
-
exports.
|
|
7806
|
-
exports.createSellAndTradeOption = createSellAndTradeOption;
|
|
7807
|
-
exports.createTravelToSellOption = createTravelToSellOption;
|
|
6625
|
+
exports.decodeCraftedItemStats = decodeCraftedItemStats;
|
|
6626
|
+
exports.decodeStats = decodeStats;
|
|
7808
6627
|
exports["default"] = Shipload;
|
|
7809
6628
|
exports.depthScaleFactor = depthScaleFactor;
|
|
7810
6629
|
exports.deriveLocation = deriveLocation;
|
|
@@ -7815,17 +6634,22 @@ exports.deriveResourceStats = deriveResourceStats;
|
|
|
7815
6634
|
exports.deriveStratum = deriveStratum;
|
|
7816
6635
|
exports.distanceBetweenCoordinates = distanceBetweenCoordinates;
|
|
7817
6636
|
exports.distanceBetweenPoints = distanceBetweenPoints;
|
|
6637
|
+
exports.encodeStats = encodeStats;
|
|
7818
6638
|
exports.energyPercent = energyPercent;
|
|
6639
|
+
exports.entityRecipes = entityRecipes;
|
|
7819
6640
|
exports.estimateDealTravelTime = estimateDealTravelTime;
|
|
7820
6641
|
exports.estimateTravelTime = estimateTravelTime;
|
|
7821
|
-
exports.findBestDeal = findBestDeal;
|
|
7822
|
-
exports.findBestItemToTrade = findBestItemToTrade;
|
|
7823
|
-
exports.findDealsForShip = findDealsForShip;
|
|
7824
6642
|
exports.findNearbyPlanets = findNearbyPlanets;
|
|
6643
|
+
exports.getAllCraftableItems = getAllCraftableItems;
|
|
6644
|
+
exports.getComponentById = getComponentById;
|
|
6645
|
+
exports.getComponentsForCategory = getComponentsForCategory;
|
|
6646
|
+
exports.getComponentsForStat = getComponentsForStat;
|
|
7825
6647
|
exports.getCurrentEpoch = getCurrentEpoch;
|
|
7826
6648
|
exports.getDepthThreshold = getDepthThreshold;
|
|
7827
6649
|
exports.getDestinationLocation = getDestinationLocation;
|
|
7828
6650
|
exports.getEligibleResources = getEligibleResources;
|
|
6651
|
+
exports.getEntityRecipe = getEntityRecipe;
|
|
6652
|
+
exports.getEntityRecipeByItemId = getEntityRecipeByItemId;
|
|
7829
6653
|
exports.getEpochInfo = getEpochInfo;
|
|
7830
6654
|
exports.getFlightOrigin = getFlightOrigin;
|
|
7831
6655
|
exports.getItem = getItem;
|
|
@@ -7833,9 +6657,10 @@ exports.getItems = getItems;
|
|
|
7833
6657
|
exports.getLocationCandidates = getLocationCandidates;
|
|
7834
6658
|
exports.getLocationType = getLocationType;
|
|
7835
6659
|
exports.getPositionAt = getPositionAt;
|
|
7836
|
-
exports.
|
|
7837
|
-
exports.getResourceRarity = getResourceRarity;
|
|
6660
|
+
exports.getResourceTier = getResourceTier;
|
|
7838
6661
|
exports.getResourceWeight = getResourceWeight;
|
|
6662
|
+
exports.getStatDefinitions = getStatDefinitions;
|
|
6663
|
+
exports.getStatName = getStatName;
|
|
7839
6664
|
exports.getSystemName = getSystemName;
|
|
7840
6665
|
exports.hasEnergy = hasEnergy;
|
|
7841
6666
|
exports.hasEnergyForDistance = hasEnergyForDistance$1;
|
|
@@ -7847,24 +6672,21 @@ exports.hasSpace = hasSpace$1;
|
|
|
7847
6672
|
exports.hasSpaceForMass = hasSpaceForMass;
|
|
7848
6673
|
exports.hasStorage = hasStorage;
|
|
7849
6674
|
exports.hasSystem = hasSystem;
|
|
7850
|
-
exports.hasTrade = hasTrade;
|
|
7851
6675
|
exports.hash = hash;
|
|
7852
6676
|
exports.hash512 = hash512;
|
|
7853
6677
|
exports.isExtractableLocation = isExtractableLocation;
|
|
7854
6678
|
exports.isFull = isFull$1;
|
|
7855
6679
|
exports.isFullFromMass = isFullFromMass;
|
|
7856
|
-
exports.isProfitable = isProfitable;
|
|
7857
6680
|
exports.itemIds = itemIds;
|
|
7858
6681
|
exports.lerp = lerp;
|
|
7859
6682
|
exports.makeContainer = makeContainer;
|
|
7860
6683
|
exports.makeShip = makeShip;
|
|
7861
6684
|
exports.makeWarehouse = makeWarehouse;
|
|
7862
|
-
exports.marketPrice = marketPrice;
|
|
7863
|
-
exports.marketPrices = marketPrices;
|
|
7864
6685
|
exports.maxTravelDistance = maxTravelDistance;
|
|
7865
6686
|
exports.needsRecharge = needsRecharge;
|
|
7866
6687
|
exports.projectEntity = projectEntity;
|
|
7867
6688
|
exports.projectEntityAt = projectEntityAt;
|
|
6689
|
+
exports.resolveStats = resolveStats;
|
|
7868
6690
|
exports.rotation = rotation;
|
|
7869
6691
|
exports.schedule = schedule;
|
|
7870
6692
|
exports.toLocation = toLocation;
|