factorio-types 1.2.37 → 1.2.39

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/dist/classes.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  // Factorio API reference https://lua-api.factorio.com/latest/index.html
3
3
  // Generated from JSON source https://lua-api.factorio.com/latest/runtime-api.json
4
4
  // Definition source https://github.com/sguest/factorio-types
5
- // Factorio version 2.0.52
5
+ // Factorio version 2.0.55
6
6
  // API version 6
7
7
 
8
8
  declare namespace runtime {
@@ -6416,7 +6416,7 @@ interface LuaEntity extends LuaControl {
6416
6416
  */
6417
6417
  set_inventory_size_override(this: void, inventory_index: defines.inventory, size_override: uint16 | nil, overflow?: LuaInventory): void;
6418
6418
  /**
6419
- * Sets the passenger of this car or spidertron.
6419
+ * Sets the passenger of this car, spidertron, or cargo pod.
6420
6420
  *
6421
6421
  * This differs from {@link LuaEntity::get_driver | runtime:LuaEntity::get_driver} in that the passenger can't drive the car.
6422
6422
  * @param passenger The new passenger. Writing `nil` ejects the current passenger, if any.
@@ -8942,6 +8942,9 @@ interface LuaEquipmentPrototype extends LuaPrototypeBase {
8942
8942
  */
8943
8943
  points?: EquipmentPoint[];
8944
8944
  };
8945
+ readonly solar_panel_performance_at_day: double;
8946
+ readonly solar_panel_performance_at_night: double;
8947
+ readonly solar_panel_solar_coefficient_property: LuaSurfacePropertyPrototype;
8945
8948
  /**
8946
8949
  * The result item when taking this equipment out of an equipment grid, if any.
8947
8950
  */
@@ -11704,19 +11707,30 @@ interface LuaHeatEnergySourcePrototype {
11704
11707
  readonly valid: boolean;
11705
11708
  }
11706
11709
  /**
11707
- * Provides various helper and utility functions. It is accessible through the global object named `helpers`.
11710
+ * Provides various helper and utility functions. It is accessible through the global object named `helpers` in all stages (settings, prototype and runtime).
11708
11711
  */
11709
11712
  interface LuaHelpers {
11710
11713
  /**
11711
11714
  * Goes over all items, entities, tiles, recipes, technologies among other things and logs if the locale is incorrect.
11712
11715
  *
11713
11716
  * Also prints true/false if called from the console.
11717
+ *
11718
+ * Not available in settings and prototype stages.
11714
11719
  */
11715
11720
  check_prototype_translations(this: void): void;
11721
+ /**
11722
+ * Compares 2 version strings.
11723
+ * @param first First version string to compare.
11724
+ * @param second Second version string to compare.
11725
+ * @returns -1 if first is smaller than second, 0 if first equal second, 1 if first is greater than second.
11726
+ */
11727
+ compare_versions(this: void, first: string, second: string): int;
11716
11728
  /**
11717
11729
  * Creates a {@link LuaProfiler | runtime:LuaProfiler}, which is used for measuring script performance.
11718
11730
  *
11719
11731
  * LuaProfiler cannot be serialized.
11732
+ *
11733
+ * Not available in settings and prototype stages.
11720
11734
  * @param stopped Create the timer stopped
11721
11735
  */
11722
11736
  create_profiler(this: void, stopped?: boolean): LuaProfiler;
@@ -11749,11 +11763,15 @@ interface LuaHelpers {
11749
11763
  evaluate_expression(this: void, expression: MathExpression, variables?: Record<string, double>): double;
11750
11764
  /**
11751
11765
  * Checks if the given SoundPath is valid.
11766
+ *
11767
+ * Not available in settings and prototype stages.
11752
11768
  * @param sound_path Path to the sound.
11753
11769
  */
11754
11770
  is_valid_sound_path(this: void, sound_path: SoundPath): boolean;
11755
11771
  /**
11756
11772
  * Checks if the given SpritePath is valid and contains a loaded sprite. The existence of the image is not checked for paths of type `file`.
11773
+ *
11774
+ * Not available in settings and prototype stages.
11757
11775
  * @param sprite_path Path to the image.
11758
11776
  */
11759
11777
  is_valid_sprite_path(this: void, sprite_path: SpritePath): boolean;
@@ -11765,6 +11783,8 @@ interface LuaHelpers {
11765
11783
  json_to_table(this: void, json: string): AnyBasic | null;
11766
11784
  /**
11767
11785
  * Convert a map exchange string to map gen settings and map settings.
11786
+ *
11787
+ * Not available in settings and prototype stages.
11768
11788
  */
11769
11789
  parse_map_exchange_string(this: void, map_exchange_string: string): MapExchangeStringData;
11770
11790
  /**
@@ -11781,9 +11801,13 @@ interface LuaHelpers {
11781
11801
  * @param filename The name of the file. Providing a directory path (ex. `"save/here/example.txt"`) will create the necessary folder structure in `script-output`.
11782
11802
  * @param data The content to write to the file.
11783
11803
  * @param append If `true`, `data` will be appended to the end of the file. Defaults to `false`, which will overwrite any pre-existing file with the new `data`.
11784
- * @param for_player If given, the file will only be written for this `player_index`. Providing `0` will only write to the server's output if present.
11804
+ * @param for_player If given, the file will only be written for this `player_index`. Providing `0` will only write to the server's output if present. `for_player` cannot be used in settings and prototype stages.
11785
11805
  */
11786
11806
  write_file(this: void, filename: string, data: LocalisedString, append?: boolean, for_player?: uint): void;
11807
+ /**
11808
+ * Current version of game
11809
+ */
11810
+ readonly game_version: string;
11787
11811
  /**
11788
11812
  * The class name of this object. Available even when `valid` is false. For LuaStruct objects it may also be suffixed with a dotted path to a member of the struct.
11789
11813
  */
@@ -12189,12 +12213,12 @@ interface LuaItemCommon {
12189
12213
  */
12190
12214
  get_inventory(this: void, inventory: defines.inventory): LuaInventory | null;
12191
12215
  /**
12192
- * Gets the filter at the given index for this upgrade item.
12216
+ * Gets the filter at the given index for this upgrade item. Note that sources (`"from"` type) that are undefined will read as `{type = "item"}`, while destinations (`"to"` type) that are undefined will read as `nil`.
12193
12217
  *
12194
12218
  * In contrast to {@link LuaItemCommon::set_mapper | runtime:LuaItemCommon::set_mapper}, indices past the upgrade item's current size are considered to be out of bounds.
12195
12219
  * @param index The index of the mapper to read.
12196
12220
  */
12197
- get_mapper(this: void, index: uint, type: 'from' | 'to'): UpgradeMapperSource | UpgradeMapperDestination;
12221
+ get_mapper(this: void, index: uint, type: 'from' | 'to'): (UpgradeMapperSource | UpgradeMapperDestination) | null;
12198
12222
  /**
12199
12223
  * Gets the tag with the given name or returns `nil` if it doesn't exist.
12200
12224
  */
@@ -13282,8 +13306,9 @@ interface LuaLogisticSection {
13282
13306
  * This can only be called when the section {@link is manual | runtime:LuaLogisticSection::is_manual}.
13283
13307
  * @param slot_index Index of a slot to set.
13284
13308
  * @param filter The details of the filter to set.
13309
+ * @returns The existing index for the given filter or nil if the filter was successfully set.
13285
13310
  */
13286
- set_slot(this: void, slot_index: LogisticFilterIndex, filter: LogisticFilter): void;
13311
+ set_slot(this: void, slot_index: LogisticFilterIndex, filter: LogisticFilter): LogisticFilterIndex | null;
13287
13312
  /**
13288
13313
  * Whether this section is active. This can only be written to when the section {@link is manual | runtime:LuaLogisticSection::is_manual}.
13289
13314
  */
@@ -15399,7 +15424,7 @@ interface LuaRecord {
15399
15424
  */
15400
15425
  get_entity_filter(this: void, index: uint): ItemFilter | null;
15401
15426
  /**
15402
- * Gets the filter at the given index for this upgrade item.
15427
+ * Gets the filter at the given index for this upgrade item. Note that sources (`"from"` type) that are undefined will read as `{type = "item"}`, while destinations (`"to"` type) that are undefined will read as `nil`.
15403
15428
  *
15404
15429
  * In contrast to {@link LuaRecord::set_mapper | runtime:LuaRecord::set_mapper}, indices past the upgrade item's current size are considered to be out of bounds.
15405
15430
  * @param index The index of the mapper to read.
@@ -18273,7 +18298,7 @@ interface LuaSurfaceCreateEntityParamsHighlightBox extends BaseLuaSurfaceCreateE
18273
18298
  */
18274
18299
  interface LuaSurfaceCreateEntityParamsInserter extends BaseLuaSurfaceCreateEntityParams {
18275
18300
  'conditions': InserterCircuitConditions;
18276
- 'filters': InventoryFilter[];
18301
+ 'filters'?: InserterItemFilter[];
18277
18302
  }
18278
18303
  /**
18279
18304
  *
@@ -2,7 +2,7 @@
2
2
  // Factorio API reference https://lua-api.factorio.com/latest/index.html
3
3
  // Generated from JSON source https://lua-api.factorio.com/latest/runtime-api.json
4
4
  // Definition source https://github.com/sguest/factorio-types
5
- // Factorio version 2.0.52
5
+ // Factorio version 2.0.55
6
6
  // API version 6
7
7
 
8
8
  declare namespace runtime {
@@ -181,9 +181,6 @@ interface AsteroidChunkPrototypeFilter {
181
181
  */
182
182
  invert?: boolean;
183
183
  }
184
- /**
185
- * Used by {@link MapSettings | runtime:MapSettings} and {@link MapAndDifficultySettings | runtime:MapAndDifficultySettings}.
186
- */
187
184
  interface AsteroidMapSettings {
188
185
  spawning_rate: double;
189
186
  max_ray_portals_expanded_per_tick: uint;
@@ -2606,6 +2603,24 @@ interface InserterCircuitConditions {
2606
2603
  circuit?: CircuitCondition;
2607
2604
  logistics?: CircuitCondition;
2608
2605
  }
2606
+ interface InserterItemFilter {
2607
+ /**
2608
+ * Position of the corresponding filter slot.
2609
+ */
2610
+ index: uint;
2611
+ /**
2612
+ * Item prototype name of the item to filter.
2613
+ */
2614
+ name: string;
2615
+ /**
2616
+ * Quality prototype name of the item to filter.
2617
+ */
2618
+ quality?: string;
2619
+ /**
2620
+ * Quality comparator to use for the quality filter.
2621
+ */
2622
+ comparator?: string;
2623
+ }
2609
2624
  interface InventoryFilter {
2610
2625
  /**
2611
2626
  * Position of the corresponding filter slot.
@@ -8162,27 +8177,28 @@ interface UnitSpawnDefinition {
8162
8177
  spawn_points: SpawnPointDefinition[];
8163
8178
  }
8164
8179
  interface UpgradeMapperDestination {
8180
+ type: 'item' | 'entity';
8165
8181
  /**
8166
- * `"item"`, or `"entity"`.
8167
- */
8168
- type: string;
8169
- /**
8170
- * Name of the item, or entity.
8182
+ * Name of the item or entity.
8171
8183
  */
8172
8184
  name?: string;
8173
8185
  /**
8174
- * Name of the quality.
8186
+ * Name of the quality prototype.
8175
8187
  */
8176
8188
  quality?: string;
8177
8189
  /**
8178
- * when type is `"item"` and the mapper is configured to install modules the limit per machine. If `0` then no limit.
8190
+ * When upgrading modules, this defines the maximum number of this module to be installed in the destination entity. `0` or `nil` means no limit.
8179
8191
  */
8180
- count?: uint;
8192
+ module_limit?: uint16;
8193
+ /**
8194
+ * When upgrading entities, this defines explicit modules to be installed in the destination entity. Lists empty slots as `{}`.
8195
+ */
8196
+ module_slots?: ItemIDAndQualityIDPair[];
8181
8197
  }
8182
8198
  interface UpgradeMapperSource {
8183
8199
  type: 'item' | 'entity';
8184
8200
  /**
8185
- * Name of the item, or entity.
8201
+ * Name of the item or entity.
8186
8202
  */
8187
8203
  name?: string;
8188
8204
  /**
@@ -8193,6 +8209,10 @@ interface UpgradeMapperSource {
8193
8209
  * The quality comparison type.
8194
8210
  */
8195
8211
  comparator?: ComparatorString;
8212
+ /**
8213
+ * When upgrading modules, this defines the specific entities to apply the upgrade to. `nil` applies it to all entities.
8214
+ */
8215
+ module_filter?: EntityIDFilter;
8196
8216
  }
8197
8217
  /**
8198
8218
  * Defines the mode of operation for a {@link ValvePrototype | prototype:ValvePrototype}.
@@ -2,7 +2,7 @@
2
2
  // Factorio API reference https://lua-api.factorio.com/latest/index.html
3
3
  // Generated from JSON source https://lua-api.factorio.com/latest/prototype-api.json
4
4
  // Definition source https://github.com/sguest/factorio-types
5
- // Factorio version 2.0.52
5
+ // Factorio version 2.0.55
6
6
  // API version 6
7
7
 
8
8
  declare namespace prototype {
package/dist/defines.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  // Factorio API reference https://lua-api.factorio.com/latest/index.html
3
3
  // Generated from JSON source https://lua-api.factorio.com/latest/runtime-api.json
4
4
  // Definition source https://github.com/sguest/factorio-types
5
- // Factorio version 2.0.52
5
+ // Factorio version 2.0.55
6
6
  // API version 6
7
7
 
8
8
  declare namespace defines {
@@ -442,7 +442,7 @@ enum distraction {
442
442
  }
443
443
  enum entity_status {
444
444
  /**
445
- * Only used if set through {@link LuaEntity::status | runtime:LuaEntity::status} or {@link ContainerPrototype::default_status | prototype:ContainerPrototype::default_status}.
445
+ * Only used if set through {@link ContainerPrototype::default_status | prototype:ContainerPrototype::default_status}.
446
446
  */
447
447
  broken = 3,
448
448
  /**
@@ -1235,14 +1235,23 @@ enum inventory {
1235
1235
  artillery_turret_ammo = 46,
1236
1236
  artillery_wagon_ammo = 47,
1237
1237
  /**
1238
- * Used when items are ejected or items held by inserters cannot be inserted due to changing the recipe with the circuit network.
1238
+ * Used for ejected items, or items held by inserters that can't be inserted due the recipe being changed with the circuit network.
1239
1239
  */
1240
1240
  assembling_machine_dump = 26,
1241
+ /**
1242
+ * Deprecated, replaced by `"crafter_input"`.
1243
+ */
1241
1244
  assembling_machine_input = 23,
1245
+ /**
1246
+ * Deprecated, replaced by `"crafter_modules"`.
1247
+ */
1242
1248
  assembling_machine_modules = 25,
1249
+ /**
1250
+ * Deprecated, replaced by `"crafter_output"`.
1251
+ */
1243
1252
  assembling_machine_output = 24,
1244
1253
  /**
1245
- * Used for spoil result items that do not fit into the recipe slots and for items that are ejected when changing the recipe via remote view.
1254
+ * Deprecated, replaced by `"crafter_trash"`.
1246
1255
  */
1247
1256
  assembling_machine_trash = 27,
1248
1257
  asteroid_collector_output = 63,
@@ -1266,17 +1275,29 @@ enum inventory {
1266
1275
  crafter_input = 59,
1267
1276
  crafter_modules = 61,
1268
1277
  crafter_output = 60,
1278
+ /**
1279
+ * Used for spoil result items that do not fit into the recipe slots, and for items that are ejected when changing the recipe via remote view.
1280
+ */
1269
1281
  crafter_trash = 62,
1270
1282
  editor_ammo = 17,
1271
1283
  editor_armor = 18,
1272
1284
  editor_guns = 16,
1273
1285
  editor_main = 15,
1274
1286
  fuel = 0,
1287
+ /**
1288
+ * Deprecated, replaced by `"crafter_modules"`.
1289
+ */
1275
1290
  furnace_modules = 6,
1291
+ /**
1292
+ * Deprecated, replaced by `"crafter_output"`.
1293
+ */
1276
1294
  furnace_result = 5,
1295
+ /**
1296
+ * Deprecated, replaced by `"crafter_input"`.
1297
+ */
1277
1298
  furnace_source = 4,
1278
1299
  /**
1279
- * Used for spoil result items that do not fit into the recipe slots.
1300
+ * Deprecated, replaced by `"crafter_trash"`.
1280
1301
  */
1281
1302
  furnace_trash = 7,
1282
1303
  god_main = 14,
@@ -1294,8 +1315,17 @@ enum inventory {
1294
1315
  roboport_robot = 19,
1295
1316
  robot_cargo = 21,
1296
1317
  robot_repair = 22,
1318
+ /**
1319
+ * Deprecated, replaced by `"crafter_input"`.
1320
+ */
1297
1321
  rocket_silo_input = 35,
1322
+ /**
1323
+ * Deprecated, replaced by `"crafter_modules"`.
1324
+ */
1298
1325
  rocket_silo_modules = 37,
1326
+ /**
1327
+ * Deprecated, replaced by `"crafter_output"`.
1328
+ */
1299
1329
  rocket_silo_output = 36,
1300
1330
  rocket_silo_rocket = 33,
1301
1331
  rocket_silo_trash = 34,
@@ -2282,8 +2312,17 @@ enum wire_connector_id {
2282
2312
  power_switch_right_copper = 8
2283
2313
  }
2284
2314
  enum wire_origin {
2315
+ /**
2316
+ * These wires can be modified by players, scripts, and the game. They are visible to the player if the entity's `draw_circuit_wires` prototype property is set to `true` and both ends of it are on the same surface.
2317
+ */
2285
2318
  player = 0,
2319
+ /**
2320
+ * These wires can only be modified by the game. They are not visible to the player, irrespective of the `draw_circuit_wires` prototype property.
2321
+ */
2286
2322
  radars = 2,
2323
+ /**
2324
+ * These wires can be modified by scripts and the game. They are not visible to the player, irrespective of the `draw_circuit_wires` prototype property.
2325
+ */
2287
2326
  script = 1
2288
2327
  }
2289
2328
  enum wire_type {
package/dist/events.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  // Factorio API reference https://lua-api.factorio.com/latest/index.html
3
3
  // Generated from JSON source https://lua-api.factorio.com/latest/runtime-api.json
4
4
  // Definition source https://github.com/sguest/factorio-types
5
- // Factorio version 2.0.52
5
+ // Factorio version 2.0.55
6
6
  // API version 6
7
7
 
8
8
  declare namespace runtime {
package/dist/global.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  // Factorio API reference https://lua-api.factorio.com/latest/index.html
3
3
  // Generated from JSON source https://lua-api.factorio.com/latest/runtime-api.json
4
4
  // Definition source https://github.com/sguest/factorio-types
5
- // Factorio version 2.0.52
5
+ // Factorio version 2.0.55
6
6
  // API version 6
7
7
 
8
8
  /**
@@ -2,7 +2,7 @@
2
2
  // Factorio API reference https://lua-api.factorio.com/latest/index.html
3
3
  // Generated from JSON source https://lua-api.factorio.com/latest/prototype-api.json
4
4
  // Definition source https://github.com/sguest/factorio-types
5
- // Factorio version 2.0.52
5
+ // Factorio version 2.0.55
6
6
  // API version 6
7
7
 
8
8
  declare namespace prototype {
@@ -5145,6 +5145,10 @@ interface LandMinePrototype extends EntityWithOwnerPrototype {
5145
5145
  */
5146
5146
  trigger_collision_mask?: CollisionMaskConnector;
5147
5147
  trigger_force?: ForceCondition;
5148
+ /**
5149
+ * Time between checks to detonate due to nearby enemies, in ticks. A larger time will be more performant.
5150
+ */
5151
+ trigger_interval?: uint32;
5148
5152
  trigger_radius: double;
5149
5153
  }
5150
5154
  interface LaneSplitterPrototype extends TransportBeltConnectablePrototype {
@@ -8003,10 +8007,18 @@ interface SmokeWithTriggerPrototype extends SmokePrototype {
8003
8007
  * A {@link portable solar panel | https://wiki.factorio.com/Portable_solar_panel}.
8004
8008
  */
8005
8009
  interface SolarPanelEquipmentPrototype extends EquipmentPrototype {
8010
+ performance_at_day?: double;
8011
+ performance_at_night?: double;
8006
8012
  /**
8007
8013
  * How much power should be provided.
8008
8014
  */
8009
8015
  power: Energy;
8016
+ /**
8017
+ * Surface property must have a positive {@link default value | prototype:SurfacePropertyPrototype::default_value}. When {@link SolarPanelEquipmentPrototype::solar_coefficient_property | prototype:SolarPanelEquipmentPrototype::solar_coefficient_property} is set to point at a different surface property than "solar-power", then {@link LuaSurface::solar_power_multiplier | runtime:LuaSurface::solar_power_multiplier} and {@link SpaceLocationPrototype::solar_power_in_space | prototype:SpaceLocationPrototype::solar_power_in_space} will be ignored as the solar panel power output will be only affected by value of this surface property set on the surface using {@link PlanetPrototype::surface_properties | prototype:PlanetPrototype::surface_properties} or {@link LuaSurface::set_property | runtime:LuaSurface::set_property}.
8018
+ *
8019
+ * Due to equipment grid overall description, when solar_coefficient_property is not solar-power, a different locale will be used to show total energy production of solar panels: `description.solar-panel-power-X` where X is the surface property name.
8020
+ */
8021
+ solar_coefficient_property?: SurfacePropertyID;
8010
8022
  }
8011
8023
  /**
8012
8024
  * A {@link solar panel | https://wiki.factorio.com/Solar_panel}.
@@ -8674,11 +8686,11 @@ interface StickerPrototype extends EntityPrototype {
8674
8686
  /**
8675
8687
  * The `hidden` property of stickers is hardcoded to `true`.
8676
8688
  */
8677
- hidden?: boolean;
8689
+ hidden: true;
8678
8690
  /**
8679
8691
  * The `hidden_in_factoriopedia` property of stickers is hardcoded to `true`.
8680
8692
  */
8681
- hidden_in_factoriopedia?: boolean;
8693
+ hidden_in_factoriopedia: true;
8682
8694
  render_layer?: RenderLayer;
8683
8695
  /**
8684
8696
  * Using this property marks the sticker as a "selection sticker", meaning that the selection box will be rendered around the entity when the sticker is on it.
@@ -9761,6 +9773,14 @@ interface UtilityConstants extends PrototypeBase {
9761
9773
  asteroid_position_offset_to_speed_coefficient: double;
9762
9774
  asteroid_spawning_offset: SimpleBoundingBox;
9763
9775
  asteroid_spawning_with_random_orientation_max_speed: double;
9776
+ /**
9777
+ * Will be clamped to the range [2, 100].
9778
+ */
9779
+ blueprint_big_slots_per_row: uint8;
9780
+ /**
9781
+ * Will be clamped to the range [2, 100].
9782
+ */
9783
+ blueprint_small_slots_per_row: uint8;
9764
9784
  /**
9765
9785
  * The base game uses more entries here that are applied via the ammo-category.lua file.
9766
9786
  */
@@ -9788,6 +9808,10 @@ interface UtilityConstants extends PrototypeBase {
9788
9808
  color_filters?: ColorFilterData[];
9789
9809
  construction_robots_use_busy_robots_queue: boolean;
9790
9810
  count_button_size: int32;
9811
+ /**
9812
+ * Will be clamped to the range [1, 100].
9813
+ */
9814
+ crafting_queue_slots_per_row: uint8;
9791
9815
  daytime_color_lookup: DaytimeColorLookupTable;
9792
9816
  deconstruct_mark_tint: Color;
9793
9817
  default_alert_icon_scale: float;
@@ -9879,9 +9903,9 @@ interface UtilityConstants extends PrototypeBase {
9879
9903
  */
9880
9904
  inserter_hand_stack_max_sprites: ItemCountType;
9881
9905
  /**
9882
- * Must be in range [1, 100].
9906
+ * Will be clamped to the range [1, 100].
9883
9907
  */
9884
- inventory_width: uint32;
9908
+ inventory_width: uint8;
9885
9909
  item_ammo_magazine_left_bar_color: Color;
9886
9910
  item_default_random_tint_strength: Color;
9887
9911
  /**
@@ -9912,6 +9936,10 @@ interface UtilityConstants extends PrototypeBase {
9912
9936
  logistic_gui_selected_network_highlight_tint: Color;
9913
9937
  logistic_gui_unselected_network_highlight_tint: Color;
9914
9938
  logistic_robots_use_busy_robots_queue: boolean;
9939
+ /**
9940
+ * Will be clamped to the range [2, 100].
9941
+ */
9942
+ logistic_slots_per_row: uint8;
9915
9943
  low_energy_robot_estimate_multiplier: double;
9916
9944
  main_menu_background_image_location: FileName;
9917
9945
  main_menu_background_vignette_intensity: float;
@@ -9937,9 +9965,9 @@ interface UtilityConstants extends PrototypeBase {
9937
9965
  minimum_recipe_overload_multiplier: uint32;
9938
9966
  missing_preview_sprite_location: FileName;
9939
9967
  /**
9940
- * Must be in range [1, 100].
9968
+ * Will be clamped to the range [1, 100].
9941
9969
  */
9942
- module_inventory_width: uint32;
9970
+ module_inventory_width: uint8;
9943
9971
  /**
9944
9972
  * Silently clamped to be between 0 and 1.
9945
9973
  */
@@ -9957,11 +9985,11 @@ interface UtilityConstants extends PrototypeBase {
9957
9985
  rocket_lift_weight: Weight;
9958
9986
  script_command_console_chat_color: Color;
9959
9987
  /**
9960
- * Must be in range [1, 100].
9988
+ * Will be clamped to the range [1, 100].
9961
9989
  */
9962
9990
  select_group_row_count: uint8;
9963
9991
  /**
9964
- * Must be in range [1, 100].
9992
+ * Will be clamped to the range [1, 100].
9965
9993
  */
9966
9994
  select_slot_row_count: uint8;
9967
9995
  selected_chart_search_highlight: Color;
@@ -9975,6 +10003,10 @@ interface UtilityConstants extends PrototypeBase {
9975
10003
  * Variables: speed, thrust, weight, width, height
9976
10004
  */
9977
10005
  space_platform_acceleration_expression: MathExpression;
10006
+ /**
10007
+ * How many asteroid chunks should be processed per tick, see {@link space_platform_max_relative_speed_deviation_for_asteroid_chunks_update | prototype:UtilityConstants::space_platform_max_relative_speed_deviation_for_asteroid_chunks_update}.
10008
+ */
10009
+ space_platform_asteroid_chunk_trajectory_updates_per_tick: uint32;
9978
10010
  /**
9979
10011
  * Determines how fast space platforms will send items in drop slots to the surface. Each item type has its own cooldown.
9980
10012
  */
@@ -9983,6 +10015,10 @@ interface UtilityConstants extends PrototypeBase {
9983
10015
  * Delay after manual transfer until space platform sends items in drop slots to the surface. Overrides remaining space_platform_dump_cooldown in this instance.
9984
10016
  */
9985
10017
  space_platform_manual_dump_cooldown: uint32;
10018
+ /**
10019
+ * Space platform remembers relative speed range which asteroids use while it moves. When the range is larger than the specified deviation, the platform will start updating cached trajectories of all asteroid chunks over multiple ticks.
10020
+ */
10021
+ space_platform_max_relative_speed_deviation_for_asteroid_chunks_update: float;
9986
10022
  space_platform_max_size: SimpleBoundingBox;
9987
10023
  space_platform_relative_speed_factor: double;
9988
10024
  space_platform_starfield_movement_vector: Vector;
@@ -10008,6 +10044,10 @@ interface UtilityConstants extends PrototypeBase {
10008
10044
  train_temporary_stop_wait_time: uint32;
10009
10045
  train_time_wait_condition_default: uint32;
10010
10046
  train_visualization: TrainVisualizationConstants;
10047
+ /**
10048
+ * Will be clamped to the range [1, 100].
10049
+ */
10050
+ trash_inventory_width: uint8;
10011
10051
  tree_leaf_distortion_distortion_far: Vector;
10012
10052
  tree_leaf_distortion_distortion_near: Vector;
10013
10053
  tree_leaf_distortion_speed_far: Vector;
package/dist/types.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  // Factorio API reference https://lua-api.factorio.com/latest/index.html
3
3
  // Generated from JSON source https://lua-api.factorio.com/latest/prototype-api.json
4
4
  // Definition source https://github.com/sguest/factorio-types
5
- // Factorio version 2.0.52
5
+ // Factorio version 2.0.55
6
6
  // API version 6
7
7
 
8
8
  declare namespace prototype {
@@ -4462,7 +4462,7 @@ interface FastReplaceTipTrigger extends CountBasedTipTrigger {
4462
4462
  type: 'fast-replace';
4463
4463
  }
4464
4464
  /**
4465
- * A dictionary of feature flags and their status. It can be used to adjust prototypes based on whether the feature flags are enabled.
4465
+ * A dictionary of feature flags and their status. It can be used to adjust prototypes based on whether the feature flags are enabled. It is accessible through the global object named `feature_flags`.
4466
4466
  * @example ```
4467
4467
  -- sets coal to spoil only when the spoiling feature flag is enabled
4468
4468
  if feature_flags["spoiling"] then
@@ -6657,10 +6657,10 @@ if mods["pizza"] then
6657
6657
  end
6658
6658
  ```
6659
6659
  * @example ```
6660
- -- when the only active mod is the space-age mod with version 1.2.0
6660
+ -- when the only active mod is the space-age mod with version 2.0.7
6661
6661
  -- then this logs
6662
6662
  for name, version in pairs(mods) do
6663
- log(name .. " version " .. version) -- => space-age version 1.2.0
6663
+ log(name .. " version " .. version) -- => space-age version 2.0.7
6664
6664
  end
6665
6665
  ```
6666
6666
  */
@@ -8886,7 +8886,7 @@ interface SetTileTriggerEffectItem extends TriggerEffectItem {
8886
8886
  type: 'set-tile';
8887
8887
  }
8888
8888
  /**
8889
- * A struct that provides access to the user-set values of startup {@link mod settings | https://wiki.factorio.com/Tutorial:Mod_settings}.
8889
+ * A struct that provides access to the user-set values of startup {@link mod settings | https://wiki.factorio.com/Tutorial:Mod_settings}. It is accessible through the global object named `settings`.
8890
8890
  * @example ```
8891
8891
  -- Accessing the value of a mod setting
8892
8892
  local val = settings.startup["my-mod-setting-name"].value
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "factorio-types",
3
- "version": "1.2.37",
3
+ "version": "1.2.39",
4
4
  "description": "Typescript declarations for the Factorio mod API",
5
5
  "main": "index.d.ts",
6
6
  "repository": "https://github.com/sguest/factorio-types.git",
@@ -23,7 +23,7 @@
23
23
  "src/**/*.d.ts",
24
24
  "dist/**/*.d.ts"
25
25
  ],
26
- "factorioVersion": "2.0.52",
26
+ "factorioVersion": "2.0.55",
27
27
  "dependencies": {
28
28
  "lua-types": "^2.13.1"
29
29
  },