@shipload/sdk 1.0.0-next.4 → 1.0.0-next.5
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 +190 -91
- package/lib/shipload.js +568 -37
- package/lib/shipload.js.map +1 -1
- package/lib/shipload.m.js +561 -37
- package/lib/shipload.m.js.map +1 -1
- package/package.json +1 -1
- package/src/contracts/server.ts +54 -1
- package/src/data/colors.ts +1 -0
- package/src/data/items.json +245 -0
- package/src/data/metadata.ts +44 -1
- package/src/derivation/resources.ts +27 -19
- package/src/entities/container.ts +15 -0
- package/src/entities/ship-deploy.ts +42 -6
- package/src/entities/ship.ts +17 -0
- package/src/entities/warehouse.ts +8 -0
- package/src/index-module.ts +23 -15
- package/src/managers/actions.ts +24 -1
- package/src/nft/description.ts +21 -2
- package/src/resolution/resolve-item.ts +9 -5
- package/src/scheduling/accessor.ts +4 -0
- package/src/scheduling/projection.ts +8 -0
- package/src/scheduling/schedule.ts +15 -1
- package/src/subscriptions/manager.ts +37 -1
- package/src/travel/travel.ts +58 -1
- package/src/types.ts +3 -0
package/lib/shipload.d.ts
CHANGED
|
@@ -289,6 +289,8 @@ declare namespace Types {
|
|
|
289
289
|
capacity: UInt32;
|
|
290
290
|
cargomass: UInt32;
|
|
291
291
|
schedule?: schedule;
|
|
292
|
+
stats: UInt64;
|
|
293
|
+
item_id: UInt16;
|
|
292
294
|
}
|
|
293
295
|
class craft extends Struct {
|
|
294
296
|
entity_type: Name;
|
|
@@ -308,6 +310,10 @@ declare namespace Types {
|
|
|
308
310
|
x: Int64;
|
|
309
311
|
y: Int64;
|
|
310
312
|
}
|
|
313
|
+
class demolish extends Struct {
|
|
314
|
+
entity_type: Name;
|
|
315
|
+
entity_id: UInt64;
|
|
316
|
+
}
|
|
311
317
|
class deploy extends Struct {
|
|
312
318
|
entity_type: Name;
|
|
313
319
|
id: UInt64;
|
|
@@ -731,6 +737,7 @@ declare namespace Types {
|
|
|
731
737
|
hauler?: hauler_stats;
|
|
732
738
|
modules: module_entry[];
|
|
733
739
|
schedule?: schedule;
|
|
740
|
+
item_id: UInt16;
|
|
734
741
|
}
|
|
735
742
|
class spawncargo extends Struct {
|
|
736
743
|
entity_id: UInt64;
|
|
@@ -797,6 +804,12 @@ declare namespace Types {
|
|
|
797
804
|
game_config_type: game_config;
|
|
798
805
|
stratum_remaining_type: stratum_remaining;
|
|
799
806
|
}
|
|
807
|
+
class undeploy extends Struct {
|
|
808
|
+
host_type: Name;
|
|
809
|
+
host_id: UInt64;
|
|
810
|
+
target_type: Name;
|
|
811
|
+
target_id: UInt64;
|
|
812
|
+
}
|
|
800
813
|
class warehouse_row extends Struct {
|
|
801
814
|
id: UInt64;
|
|
802
815
|
owner: Name;
|
|
@@ -809,6 +822,7 @@ declare namespace Types {
|
|
|
809
822
|
loaders?: loader_stats;
|
|
810
823
|
modules: module_entry[];
|
|
811
824
|
schedule?: schedule;
|
|
825
|
+
item_id: UInt16;
|
|
812
826
|
}
|
|
813
827
|
class warp extends Struct {
|
|
814
828
|
entity_type: Name;
|
|
@@ -827,6 +841,10 @@ declare namespace Types {
|
|
|
827
841
|
cargo_id: UInt64;
|
|
828
842
|
quantity: UInt64;
|
|
829
843
|
}
|
|
844
|
+
class wrapentity extends Struct {
|
|
845
|
+
entity_type: Name;
|
|
846
|
+
entity_id: UInt64;
|
|
847
|
+
}
|
|
830
848
|
}
|
|
831
849
|
declare const TableMap: {
|
|
832
850
|
cargo: typeof Types.cargo_row;
|
|
@@ -983,6 +1001,10 @@ declare namespace ActionParams {
|
|
|
983
1001
|
x: Int64Type;
|
|
984
1002
|
y: Int64Type;
|
|
985
1003
|
}
|
|
1004
|
+
interface demolish {
|
|
1005
|
+
entity_type: NameType;
|
|
1006
|
+
entity_id: UInt64Type;
|
|
1007
|
+
}
|
|
986
1008
|
interface deploy {
|
|
987
1009
|
entity_type: NameType;
|
|
988
1010
|
id: UInt64Type;
|
|
@@ -1150,6 +1172,12 @@ declare namespace ActionParams {
|
|
|
1150
1172
|
y: Int64Type;
|
|
1151
1173
|
recharge: boolean;
|
|
1152
1174
|
}
|
|
1175
|
+
interface undeploy {
|
|
1176
|
+
host_type: NameType;
|
|
1177
|
+
host_id: UInt64Type;
|
|
1178
|
+
target_type: NameType;
|
|
1179
|
+
target_id: UInt64Type;
|
|
1180
|
+
}
|
|
1153
1181
|
interface warp {
|
|
1154
1182
|
entity_type: NameType;
|
|
1155
1183
|
id: UInt64Type;
|
|
@@ -1167,6 +1195,10 @@ declare namespace ActionParams {
|
|
|
1167
1195
|
cargo_id: UInt64Type;
|
|
1168
1196
|
quantity: UInt64Type;
|
|
1169
1197
|
}
|
|
1198
|
+
interface wrapentity {
|
|
1199
|
+
entity_type: NameType;
|
|
1200
|
+
entity_id: UInt64Type;
|
|
1201
|
+
}
|
|
1170
1202
|
}
|
|
1171
1203
|
interface ActionNameParams {
|
|
1172
1204
|
addmodule: ActionParams.addmodule;
|
|
@@ -1181,6 +1213,7 @@ interface ActionNameParams {
|
|
|
1181
1213
|
configlog: ActionParams.configlog;
|
|
1182
1214
|
craft: ActionParams.craft;
|
|
1183
1215
|
createentity: ActionParams.createentity;
|
|
1216
|
+
demolish: ActionParams.demolish;
|
|
1184
1217
|
deploy: ActionParams.deploy;
|
|
1185
1218
|
descentity: ActionParams.descentity;
|
|
1186
1219
|
enable: ActionParams.enable;
|
|
@@ -1224,15 +1257,18 @@ interface ActionNameParams {
|
|
|
1224
1257
|
spawnseeded: ActionParams.spawnseeded;
|
|
1225
1258
|
transfer: ActionParams.transfer;
|
|
1226
1259
|
travel: ActionParams.travel;
|
|
1260
|
+
undeploy: ActionParams.undeploy;
|
|
1227
1261
|
warp: ActionParams.warp;
|
|
1228
1262
|
wipe: ActionParams.wipe;
|
|
1229
1263
|
wipesequence: ActionParams.wipesequence;
|
|
1230
1264
|
wrap: ActionParams.wrap;
|
|
1265
|
+
wrapentity: ActionParams.wrapentity;
|
|
1231
1266
|
}
|
|
1232
1267
|
type ActionNames = keyof ActionNameParams;
|
|
1233
1268
|
interface ActionReturnValues {
|
|
1234
1269
|
cancel: Types.cancel_results;
|
|
1235
1270
|
craft: Types.task_results;
|
|
1271
|
+
demolish: Types.task_results;
|
|
1236
1272
|
deploy: Types.task_results;
|
|
1237
1273
|
descentity: string;
|
|
1238
1274
|
gather: Types.task_results;
|
|
@@ -1265,8 +1301,10 @@ interface ActionReturnValues {
|
|
|
1265
1301
|
resolve: Types.resolve_results;
|
|
1266
1302
|
transfer: Types.task_results;
|
|
1267
1303
|
travel: Types.task_results;
|
|
1304
|
+
undeploy: Types.task_results;
|
|
1268
1305
|
warp: Types.task_results;
|
|
1269
1306
|
wrap: Types.task_results;
|
|
1307
|
+
wrapentity: Types.task_results;
|
|
1270
1308
|
}
|
|
1271
1309
|
type ActionReturnNames = keyof ActionReturnValues;
|
|
1272
1310
|
declare class Contract extends Contract$2 {
|
|
@@ -1431,7 +1469,10 @@ declare enum TaskType {
|
|
|
1431
1469
|
CRAFT = 7,
|
|
1432
1470
|
DEPLOY = 8,
|
|
1433
1471
|
WRAP = 9,
|
|
1434
|
-
UNWRAP = 10
|
|
1472
|
+
UNWRAP = 10,
|
|
1473
|
+
UNDEPLOY = 11,
|
|
1474
|
+
WRAP_ENTITY = 12,
|
|
1475
|
+
DEMOLISH = 13
|
|
1435
1476
|
}
|
|
1436
1477
|
declare enum LocationType {
|
|
1437
1478
|
EMPTY = 0,
|
|
@@ -1726,10 +1767,10 @@ declare function deriveStrata(coords: CoordinatesType, gameSeed: Checksum256Type
|
|
|
1726
1767
|
declare function deriveLocationSize(loc: Types.location_static): number;
|
|
1727
1768
|
|
|
1728
1769
|
declare const DEPTH_THRESHOLD_T1 = 0;
|
|
1729
|
-
declare const DEPTH_THRESHOLD_T2 =
|
|
1730
|
-
declare const DEPTH_THRESHOLD_T3 =
|
|
1731
|
-
declare const DEPTH_THRESHOLD_T4 =
|
|
1732
|
-
declare const DEPTH_THRESHOLD_T5 =
|
|
1770
|
+
declare const DEPTH_THRESHOLD_T2 = 1500;
|
|
1771
|
+
declare const DEPTH_THRESHOLD_T3 = 5000;
|
|
1772
|
+
declare const DEPTH_THRESHOLD_T4 = 12000;
|
|
1773
|
+
declare const DEPTH_THRESHOLD_T5 = 22000;
|
|
1733
1774
|
declare const LOCATION_MIN_DEPTH = 500;
|
|
1734
1775
|
declare const LOCATION_MAX_DEPTH = 65535;
|
|
1735
1776
|
declare const PLANET_SUBTYPE_GAS_GIANT = 0;
|
|
@@ -1853,7 +1894,7 @@ declare class EpochsManager extends BaseManager {
|
|
|
1853
1894
|
}
|
|
1854
1895
|
|
|
1855
1896
|
type EntityRefInput = {
|
|
1856
|
-
entityType:
|
|
1897
|
+
entityType: NameType;
|
|
1857
1898
|
entityId: UInt64Type;
|
|
1858
1899
|
};
|
|
1859
1900
|
declare class ActionsManager extends BaseManager {
|
|
@@ -1873,6 +1914,9 @@ declare class ActionsManager extends BaseManager {
|
|
|
1873
1914
|
addmodule(entityType: EntityTypeName, entityId: UInt64Type, moduleIndex: number, moduleCargoId: UInt64Type, targetCargoId?: UInt64Type): Action;
|
|
1874
1915
|
rmmodule(entityType: EntityTypeName, entityId: UInt64Type, moduleIndex: number, targetCargoId?: UInt64Type): Action;
|
|
1875
1916
|
wrap(owner: NameType, entityType: EntityTypeName, entityId: UInt64Type, cargoId: UInt64Type, quantity: UInt64Type): Action;
|
|
1917
|
+
undeploy(host: EntityRefInput, target: EntityRefInput): Action;
|
|
1918
|
+
wrapEntity(entity: EntityRefInput): Action;
|
|
1919
|
+
demolish(entity: EntityRefInput): Action;
|
|
1876
1920
|
joinGame(account: NameType, companyName: string): Action[];
|
|
1877
1921
|
}
|
|
1878
1922
|
|
|
@@ -1981,6 +2025,104 @@ type ErrorMessage = {
|
|
|
1981
2025
|
};
|
|
1982
2026
|
type ServerMessage = AckMessage | SnapshotMessage | UpdateMessage | BoundsDeltaMessage | EventMessage | EventCatchupCompleteMessage | PongMessage | ErrorMessage;
|
|
1983
2027
|
|
|
2028
|
+
/**
|
|
2029
|
+
* Travel calculations for ship movement, energy usage, and flight times.
|
|
2030
|
+
*
|
|
2031
|
+
* Functions prefixed with `calc_` are contract-parity functions that mirror
|
|
2032
|
+
* the C++ implementation in the server contract (schedule.cpp, ship.cpp).
|
|
2033
|
+
* These use snake_case intentionally to match the contract naming convention
|
|
2034
|
+
* and signal that they must produce identical results to the on-chain code.
|
|
2035
|
+
*
|
|
2036
|
+
* Functions prefixed with `calculate` are higher-level SDK helpers that may
|
|
2037
|
+
* combine multiple contract calculations for convenience.
|
|
2038
|
+
*/
|
|
2039
|
+
|
|
2040
|
+
declare function calc_orbital_altitude(mass: number): number;
|
|
2041
|
+
declare function distanceBetweenCoordinates(origin: ActionParams.Type.coordinates, destination: ActionParams.Type.coordinates): UInt64;
|
|
2042
|
+
declare function distanceBetweenPoints(x1: Int64Type, y1: Int64Type, x2: Int64Type, y2: Int64Type): UInt64;
|
|
2043
|
+
declare function lerp(origin: ActionParams.Type.coordinates, destination: ActionParams.Type.coordinates, time: number): ActionParams.Type.coordinates;
|
|
2044
|
+
interface FloatPosition {
|
|
2045
|
+
x: number;
|
|
2046
|
+
y: number;
|
|
2047
|
+
}
|
|
2048
|
+
declare function easeFlightProgress(t: number): number;
|
|
2049
|
+
declare function flightSpeedFactor(t: number): number;
|
|
2050
|
+
declare function interpolateFlightPosition(origin: {
|
|
2051
|
+
x: Int64Type | number;
|
|
2052
|
+
y: Int64Type | number;
|
|
2053
|
+
}, destination: {
|
|
2054
|
+
x: Int64Type | number;
|
|
2055
|
+
y: Int64Type | number;
|
|
2056
|
+
}, taskProgress: number, options?: {
|
|
2057
|
+
easing?: 'physics' | 'linear';
|
|
2058
|
+
}): FloatPosition;
|
|
2059
|
+
declare function getInterpolatedPosition(entity: HasScheduleAndLocation, taskIndex: number, taskProgress: number): FloatPosition;
|
|
2060
|
+
declare function rotation(origin: ActionParams.Type.coordinates, destination: ActionParams.Type.coordinates): number;
|
|
2061
|
+
declare function findNearbyPlanets(seed: Checksum256, origin: ActionParams.Type.coordinates, maxDistance?: UInt64Type): Distance[];
|
|
2062
|
+
declare function calc_rechargetime(capacity: UInt32Type, energy: UInt32Type, recharge: UInt32Type): UInt32;
|
|
2063
|
+
declare function calc_ship_rechargetime(ship: ShipLike): UInt32;
|
|
2064
|
+
declare function calc_flighttime(distance: UInt64Type, acceleration: number): UInt32;
|
|
2065
|
+
declare function calc_loader_flighttime(ship: ShipLike, mass: UInt64, altitude?: number): UInt32;
|
|
2066
|
+
declare function calc_loader_acceleration(ship: ShipLike, mass: UInt64): number;
|
|
2067
|
+
declare function calc_ship_flighttime(ship: ShipLike, mass: UInt64, distance: UInt64): UInt32;
|
|
2068
|
+
declare function calc_ship_acceleration(ship: ShipLike, mass: UInt64): number;
|
|
2069
|
+
declare function calc_acceleration(thrust: number, mass: number): number;
|
|
2070
|
+
declare function calc_ship_mass(ship: ShipLike, cargos: CargoMassInfo[]): UInt64;
|
|
2071
|
+
declare function calc_energyusage(distance: UInt64Type, drain: UInt32Type): UInt32;
|
|
2072
|
+
declare function calculateTransferTime(ship: ShipLike, cargos: CargoMassInfo[], quantities?: Map<number, number>): UInt32;
|
|
2073
|
+
declare function calculateRefuelingTime(ship: ShipLike): UInt32;
|
|
2074
|
+
declare function calculateFlightTime(ship: ShipLike, cargos: CargoMassInfo[], distance: UInt64Type): UInt32;
|
|
2075
|
+
interface LoadTimeBreakdown {
|
|
2076
|
+
unloadTime: number;
|
|
2077
|
+
loadTime: number;
|
|
2078
|
+
totalTime: number;
|
|
2079
|
+
unloadMass: number;
|
|
2080
|
+
loadMass: number;
|
|
2081
|
+
}
|
|
2082
|
+
declare function calculateLoadTimeBreakdown(ship: ShipLike, cargos: CargoMassInfo[], loadQuantities?: Map<number, number>, unloadQuantities?: Map<number, number>): LoadTimeBreakdown;
|
|
2083
|
+
interface EstimatedTravelTime {
|
|
2084
|
+
flightTime: UInt32;
|
|
2085
|
+
rechargeTime: UInt32;
|
|
2086
|
+
loadTime: UInt32;
|
|
2087
|
+
unloadTime: UInt32;
|
|
2088
|
+
total: UInt32;
|
|
2089
|
+
}
|
|
2090
|
+
interface EstimateTravelTimeOptions {
|
|
2091
|
+
needsRecharge?: boolean;
|
|
2092
|
+
loadMass?: UInt32Type;
|
|
2093
|
+
unloadMass?: UInt32Type;
|
|
2094
|
+
}
|
|
2095
|
+
declare function estimateTravelTime(ship: ShipLike, travelMass: UInt64Type, distance: UInt64Type, options?: EstimateTravelTimeOptions): EstimatedTravelTime;
|
|
2096
|
+
declare function estimateDealTravelTime(ship: ShipLike, shipMass: UInt64Type, distance: UInt64Type, loadMass: UInt32Type): UInt32;
|
|
2097
|
+
declare function hasEnergyForDistance(ship: ShipLike, distance: UInt64Type): boolean;
|
|
2098
|
+
interface TransferEntity {
|
|
2099
|
+
location: {
|
|
2100
|
+
z?: {
|
|
2101
|
+
toNumber(): number;
|
|
2102
|
+
} | number;
|
|
2103
|
+
};
|
|
2104
|
+
loaders?: {
|
|
2105
|
+
thrust: {
|
|
2106
|
+
toNumber(): number;
|
|
2107
|
+
} | number;
|
|
2108
|
+
mass: {
|
|
2109
|
+
toNumber(): number;
|
|
2110
|
+
} | number;
|
|
2111
|
+
quantity: {
|
|
2112
|
+
toNumber(): number;
|
|
2113
|
+
} | number;
|
|
2114
|
+
};
|
|
2115
|
+
}
|
|
2116
|
+
interface HasScheduleAndLocation {
|
|
2117
|
+
coordinates: ActionParams.Type.coordinates;
|
|
2118
|
+
schedule?: Types.schedule;
|
|
2119
|
+
}
|
|
2120
|
+
declare function getFlightOrigin(entity: HasScheduleAndLocation, flightTaskIndex: number): ActionParams.Type.coordinates;
|
|
2121
|
+
declare function getDestinationLocation(entity: HasScheduleAndLocation): ActionParams.Type.coordinates | undefined;
|
|
2122
|
+
/** Returns chain-tile coordinates (rounded). For visual position use getInterpolatedPosition. */
|
|
2123
|
+
declare function getPositionAt(entity: HasScheduleAndLocation, taskIndex: number, taskProgress: number): ActionParams.Type.coordinates;
|
|
2124
|
+
declare function calc_transfer_duration(source: TransferEntity, dest: TransferEntity, cargoMass: number): number;
|
|
2125
|
+
|
|
1984
2126
|
interface MovementCapability {
|
|
1985
2127
|
engines: Types.movement_stats;
|
|
1986
2128
|
generator: Types.energy_stats;
|
|
@@ -2105,6 +2247,7 @@ declare function getTaskRemaining(entity: ScheduleData, index: number, now: Date
|
|
|
2105
2247
|
declare function isTaskComplete(entity: ScheduleData, index: number, now: Date): boolean;
|
|
2106
2248
|
declare function isTaskInProgress(entity: ScheduleData, index: number, now: Date): boolean;
|
|
2107
2249
|
declare function currentTaskProgress(entity: ScheduleData, now: Date): number;
|
|
2250
|
+
declare function currentTaskProgressFloat(entity: ScheduleData, now: Date): number;
|
|
2108
2251
|
declare function scheduleProgress(entity: ScheduleData, now: Date): number;
|
|
2109
2252
|
declare function isTaskType(entity: ScheduleData, taskType: TaskType, now: Date): boolean;
|
|
2110
2253
|
declare function isInFlight(entity: ScheduleData, now: Date): boolean;
|
|
@@ -2130,6 +2273,7 @@ declare const schedule_getTaskRemaining: typeof getTaskRemaining;
|
|
|
2130
2273
|
declare const schedule_isTaskComplete: typeof isTaskComplete;
|
|
2131
2274
|
declare const schedule_isTaskInProgress: typeof isTaskInProgress;
|
|
2132
2275
|
declare const schedule_currentTaskProgress: typeof currentTaskProgress;
|
|
2276
|
+
declare const schedule_currentTaskProgressFloat: typeof currentTaskProgressFloat;
|
|
2133
2277
|
declare const schedule_scheduleProgress: typeof scheduleProgress;
|
|
2134
2278
|
declare const schedule_isTaskType: typeof isTaskType;
|
|
2135
2279
|
declare const schedule_isInFlight: typeof isInFlight;
|
|
@@ -2157,6 +2301,7 @@ declare namespace schedule {
|
|
|
2157
2301
|
schedule_isTaskComplete as isTaskComplete,
|
|
2158
2302
|
schedule_isTaskInProgress as isTaskInProgress,
|
|
2159
2303
|
schedule_currentTaskProgress as currentTaskProgress,
|
|
2304
|
+
schedule_currentTaskProgressFloat as currentTaskProgressFloat,
|
|
2160
2305
|
schedule_scheduleProgress as scheduleProgress,
|
|
2161
2306
|
schedule_isTaskType as isTaskType,
|
|
2162
2307
|
schedule_isInFlight as isInFlight,
|
|
@@ -2249,6 +2394,7 @@ declare class ScheduleAccessor {
|
|
|
2249
2394
|
taskComplete(index: number, now: Date): boolean;
|
|
2250
2395
|
taskInProgress(index: number, now: Date): boolean;
|
|
2251
2396
|
currentTaskProgress(now: Date): number;
|
|
2397
|
+
currentTaskProgressFloat(now: Date): number;
|
|
2252
2398
|
progress(now: Date): number;
|
|
2253
2399
|
}
|
|
2254
2400
|
declare function createScheduleAccessor(entity: ScheduleData): ScheduleAccessor;
|
|
@@ -2301,6 +2447,8 @@ declare class Ship extends Types.entity_info {
|
|
|
2301
2447
|
private _sched?;
|
|
2302
2448
|
private _inv?;
|
|
2303
2449
|
get name(): string;
|
|
2450
|
+
get entityClass(): 'mobile';
|
|
2451
|
+
get canUndeploy(): boolean;
|
|
2304
2452
|
get inv(): InventoryAccessor;
|
|
2305
2453
|
get inventory(): EntityInventory[];
|
|
2306
2454
|
get sched(): ScheduleAccessor;
|
|
@@ -2308,7 +2456,9 @@ declare class Ship extends Types.entity_info {
|
|
|
2308
2456
|
get isIdle(): boolean;
|
|
2309
2457
|
getFlightOrigin(flightTaskIndex: number): Coordinates;
|
|
2310
2458
|
destinationLocation(): Coordinates | undefined;
|
|
2459
|
+
/** Chain-tile coordinates at `now`. For smooth visual position use interpolatedPositionAt. */
|
|
2311
2460
|
positionAt(now: Date): Coordinates;
|
|
2461
|
+
interpolatedPositionAt(now: Date): FloatPosition;
|
|
2312
2462
|
isInFlight(now: Date): boolean;
|
|
2313
2463
|
isRecharging(now: Date): boolean;
|
|
2314
2464
|
isLoading(now: Date): boolean;
|
|
@@ -2355,6 +2505,8 @@ declare class Warehouse extends Types.entity_info {
|
|
|
2355
2505
|
private _sched?;
|
|
2356
2506
|
private _inv?;
|
|
2357
2507
|
get name(): string;
|
|
2508
|
+
get entityClass(): 'building';
|
|
2509
|
+
get canDemolish(): boolean;
|
|
2358
2510
|
get inv(): InventoryAccessor;
|
|
2359
2511
|
get inventory(): EntityInventory[];
|
|
2360
2512
|
get sched(): ScheduleAccessor;
|
|
@@ -2400,8 +2552,11 @@ interface ContainerStateInput {
|
|
|
2400
2552
|
declare class Container extends Types.entity_info {
|
|
2401
2553
|
private _sched?;
|
|
2402
2554
|
get name(): string;
|
|
2555
|
+
get entityClass(): 'mobile';
|
|
2556
|
+
get canUndeploy(): boolean;
|
|
2403
2557
|
get sched(): ScheduleAccessor;
|
|
2404
2558
|
get isIdle(): boolean;
|
|
2559
|
+
interpolatedPositionAt(now: Date): FloatPosition;
|
|
2405
2560
|
isLoading(now: Date): boolean;
|
|
2406
2561
|
isUnloading(now: Date): boolean;
|
|
2407
2562
|
get location(): Location;
|
|
@@ -2435,6 +2590,11 @@ interface BoundsSubscriptionHandle {
|
|
|
2435
2590
|
updateBounds(bounds: BoundingBox): void;
|
|
2436
2591
|
current: Map<number, EntityInstance>;
|
|
2437
2592
|
}
|
|
2593
|
+
interface OwnerSubscriptionHandle {
|
|
2594
|
+
readonly subId: string;
|
|
2595
|
+
unsubscribe(): void;
|
|
2596
|
+
current: Map<number, EntityInstance>;
|
|
2597
|
+
}
|
|
2438
2598
|
interface EntitySubscriptionHandle {
|
|
2439
2599
|
readonly subId: string;
|
|
2440
2600
|
readonly entityType: SubscriptionEntityType;
|
|
@@ -2461,6 +2621,10 @@ declare class SubscriptionsManager {
|
|
|
2461
2621
|
owner?: string;
|
|
2462
2622
|
prioritizeOwner?: string;
|
|
2463
2623
|
}): BoundsSubscriptionHandle;
|
|
2624
|
+
subscribeOwner(owner: string, handlers?: {
|
|
2625
|
+
onSnapshot?: (entities: EntityInstance[]) => void;
|
|
2626
|
+
onUpdate?: (entity: EntityInstance) => void;
|
|
2627
|
+
}): OwnerSubscriptionHandle;
|
|
2464
2628
|
private unsubscribeBounds;
|
|
2465
2629
|
private updateBounds;
|
|
2466
2630
|
private onStateChange;
|
|
@@ -2594,87 +2758,6 @@ declare function deriveLocation(gameSeed: Checksum256Type, epochSeed: Checksum25
|
|
|
2594
2758
|
declare function hash(seed: Checksum256Type, string: string): Checksum256;
|
|
2595
2759
|
declare function hash512(seed: Checksum256Type, string: string): Checksum512;
|
|
2596
2760
|
|
|
2597
|
-
/**
|
|
2598
|
-
* Travel calculations for ship movement, energy usage, and flight times.
|
|
2599
|
-
*
|
|
2600
|
-
* Functions prefixed with `calc_` are contract-parity functions that mirror
|
|
2601
|
-
* the C++ implementation in the server contract (schedule.cpp, ship.cpp).
|
|
2602
|
-
* These use snake_case intentionally to match the contract naming convention
|
|
2603
|
-
* and signal that they must produce identical results to the on-chain code.
|
|
2604
|
-
*
|
|
2605
|
-
* Functions prefixed with `calculate` are higher-level SDK helpers that may
|
|
2606
|
-
* combine multiple contract calculations for convenience.
|
|
2607
|
-
*/
|
|
2608
|
-
|
|
2609
|
-
declare function calc_orbital_altitude(mass: number): number;
|
|
2610
|
-
declare function distanceBetweenCoordinates(origin: ActionParams.Type.coordinates, destination: ActionParams.Type.coordinates): UInt64;
|
|
2611
|
-
declare function distanceBetweenPoints(x1: Int64Type, y1: Int64Type, x2: Int64Type, y2: Int64Type): UInt64;
|
|
2612
|
-
declare function lerp(origin: ActionParams.Type.coordinates, destination: ActionParams.Type.coordinates, time: number): ActionParams.Type.coordinates;
|
|
2613
|
-
declare function rotation(origin: ActionParams.Type.coordinates, destination: ActionParams.Type.coordinates): number;
|
|
2614
|
-
declare function findNearbyPlanets(seed: Checksum256, origin: ActionParams.Type.coordinates, maxDistance?: UInt64Type): Distance[];
|
|
2615
|
-
declare function calc_rechargetime(capacity: UInt32Type, energy: UInt32Type, recharge: UInt32Type): UInt32;
|
|
2616
|
-
declare function calc_ship_rechargetime(ship: ShipLike): UInt32;
|
|
2617
|
-
declare function calc_flighttime(distance: UInt64Type, acceleration: number): UInt32;
|
|
2618
|
-
declare function calc_loader_flighttime(ship: ShipLike, mass: UInt64, altitude?: number): UInt32;
|
|
2619
|
-
declare function calc_loader_acceleration(ship: ShipLike, mass: UInt64): number;
|
|
2620
|
-
declare function calc_ship_flighttime(ship: ShipLike, mass: UInt64, distance: UInt64): UInt32;
|
|
2621
|
-
declare function calc_ship_acceleration(ship: ShipLike, mass: UInt64): number;
|
|
2622
|
-
declare function calc_acceleration(thrust: number, mass: number): number;
|
|
2623
|
-
declare function calc_ship_mass(ship: ShipLike, cargos: CargoMassInfo[]): UInt64;
|
|
2624
|
-
declare function calc_energyusage(distance: UInt64Type, drain: UInt32Type): UInt32;
|
|
2625
|
-
declare function calculateTransferTime(ship: ShipLike, cargos: CargoMassInfo[], quantities?: Map<number, number>): UInt32;
|
|
2626
|
-
declare function calculateRefuelingTime(ship: ShipLike): UInt32;
|
|
2627
|
-
declare function calculateFlightTime(ship: ShipLike, cargos: CargoMassInfo[], distance: UInt64Type): UInt32;
|
|
2628
|
-
interface LoadTimeBreakdown {
|
|
2629
|
-
unloadTime: number;
|
|
2630
|
-
loadTime: number;
|
|
2631
|
-
totalTime: number;
|
|
2632
|
-
unloadMass: number;
|
|
2633
|
-
loadMass: number;
|
|
2634
|
-
}
|
|
2635
|
-
declare function calculateLoadTimeBreakdown(ship: ShipLike, cargos: CargoMassInfo[], loadQuantities?: Map<number, number>, unloadQuantities?: Map<number, number>): LoadTimeBreakdown;
|
|
2636
|
-
interface EstimatedTravelTime {
|
|
2637
|
-
flightTime: UInt32;
|
|
2638
|
-
rechargeTime: UInt32;
|
|
2639
|
-
loadTime: UInt32;
|
|
2640
|
-
unloadTime: UInt32;
|
|
2641
|
-
total: UInt32;
|
|
2642
|
-
}
|
|
2643
|
-
interface EstimateTravelTimeOptions {
|
|
2644
|
-
needsRecharge?: boolean;
|
|
2645
|
-
loadMass?: UInt32Type;
|
|
2646
|
-
unloadMass?: UInt32Type;
|
|
2647
|
-
}
|
|
2648
|
-
declare function estimateTravelTime(ship: ShipLike, travelMass: UInt64Type, distance: UInt64Type, options?: EstimateTravelTimeOptions): EstimatedTravelTime;
|
|
2649
|
-
declare function estimateDealTravelTime(ship: ShipLike, shipMass: UInt64Type, distance: UInt64Type, loadMass: UInt32Type): UInt32;
|
|
2650
|
-
declare function hasEnergyForDistance(ship: ShipLike, distance: UInt64Type): boolean;
|
|
2651
|
-
interface TransferEntity {
|
|
2652
|
-
location: {
|
|
2653
|
-
z?: {
|
|
2654
|
-
toNumber(): number;
|
|
2655
|
-
} | number;
|
|
2656
|
-
};
|
|
2657
|
-
loaders?: {
|
|
2658
|
-
thrust: {
|
|
2659
|
-
toNumber(): number;
|
|
2660
|
-
} | number;
|
|
2661
|
-
mass: {
|
|
2662
|
-
toNumber(): number;
|
|
2663
|
-
} | number;
|
|
2664
|
-
quantity: {
|
|
2665
|
-
toNumber(): number;
|
|
2666
|
-
} | number;
|
|
2667
|
-
};
|
|
2668
|
-
}
|
|
2669
|
-
interface HasScheduleAndLocation {
|
|
2670
|
-
coordinates: ActionParams.Type.coordinates;
|
|
2671
|
-
schedule?: Types.schedule;
|
|
2672
|
-
}
|
|
2673
|
-
declare function getFlightOrigin(entity: HasScheduleAndLocation, flightTaskIndex: number): ActionParams.Type.coordinates;
|
|
2674
|
-
declare function getDestinationLocation(entity: HasScheduleAndLocation): ActionParams.Type.coordinates | undefined;
|
|
2675
|
-
declare function getPositionAt(entity: HasScheduleAndLocation, taskIndex: number, taskProgress: number): ActionParams.Type.coordinates;
|
|
2676
|
-
declare function calc_transfer_duration(source: TransferEntity, dest: TransferEntity, cargoMass: number): number;
|
|
2677
|
-
|
|
2678
2761
|
interface CargoData {
|
|
2679
2762
|
cargo: EntityInventory[];
|
|
2680
2763
|
}
|
|
@@ -2773,7 +2856,7 @@ declare function isModuleItem(itemId: number): boolean;
|
|
|
2773
2856
|
declare function moduleSlotTypeToCode(slotType: string): number;
|
|
2774
2857
|
|
|
2775
2858
|
declare function computeHaulPenalty(totalThrust: number, haulCount: number, avgEfficiency: number): number;
|
|
2776
|
-
declare function computeHaulerDrain(distance: number, drain: number, haulCount: number): number;
|
|
2859
|
+
declare function computeHaulerDrain$1(distance: number, drain: number, haulCount: number): number;
|
|
2777
2860
|
|
|
2778
2861
|
declare const categoryColors: Record<ResourceCategory, string>;
|
|
2779
2862
|
declare const tierColors: Record<number, string>;
|
|
@@ -2855,7 +2938,14 @@ declare function computeGeneratorCapabilities(stats: Record<string, number>): {
|
|
|
2855
2938
|
capacity: number;
|
|
2856
2939
|
recharge: number;
|
|
2857
2940
|
};
|
|
2858
|
-
|
|
2941
|
+
interface GathererDepthParams {
|
|
2942
|
+
readonly floor: number;
|
|
2943
|
+
readonly slope: number;
|
|
2944
|
+
}
|
|
2945
|
+
declare const GATHERER_DEPTH_TABLE: readonly GathererDepthParams[];
|
|
2946
|
+
declare const GATHERER_DEPTH_MAX_TIER = 10;
|
|
2947
|
+
declare function gathererDepthForTier(tol: number, tier: number): number;
|
|
2948
|
+
declare function computeGathererCapabilities(stats: Record<string, number>, tier: number): {
|
|
2859
2949
|
yield: number;
|
|
2860
2950
|
drain: number;
|
|
2861
2951
|
depth: number;
|
|
@@ -3020,12 +3110,15 @@ declare const computeGeneratorCap: (com: number) => number;
|
|
|
3020
3110
|
declare const computeGeneratorRech: (fin: number) => number;
|
|
3021
3111
|
declare const computeGathererYield: (str: number) => number;
|
|
3022
3112
|
declare const computeGathererDrain: (con: number) => number;
|
|
3023
|
-
declare const computeGathererDepth: (tol: number) => number;
|
|
3113
|
+
declare const computeGathererDepth: (tol: number, tier: number) => number;
|
|
3024
3114
|
declare const computeGathererSpeed: (ref: number) => number;
|
|
3025
3115
|
declare const computeLoaderMass: (ins: number) => number;
|
|
3026
3116
|
declare const computeLoaderThrust: (pla: number) => number;
|
|
3027
3117
|
declare const computeCrafterSpeed: (rea: number) => number;
|
|
3028
3118
|
declare const computeCrafterDrain: (fin: number) => number;
|
|
3119
|
+
declare const computeHaulerCapacity: (fin: number) => number;
|
|
3120
|
+
declare const computeHaulerEfficiency: (con: number) => number;
|
|
3121
|
+
declare const computeHaulerDrain: (com: number) => number;
|
|
3029
3122
|
declare const computeWarpRange: (stat: number) => number;
|
|
3030
3123
|
declare function entityDisplayName(itemId: number): string;
|
|
3031
3124
|
declare function moduleDisplayName(itemId: number): string;
|
|
@@ -3058,6 +3151,9 @@ declare const index_computeLoaderMass: typeof computeLoaderMass;
|
|
|
3058
3151
|
declare const index_computeLoaderThrust: typeof computeLoaderThrust;
|
|
3059
3152
|
declare const index_computeCrafterSpeed: typeof computeCrafterSpeed;
|
|
3060
3153
|
declare const index_computeCrafterDrain: typeof computeCrafterDrain;
|
|
3154
|
+
declare const index_computeHaulerCapacity: typeof computeHaulerCapacity;
|
|
3155
|
+
declare const index_computeHaulerEfficiency: typeof computeHaulerEfficiency;
|
|
3156
|
+
declare const index_computeHaulerDrain: typeof computeHaulerDrain;
|
|
3061
3157
|
declare const index_computeWarpRange: typeof computeWarpRange;
|
|
3062
3158
|
declare const index_entityDisplayName: typeof entityDisplayName;
|
|
3063
3159
|
declare const index_moduleDisplayName: typeof moduleDisplayName;
|
|
@@ -3091,6 +3187,9 @@ declare namespace index {
|
|
|
3091
3187
|
index_computeLoaderThrust as computeLoaderThrust,
|
|
3092
3188
|
index_computeCrafterSpeed as computeCrafterSpeed,
|
|
3093
3189
|
index_computeCrafterDrain as computeCrafterDrain,
|
|
3190
|
+
index_computeHaulerCapacity as computeHaulerCapacity,
|
|
3191
|
+
index_computeHaulerEfficiency as computeHaulerEfficiency,
|
|
3192
|
+
index_computeHaulerDrain as computeHaulerDrain,
|
|
3094
3193
|
index_computeWarpRange as computeWarpRange,
|
|
3095
3194
|
index_entityDisplayName as entityDisplayName,
|
|
3096
3195
|
index_moduleDisplayName as moduleDisplayName,
|
|
@@ -3178,4 +3277,4 @@ type location_epoch = Types.location_epoch;
|
|
|
3178
3277
|
type location_derived = Types.location_derived;
|
|
3179
3278
|
type location_row = Types.location_row;
|
|
3180
3279
|
|
|
3181
|
-
export { AckMessage, ActionsManager, AnyEntity, BASE_ORBITAL_MASS, BLEND_INPUTS_MUST_MATCH, BLEND_REQUIRES_MULTIPLE, BLEND_STAT_LESS_NOT_SUPPORTED, BoundingBox, BoundsDeltaMessage, BoundsSubscriptionHandle, CANCEL_CONTAINS_GROUPED_TASK, CANCEL_PAIRED_HAS_PENDING, CATEGORY_LABELS, COMMIT_ALREADY_SET, COMMIT_CANNOT_MATCH, COMMIT_NOT_SET, COMPANY_NOT_FOUND, CONTAINER_CAPACITY_EXCEEDED, CONTAINER_NOT_FOUND, CONTAINER_Z, CRAFT_ENERGY_DIVISOR, CRAFT_EXCEEDS_ENERGY_CAPACITY, CRAFT_NOT_ENOUGH_ENERGY, CapabilityAttribute, CapabilityInput, CargoData, CargoMassInfo, CargoStack, CategoryIconShape, CategoryInfo, CategoryStacks, ClientMessage, ConnectionState, Container, ContainerEntity, ContainerStateInput, Coordinates, CoordinatesType, CraftedItemCategory, CrafterCapability, DEPLOY_ENTITY_HAS_SCHEDULE, DEPTH_THRESHOLD_T1, DEPTH_THRESHOLD_T2, DEPTH_THRESHOLD_T3, DEPTH_THRESHOLD_T4, DEPTH_THRESHOLD_T5, DESTINATION_CAPACITY_EXCEEDED, DerivedStratum, DescribeOptions, Distance, ENTITY_CAPACITY_EXCEEDED, ENTITY_NO_CRAFTER, EPOCH_NON_ZERO, EPOCH_NOT_READY, ERROR_SYSTEM_ALREADY_INITIALIZED, ERROR_SYSTEM_DISABLED, ERROR_SYSTEM_NOT_INITIALIZED, EnergyCapability, EntitiesManager, Entity, EntityCapabilities, EntityInfo, EntityInstance, EntityInventory, EntityLayout, EntityRefInput, EntitySlot, EntityState, EntitySubscriptionHandle, EntityType, EntityTypeName, EpochInfo, EpochsManager, ErrorMessage, EstimateTravelTimeOptions, EstimatedTravelTime, EventCatchupCompleteMessage, EventMessage, GAME_NOT_FOUND, GAME_SEED_NOT_SET, GATHER_EXCEEDS_ENERGY_CAPACITY, GATHER_NOT_ENOUGH_ENERGY, GROUP_DUPLICATE_ENTITY, GROUP_EMPTY, GROUP_ENTITY_NOT_MOVABLE, GROUP_HAUL_CAPACITY_EXCEEDED, GROUP_NOT_FOUND, GROUP_NOT_SAME_LOCATION, GROUP_NOT_SAME_OWNER, GROUP_NO_THRUST, GameState, GathererCapability, HasCapacity, HasCargo, HasCargomass, HasScheduleAndLocation, INSUFFICIENT_BALANCE, INSUFFICIENT_ITEM_QUANTITY, INSUFFICIENT_ITEM_SUPPLY, INVALID_AMOUNT, ITEM_BIOMASS_T1, ITEM_BIOMASS_T10, ITEM_BIOMASS_T2, ITEM_BIOMASS_T3, ITEM_BIOMASS_T4, ITEM_BIOMASS_T5, ITEM_BIOMASS_T6, ITEM_BIOMASS_T7, ITEM_BIOMASS_T8, ITEM_BIOMASS_T9, ITEM_CARGO_ARM, ITEM_CARGO_LINING, ITEM_CARGO_LINING_T2, ITEM_CONTAINER_T1_PACKED, ITEM_CONTAINER_T2_PACKED, ITEM_CRAFTER_T1, ITEM_CRYSTAL_T1, ITEM_CRYSTAL_T10, ITEM_CRYSTAL_T2, ITEM_CRYSTAL_T3, ITEM_CRYSTAL_T4, ITEM_CRYSTAL_T5, ITEM_CRYSTAL_T6, ITEM_CRYSTAL_T7, ITEM_CRYSTAL_T8, ITEM_CRYSTAL_T9, ITEM_DOES_NOT_EXIST, ITEM_ENGINE_T1, ITEM_FOCUSING_ARRAY, ITEM_GAS_T1, ITEM_GAS_T10, ITEM_GAS_T2, ITEM_GAS_T3, ITEM_GAS_T4, ITEM_GAS_T5, ITEM_GAS_T6, ITEM_GAS_T7, ITEM_GAS_T8, ITEM_GAS_T9, ITEM_GATHERER_T1, ITEM_GENERATOR_T1, ITEM_HAULER_T1, ITEM_HULL_PLATES, ITEM_HULL_PLATES_T2, ITEM_LOADER_T1, ITEM_MATTER_CONDUIT, ITEM_NOT_AVAILABLE_AT_LOCATION, ITEM_NOT_DEPLOYABLE, ITEM_NOT_PACKED_ENTITY, ITEM_ORE_T1, ITEM_ORE_T10, ITEM_ORE_T2, ITEM_ORE_T3, ITEM_ORE_T4, ITEM_ORE_T5, ITEM_ORE_T6, ITEM_ORE_T7, ITEM_ORE_T8, ITEM_ORE_T9, ITEM_POWER_CELL, ITEM_REACTION_CHAMBER, ITEM_REGOLITH_T1, ITEM_REGOLITH_T10, ITEM_REGOLITH_T2, ITEM_REGOLITH_T3, ITEM_REGOLITH_T4, ITEM_REGOLITH_T5, ITEM_REGOLITH_T6, ITEM_REGOLITH_T7, ITEM_REGOLITH_T8, ITEM_REGOLITH_T9, ITEM_SHIP_T1_PACKED, ITEM_STORAGE_T1, ITEM_SURVEY_PROBE, ITEM_THRUSTER_CORE, ITEM_TOOL_BIT, ITEM_TYPE_COMPONENT, ITEM_TYPE_ENTITY, ITEM_TYPE_MODULE, ITEM_TYPE_RESOURCE, ITEM_WAREHOUSE_T1_PACKED, ITEM_WARP_T1, InventoryAccessor, Item, ItemType, LOCATION_MAX_DEPTH, LOCATION_MIN_DEPTH, LoadTimeBreakdown, LoaderCapability, Location, LocationStratum, LocationType, LocationsManager, MAX_ORBITAL_ALTITUDE, MIN_ORBITAL_ALTITUDE, MODULE_ANY, MODULE_CARGO_NOT_FOUND, MODULE_CRAFTER, MODULE_ENGINE, MODULE_ENTITY_BUSY, MODULE_GATHERER, MODULE_GENERATOR, MODULE_HAULER, MODULE_LAUNCHER, MODULE_LOADER, MODULE_NOT_MODULE, MODULE_SLOT_EMPTY, MODULE_SLOT_INVALID, MODULE_SLOT_OCCUPIED, MODULE_STORAGE, MODULE_TYPE_MISMATCH, MODULE_WARP, MassCapability, ModuleDescription, ModuleEntry, ModuleType, MovementCapability, index as NFT, NFTCargoItem, NFTCommonBase, NFTInstalledModule, NFTModuleSlot, NO_SCHEDULE, NamedStats, PLANET_SUBTYPE_GAS_GIANT, PLANET_SUBTYPE_ICY, PLANET_SUBTYPE_INDUSTRIAL, PLANET_SUBTYPE_OCEAN, PLANET_SUBTYPE_ROCKY, PLANET_SUBTYPE_TERRESTRIAL, PLAYER_ALREADY_JOINED, PLAYER_NOT_FOUND, PLAYER_NOT_JOINED, PRECISION, PackedModule, PackedModuleInput, PingMessage, PlanetSubtypeInfo, platform as PlatformContract, Types$1 as PlatformTypes, Player, PlayerStateInput, PlayersManager, PongMessage, Projectable, ProjectableSnapshot, ProjectedEntity, ProjectionOptions, RECIPE_INPUTS_EXCESS, RECIPE_INPUTS_INSUFFICIENT, RECIPE_INPUTS_INVALID, RECIPE_INPUTS_MIXED, RECIPE_NOT_FOUND, REQUIRES_MORE_THAN_ONE, REQUIRES_POSITIVE_VALUE, RESERVE_TIERS, RESOLVE_COUNT_EXCEEDS_COMPLETED, Recipe, RecipeInput, RecipeInputCategory, RecipeInputItemId, RecipeSlotInput, RenderDescriptionOptions, ReserveTier, ResolvedAttributeGroup, ResolvedItem, ResolvedItemStat, ResolvedItemType, ResolvedModuleSlot, ResourceCategory, ResourceStats, SHIP_ALREADY_THERE, SHIP_ALREADY_TRAVELING, SHIP_CANNOT_BUY_TRAVELING, SHIP_CANNOT_CANCEL_TASK, SHIP_CANNOT_UPDATE_TRAVELING, SHIP_CAPACITY_EXCEEDED, SHIP_CARGO_NOT_LOADED, SHIP_CARGO_NOT_OWNED, SHIP_INVALID_CARGO, SHIP_INVALID_DESTINATION, SHIP_INVALID_TRAVEL_DURATION, SHIP_NOT_ARRIVED, SHIP_NOT_ENOUGH_ENERGY, SHIP_NOT_ENOUGH_ENERGY_CAPACITY, SHIP_NOT_FOUND, SHIP_NOT_IDLE, SHIP_NOT_OWNED, SHIP_NO_COMPLETED_TASKS, SHIP_NO_TASKS_TO_CANCEL, SLOT_FORMULAS, STARTER_ALREADY_CLAIMED, ScheduleAccessor, ScheduleCapability, ScheduleData, Scheduleable, server as ServerContract, ServerMessage, Types as ServerTypes, Ship, ShipCapabilities, ShipEntity, ShipLike, ShipStateInput, Shipload, SlotConsumer, SlotConsumerKind, SnapshotMessage, StackInput, StatDefinition, StatMapping, StatSlot, StorageCapability, StratumInfo, SubscribeEntityMessage, SubscribeEventsMessage, SubscribeMessage, SubscriptionEntityType, SubscriptionsManager, SubscriptionsOptions, TIER_ADJECTIVES, TIER_ROLL_MAX, TRAVEL_MAX_DURATION, TaskCancelable, TaskType, TextSpan, TierRange, TransferEntity, UnsubscribeEntityMessage, UnsubscribeEventsMessage, UnsubscribeMessage, UpdateBoundsMessage, UpdateMessage, WAREHOUSE_ALREADY_AT_LOCATION, WAREHOUSE_CAPACITY_EXCEEDED, WAREHOUSE_NOT_FOUND, WAREHOUSE_Z, WARP_HAS_CARGO, WARP_HAS_SCHEDULE, WARP_NOT_FULL_ENERGY, WARP_NO_CAPABILITY, WARP_OUT_OF_RANGE, Warehouse, WarehouseEntity, WarehouseStateInput, WebSocketConnection, WebSocketConnectionOptions, WireCoordinates, WireEntity, availableCapacity$1 as availableCapacity, availableCapacityFromMass, blendCargoStacks, blendComponentStacks, blendCrossGroup, blendStacks, buildEntityDescription, calcCargoItemMass, calcCargoMass, calcEnergyUsage, calcLoadDuration, calcStacksMass, calc_acceleration, calc_craft_duration, calc_craft_energy, calc_energyusage, calc_flighttime, calc_gather_duration, calc_gather_energy, calc_loader_acceleration, calc_loader_flighttime, calc_orbital_altitude, calc_rechargetime, calc_ship_acceleration, calc_ship_flighttime, calc_ship_mass, calc_ship_rechargetime, calc_transfer_duration, calculateFlightTime, calculateLoadTimeBreakdown, calculateRefuelingTime, calculateTransferTime, canMove, capabilityAttributes, capabilityNames, capsHasCrafter, capsHasGatherer, capsHasHauler, capsHasLoaders, capsHasMass, capsHasMovement, capsHasStorage, cargoItemToStack, cargoUtils, cargo_item, categoryColors, categoryFromIndex, categoryIconShapes, categoryIcons, categoryLabel, categoryLabelFromIndex, componentIcon, computeBaseCapacityShip, computeBaseCapacityWarehouse, computeBaseHullmass, computeComponentStats, computeContainerCapabilities, computeContainerT2Capabilities, computeCraftedOutputStats, computeCrafterCapabilities, computeCrafterDrain, computeCrafterSpeed, computeEngineCapabilities, computeEngineDrain, computeEngineThrust, computeEntityStats, computeGathererCapabilities, computeGathererDepth, computeGathererDrain, computeGathererSpeed, computeGathererYield, computeGeneratorCap, computeGeneratorCapabilities, computeGeneratorRech, computeHaulPenalty, computeHaulerCapabilities, computeHaulerDrain, computeInputMass, computeLoaderCapabilities, computeLoaderMass, computeLoaderThrust, computeShipCapabilities, computeShipHullCapabilities, computeStorageCapabilities, computeWarehouseCapabilities, computeWarehouseHullCapabilities, computeWarpRange, container_row, coordsToLocationId, createInventoryAccessor, createProjectedEntity, createScheduleAccessor, decodeCraftedItemStats, decodeStat, decodeStats, Shipload as default, deriveLocation, deriveLocationEpoch, deriveLocationSize, deriveLocationStatic, deriveResourceStats, deriveStatMappings, deriveStrata, deriveStratum, describeItem, describeModule, describeModuleForItem, describeModuleForSlot, deserializeAsset, deserializeComponent, deserializeEntity, deserializeModule, deserializeResource, displayName, distanceBetweenCoordinates, distanceBetweenPoints, encodeGatheredCargoStats, encodeStats, energyPercent, energy_stats, entityDisplayName, estimateDealTravelTime, estimateTravelTime, findItemByCategoryAndTier, findNearbyPlanets, formatMass, formatMassDelta, formatModuleLine, formatTier, gatherer_stats, getCapabilityAttributes, getCategoryInfo, getComponents, getCurrentEpoch, getDepthThreshold, getDestinationLocation, getEligibleResources, getEntityItems, getEntityLayout, getEpochInfo, getFlightOrigin, getItem, getItems, getLocationCandidates, getLocationType, getLocationTypeName, getModuleCapabilityType, getModules, getPlanetSubtype, getPlanetSubtypes, getPositionAt, getRecipe, getResourceTier, getResourceWeight, getResources, getStatDefinitions, getStatMappings, getStatMappingsForCapability, getStatMappingsForStat, getStatName, getSystemName, hasEnergy, hasEnergyForDistance, hasGatherer, hasLoaders, hasMass, hasSchedule, hasSpace$1 as hasSpace, hasSpaceForMass, hasStorage, hasSystem, hash, hash512, isCraftedItem, isFull$1 as isFull, isFullFromMass, isGatherableLocation, isInvertedAttribute, isModuleItem, isRelatedItem, isSubscriptionsDebugEnabled, itemAbbreviations, itemCategory, itemIds, itemOffset, itemTier, itemTypeCode, lerp, loader_stats, location_derived, location_epoch, location_row, location_static, makeContainer, makeShip, makeWarehouse, mapEntity, maxTravelDistance, mergeStacks, moduleAccepts, moduleDisplayName, moduleIcon, moduleSlotTypeToCode, movement_stats, needsRecharge, parseWireEntity, projectEntity, projectEntityAt, projectFromCurrentState, projectFromCurrentStateAt, readCommonBase, removeFromStacks, renderDescription, resolveItem, resolveItemCategory, resolveStats, rollTier, rollWithinTier, rotation, schedule, setSubscriptionsDebug, stackKey, stackToCargoItem, stacksEqual, task, tierColors, tierLabel, tierLabels, toLocation, typeLabel, validateSchedule, warehouse_row };
|
|
3280
|
+
export { AckMessage, ActionsManager, AnyEntity, BASE_ORBITAL_MASS, BLEND_INPUTS_MUST_MATCH, BLEND_REQUIRES_MULTIPLE, BLEND_STAT_LESS_NOT_SUPPORTED, BoundingBox, BoundsDeltaMessage, BoundsSubscriptionHandle, CANCEL_CONTAINS_GROUPED_TASK, CANCEL_PAIRED_HAS_PENDING, CATEGORY_LABELS, COMMIT_ALREADY_SET, COMMIT_CANNOT_MATCH, COMMIT_NOT_SET, COMPANY_NOT_FOUND, CONTAINER_CAPACITY_EXCEEDED, CONTAINER_NOT_FOUND, CONTAINER_Z, CRAFT_ENERGY_DIVISOR, CRAFT_EXCEEDS_ENERGY_CAPACITY, CRAFT_NOT_ENOUGH_ENERGY, CapabilityAttribute, CapabilityInput, CargoData, CargoMassInfo, CargoStack, CategoryIconShape, CategoryInfo, CategoryStacks, ClientMessage, ConnectionState, Container, ContainerEntity, ContainerStateInput, Coordinates, CoordinatesType, CraftedItemCategory, CrafterCapability, DEPLOY_ENTITY_HAS_SCHEDULE, DEPTH_THRESHOLD_T1, DEPTH_THRESHOLD_T2, DEPTH_THRESHOLD_T3, DEPTH_THRESHOLD_T4, DEPTH_THRESHOLD_T5, DESTINATION_CAPACITY_EXCEEDED, DerivedStratum, DescribeOptions, Distance, ENTITY_CAPACITY_EXCEEDED, ENTITY_NO_CRAFTER, EPOCH_NON_ZERO, EPOCH_NOT_READY, ERROR_SYSTEM_ALREADY_INITIALIZED, ERROR_SYSTEM_DISABLED, ERROR_SYSTEM_NOT_INITIALIZED, EnergyCapability, EntitiesManager, Entity, EntityCapabilities, EntityInfo, EntityInstance, EntityInventory, EntityLayout, EntityRefInput, EntitySlot, EntityState, EntitySubscriptionHandle, EntityType, EntityTypeName, EpochInfo, EpochsManager, ErrorMessage, EstimateTravelTimeOptions, EstimatedTravelTime, EventCatchupCompleteMessage, EventMessage, FloatPosition, GAME_NOT_FOUND, GAME_SEED_NOT_SET, GATHERER_DEPTH_MAX_TIER, GATHERER_DEPTH_TABLE, GATHER_EXCEEDS_ENERGY_CAPACITY, GATHER_NOT_ENOUGH_ENERGY, GROUP_DUPLICATE_ENTITY, GROUP_EMPTY, GROUP_ENTITY_NOT_MOVABLE, GROUP_HAUL_CAPACITY_EXCEEDED, GROUP_NOT_FOUND, GROUP_NOT_SAME_LOCATION, GROUP_NOT_SAME_OWNER, GROUP_NO_THRUST, GameState, GathererCapability, GathererDepthParams, HasCapacity, HasCargo, HasCargomass, HasScheduleAndLocation, INSUFFICIENT_BALANCE, INSUFFICIENT_ITEM_QUANTITY, INSUFFICIENT_ITEM_SUPPLY, INVALID_AMOUNT, ITEM_BIOMASS_T1, ITEM_BIOMASS_T10, ITEM_BIOMASS_T2, ITEM_BIOMASS_T3, ITEM_BIOMASS_T4, ITEM_BIOMASS_T5, ITEM_BIOMASS_T6, ITEM_BIOMASS_T7, ITEM_BIOMASS_T8, ITEM_BIOMASS_T9, ITEM_CARGO_ARM, ITEM_CARGO_LINING, ITEM_CARGO_LINING_T2, ITEM_CONTAINER_T1_PACKED, ITEM_CONTAINER_T2_PACKED, ITEM_CRAFTER_T1, ITEM_CRYSTAL_T1, ITEM_CRYSTAL_T10, ITEM_CRYSTAL_T2, ITEM_CRYSTAL_T3, ITEM_CRYSTAL_T4, ITEM_CRYSTAL_T5, ITEM_CRYSTAL_T6, ITEM_CRYSTAL_T7, ITEM_CRYSTAL_T8, ITEM_CRYSTAL_T9, ITEM_DOES_NOT_EXIST, ITEM_ENGINE_T1, ITEM_FOCUSING_ARRAY, ITEM_GAS_T1, ITEM_GAS_T10, ITEM_GAS_T2, ITEM_GAS_T3, ITEM_GAS_T4, ITEM_GAS_T5, ITEM_GAS_T6, ITEM_GAS_T7, ITEM_GAS_T8, ITEM_GAS_T9, ITEM_GATHERER_T1, ITEM_GENERATOR_T1, ITEM_HAULER_T1, ITEM_HULL_PLATES, ITEM_HULL_PLATES_T2, ITEM_LOADER_T1, ITEM_MATTER_CONDUIT, ITEM_NOT_AVAILABLE_AT_LOCATION, ITEM_NOT_DEPLOYABLE, ITEM_NOT_PACKED_ENTITY, ITEM_ORE_T1, ITEM_ORE_T10, ITEM_ORE_T2, ITEM_ORE_T3, ITEM_ORE_T4, ITEM_ORE_T5, ITEM_ORE_T6, ITEM_ORE_T7, ITEM_ORE_T8, ITEM_ORE_T9, ITEM_POWER_CELL, ITEM_REACTION_CHAMBER, ITEM_REGOLITH_T1, ITEM_REGOLITH_T10, ITEM_REGOLITH_T2, ITEM_REGOLITH_T3, ITEM_REGOLITH_T4, ITEM_REGOLITH_T5, ITEM_REGOLITH_T6, ITEM_REGOLITH_T7, ITEM_REGOLITH_T8, ITEM_REGOLITH_T9, ITEM_SHIP_T1_PACKED, ITEM_STORAGE_T1, ITEM_SURVEY_PROBE, ITEM_THRUSTER_CORE, ITEM_TOOL_BIT, ITEM_TYPE_COMPONENT, ITEM_TYPE_ENTITY, ITEM_TYPE_MODULE, ITEM_TYPE_RESOURCE, ITEM_WAREHOUSE_T1_PACKED, ITEM_WARP_T1, InventoryAccessor, Item, ItemType, LOCATION_MAX_DEPTH, LOCATION_MIN_DEPTH, LoadTimeBreakdown, LoaderCapability, Location, LocationStratum, LocationType, LocationsManager, MAX_ORBITAL_ALTITUDE, MIN_ORBITAL_ALTITUDE, MODULE_ANY, MODULE_CARGO_NOT_FOUND, MODULE_CRAFTER, MODULE_ENGINE, MODULE_ENTITY_BUSY, MODULE_GATHERER, MODULE_GENERATOR, MODULE_HAULER, MODULE_LAUNCHER, MODULE_LOADER, MODULE_NOT_MODULE, MODULE_SLOT_EMPTY, MODULE_SLOT_INVALID, MODULE_SLOT_OCCUPIED, MODULE_STORAGE, MODULE_TYPE_MISMATCH, MODULE_WARP, MassCapability, ModuleDescription, ModuleEntry, ModuleType, MovementCapability, index as NFT, NFTCargoItem, NFTCommonBase, NFTInstalledModule, NFTModuleSlot, NO_SCHEDULE, NamedStats, OwnerSubscriptionHandle, PLANET_SUBTYPE_GAS_GIANT, PLANET_SUBTYPE_ICY, PLANET_SUBTYPE_INDUSTRIAL, PLANET_SUBTYPE_OCEAN, PLANET_SUBTYPE_ROCKY, PLANET_SUBTYPE_TERRESTRIAL, PLAYER_ALREADY_JOINED, PLAYER_NOT_FOUND, PLAYER_NOT_JOINED, PRECISION, PackedModule, PackedModuleInput, PingMessage, PlanetSubtypeInfo, platform as PlatformContract, Types$1 as PlatformTypes, Player, PlayerStateInput, PlayersManager, PongMessage, Projectable, ProjectableSnapshot, ProjectedEntity, ProjectionOptions, RECIPE_INPUTS_EXCESS, RECIPE_INPUTS_INSUFFICIENT, RECIPE_INPUTS_INVALID, RECIPE_INPUTS_MIXED, RECIPE_NOT_FOUND, REQUIRES_MORE_THAN_ONE, REQUIRES_POSITIVE_VALUE, RESERVE_TIERS, RESOLVE_COUNT_EXCEEDS_COMPLETED, Recipe, RecipeInput, RecipeInputCategory, RecipeInputItemId, RecipeSlotInput, RenderDescriptionOptions, ReserveTier, ResolvedAttributeGroup, ResolvedItem, ResolvedItemStat, ResolvedItemType, ResolvedModuleSlot, ResourceCategory, ResourceStats, SHIP_ALREADY_THERE, SHIP_ALREADY_TRAVELING, SHIP_CANNOT_BUY_TRAVELING, SHIP_CANNOT_CANCEL_TASK, SHIP_CANNOT_UPDATE_TRAVELING, SHIP_CAPACITY_EXCEEDED, SHIP_CARGO_NOT_LOADED, SHIP_CARGO_NOT_OWNED, SHIP_INVALID_CARGO, SHIP_INVALID_DESTINATION, SHIP_INVALID_TRAVEL_DURATION, SHIP_NOT_ARRIVED, SHIP_NOT_ENOUGH_ENERGY, SHIP_NOT_ENOUGH_ENERGY_CAPACITY, SHIP_NOT_FOUND, SHIP_NOT_IDLE, SHIP_NOT_OWNED, SHIP_NO_COMPLETED_TASKS, SHIP_NO_TASKS_TO_CANCEL, SLOT_FORMULAS, STARTER_ALREADY_CLAIMED, ScheduleAccessor, ScheduleCapability, ScheduleData, Scheduleable, server as ServerContract, ServerMessage, Types as ServerTypes, Ship, ShipCapabilities, ShipEntity, ShipLike, ShipStateInput, Shipload, SlotConsumer, SlotConsumerKind, SnapshotMessage, StackInput, StatDefinition, StatMapping, StatSlot, StorageCapability, StratumInfo, SubscribeEntityMessage, SubscribeEventsMessage, SubscribeMessage, SubscriptionEntityType, SubscriptionsManager, SubscriptionsOptions, TIER_ADJECTIVES, TIER_ROLL_MAX, TRAVEL_MAX_DURATION, TaskCancelable, TaskType, TextSpan, TierRange, TransferEntity, UnsubscribeEntityMessage, UnsubscribeEventsMessage, UnsubscribeMessage, UpdateBoundsMessage, UpdateMessage, WAREHOUSE_ALREADY_AT_LOCATION, WAREHOUSE_CAPACITY_EXCEEDED, WAREHOUSE_NOT_FOUND, WAREHOUSE_Z, WARP_HAS_CARGO, WARP_HAS_SCHEDULE, WARP_NOT_FULL_ENERGY, WARP_NO_CAPABILITY, WARP_OUT_OF_RANGE, Warehouse, WarehouseEntity, WarehouseStateInput, WebSocketConnection, WebSocketConnectionOptions, WireCoordinates, WireEntity, availableCapacity$1 as availableCapacity, availableCapacityFromMass, blendCargoStacks, blendComponentStacks, blendCrossGroup, blendStacks, buildEntityDescription, calcCargoItemMass, calcCargoMass, calcEnergyUsage, calcLoadDuration, calcStacksMass, calc_acceleration, calc_craft_duration, calc_craft_energy, calc_energyusage, calc_flighttime, calc_gather_duration, calc_gather_energy, calc_loader_acceleration, calc_loader_flighttime, calc_orbital_altitude, calc_rechargetime, calc_ship_acceleration, calc_ship_flighttime, calc_ship_mass, calc_ship_rechargetime, calc_transfer_duration, calculateFlightTime, calculateLoadTimeBreakdown, calculateRefuelingTime, calculateTransferTime, canMove, capabilityAttributes, capabilityNames, capsHasCrafter, capsHasGatherer, capsHasHauler, capsHasLoaders, capsHasMass, capsHasMovement, capsHasStorage, cargoItemToStack, cargoUtils, cargo_item, categoryColors, categoryFromIndex, categoryIconShapes, categoryIcons, categoryLabel, categoryLabelFromIndex, componentIcon, computeBaseCapacityShip, computeBaseCapacityWarehouse, computeBaseHullmass, computeComponentStats, computeContainerCapabilities, computeContainerT2Capabilities, computeCraftedOutputStats, computeCrafterCapabilities, computeCrafterDrain, computeCrafterSpeed, computeEngineCapabilities, computeEngineDrain, computeEngineThrust, computeEntityStats, computeGathererCapabilities, computeGathererDepth, computeGathererDrain, computeGathererSpeed, computeGathererYield, computeGeneratorCap, computeGeneratorCapabilities, computeGeneratorRech, computeHaulPenalty, computeHaulerCapabilities, computeHaulerDrain$1 as computeHaulerDrain, computeInputMass, computeLoaderCapabilities, computeLoaderMass, computeLoaderThrust, computeShipCapabilities, computeShipHullCapabilities, computeStorageCapabilities, computeWarehouseCapabilities, computeWarehouseHullCapabilities, computeWarpRange, container_row, coordsToLocationId, createInventoryAccessor, createProjectedEntity, createScheduleAccessor, decodeCraftedItemStats, decodeStat, decodeStats, Shipload as default, deriveLocation, deriveLocationEpoch, deriveLocationSize, deriveLocationStatic, deriveResourceStats, deriveStatMappings, deriveStrata, deriveStratum, describeItem, describeModule, describeModuleForItem, describeModuleForSlot, deserializeAsset, deserializeComponent, deserializeEntity, deserializeModule, deserializeResource, displayName, distanceBetweenCoordinates, distanceBetweenPoints, easeFlightProgress, encodeGatheredCargoStats, encodeStats, energyPercent, energy_stats, entityDisplayName, estimateDealTravelTime, estimateTravelTime, findItemByCategoryAndTier, findNearbyPlanets, flightSpeedFactor, formatMass, formatMassDelta, formatModuleLine, formatTier, gathererDepthForTier, gatherer_stats, getCapabilityAttributes, getCategoryInfo, getComponents, getCurrentEpoch, getDepthThreshold, getDestinationLocation, getEligibleResources, getEntityItems, getEntityLayout, getEpochInfo, getFlightOrigin, getInterpolatedPosition, getItem, getItems, getLocationCandidates, getLocationType, getLocationTypeName, getModuleCapabilityType, getModules, getPlanetSubtype, getPlanetSubtypes, getPositionAt, getRecipe, getResourceTier, getResourceWeight, getResources, getStatDefinitions, getStatMappings, getStatMappingsForCapability, getStatMappingsForStat, getStatName, getSystemName, hasEnergy, hasEnergyForDistance, hasGatherer, hasLoaders, hasMass, hasSchedule, hasSpace$1 as hasSpace, hasSpaceForMass, hasStorage, hasSystem, hash, hash512, interpolateFlightPosition, isCraftedItem, isFull$1 as isFull, isFullFromMass, isGatherableLocation, isInvertedAttribute, isModuleItem, isRelatedItem, isSubscriptionsDebugEnabled, itemAbbreviations, itemCategory, itemIds, itemOffset, itemTier, itemTypeCode, lerp, loader_stats, location_derived, location_epoch, location_row, location_static, makeContainer, makeShip, makeWarehouse, mapEntity, maxTravelDistance, mergeStacks, moduleAccepts, moduleDisplayName, moduleIcon, moduleSlotTypeToCode, movement_stats, needsRecharge, parseWireEntity, projectEntity, projectEntityAt, projectFromCurrentState, projectFromCurrentStateAt, readCommonBase, removeFromStacks, renderDescription, resolveItem, resolveItemCategory, resolveStats, rollTier, rollWithinTier, rotation, schedule, setSubscriptionsDebug, stackKey, stackToCargoItem, stacksEqual, task, tierColors, tierLabel, tierLabels, toLocation, typeLabel, validateSchedule, warehouse_row };
|