factorio-types 1.2.46 → 1.2.48

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.64
5
+ // Factorio version 2.0.66
6
6
  // API version 6
7
7
 
8
8
  declare namespace runtime {
@@ -89,7 +89,7 @@ interface LuaAchievementPrototype extends LuaPrototypeBase {
89
89
  readonly minimum_damage?: float;
90
90
  readonly minimum_distance?: double;
91
91
  readonly minimum_energy_produced?: double;
92
- readonly module?: string[];
92
+ readonly module?: LuaItemPrototype[];
93
93
  readonly more_than_manually?: boolean;
94
94
  readonly not_to_kill?: LuaEntityPrototype;
95
95
  /**
@@ -5878,7 +5878,7 @@ interface LuaDecorativePrototype extends LuaPrototypeBase {
5878
5878
  */
5879
5879
  readonly object_name: string;
5880
5880
  readonly placed_effect?: TriggerEffectItem[];
5881
- readonly render_layer: string;
5881
+ readonly render_layer: RenderLayer;
5882
5882
  readonly target_count: uint;
5883
5883
  readonly trigger_effect?: TriggerEffectItem[];
5884
5884
  /**
@@ -6587,7 +6587,7 @@ interface LuaEntity extends LuaControl {
6587
6587
  */
6588
6588
  play_note(this: void, instrument: uint, note: uint, stop_playing_sounds?: boolean): boolean;
6589
6589
  /**
6590
- * Registers the given tree in this agricultral tower.
6590
+ * Registers the given tree in this agricultural tower.
6591
6591
  *
6592
6592
  * If the tree is not within range of the tower it will not be registered.
6593
6593
  *
@@ -6633,15 +6633,15 @@ interface LuaEntity extends LuaControl {
6633
6633
  request_to_open(this: void, force: ForceID, extra_time?: uint): void;
6634
6634
  /**
6635
6635
  * Revive a ghost, which turns it from a ghost into a real entity or tile.
6636
- * @param table.return_item_request_proxy If `true` the function will return item request proxy as the third return value.
6637
6636
  * @param table.raise_revive If true, and an entity ghost; {@link script_raised_revive | runtime:script_raised_revive} will be called. Else if true, and a tile ghost; {@link script_raised_set_tiles | runtime:script_raised_set_tiles} will be called.
6637
+ * @param table.overflow Items that would be deleted will be transferred to this inventory. Must be a script inventory or inventory of other entity. Inventory references obtained from proxy container are not allowed.
6638
6638
  * @returns [0] - Any items the new real entity collided with or `nil` if the ghost could not be revived.
6639
6639
  * @returns [1] - The revived entity if an entity ghost was successfully revived.
6640
- * @returns [2] - The item request proxy if it was requested with `return_item_request_proxy`.
6640
+ * @returns [2] - The item request proxy if one was created.
6641
6641
  */
6642
6642
  revive(this: void, table: {
6643
- return_item_request_proxy?: boolean;
6644
6643
  raise_revive?: boolean;
6644
+ overflow?: LuaInventory;
6645
6645
  }): LuaMultiReturn<[
6646
6646
  Record<string, uint> | null,
6647
6647
  LuaEntity | null,
@@ -6742,12 +6742,14 @@ interface LuaEntity extends LuaControl {
6742
6742
  /**
6743
6743
  * Revives a ghost silently, so the revival makes no sound and no smoke is created.
6744
6744
  * @param table.raise_revive If true, and an entity ghost; {@link script_raised_revive | runtime:script_raised_revive} will be called. Else if true, and a tile ghost; {@link script_raised_set_tiles | runtime:script_raised_set_tiles} will be called.
6745
+ * @param table.overflow Items that would be deleted will be transferred to this inventory. Must be a script inventory or inventory of other entity. Inventory references obtained from proxy container are not allowed.
6745
6746
  * @returns [0] - Any items the new real entity collided with or `nil` if the ghost could not be revived.
6746
6747
  * @returns [1] - The revived entity if an entity ghost was successfully revived.
6747
- * @returns [2] - The item request proxy.
6748
+ * @returns [2] - The item request proxy if one was created.
6748
6749
  */
6749
6750
  silent_revive(this: void, table: {
6750
6751
  raise_revive?: boolean;
6752
+ overflow?: LuaInventory;
6751
6753
  }): LuaMultiReturn<[
6752
6754
  ItemWithQualityCounts,
6753
6755
  LuaEntity | null,
@@ -7059,7 +7061,7 @@ interface LuaEntity extends LuaControl {
7059
7061
  /**
7060
7062
  * Icon visible on the display panel. Can be written only when it is not set by control behavior.
7061
7063
  */
7062
- display_panel_icon: SignalID;
7064
+ display_panel_icon?: SignalID;
7063
7065
  display_panel_show_in_chart: boolean;
7064
7066
  /**
7065
7067
  * Text visible on the display panel. Can be written only when it is not set by control behavior.
@@ -7372,9 +7374,9 @@ interface LuaEntity extends LuaControl {
7372
7374
  /**
7373
7375
  * Not minable entities can still be destroyed.
7374
7376
  *
7375
- * Tells if entity reports as being minable right now. This takes into account minable_flag and entity specific conditions (for example rail under rolling stocks is not minable, vehicle with passenger is not minable).
7377
+ * Tells if entity reports as being minable right now. This takes into account `minable_flag` and entity specific conditions (for example rail under rolling stocks is not minable, vehicle with passenger is not minable).
7376
7378
  *
7377
- * Write to this field since 2.0.26 is deprecated and it will result in write to minable_flag instead.
7379
+ * Write to this field since 2.0.26 is deprecated and it will result in write to `minable_flag` instead.
7378
7380
  */
7379
7381
  minable: boolean;
7380
7382
  /**
@@ -7869,6 +7871,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
7869
7871
  get_inserter_rotation_speed(this: void, quality?: QualityID): double | null;
7870
7872
  /**
7871
7873
  * Gets the base size of the given inventory on this entity or `nil` if the given inventory doesn't exist.
7874
+ * @param quality Defaults to `"normal"`.
7872
7875
  */
7873
7876
  get_inventory_size(this: void, index: defines.inventory, quality?: QualityID): uint | null;
7874
7877
  /**
@@ -8389,6 +8392,14 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
8389
8392
  readonly held_items_offset?: float;
8390
8393
  readonly held_items_spread?: float;
8391
8394
  readonly hide_resistances?: boolean;
8395
+ /**
8396
+ * The definition of where and how the alt-mode icons of this entity should be drawn.
8397
+ */
8398
+ readonly icon_draw_specification: IconDrawSpecification;
8399
+ /**
8400
+ * The icon positioning for inventories of this entity, if defined.
8401
+ */
8402
+ readonly icons_positioning?: IconSequencePositioning[];
8392
8403
  /**
8393
8404
  * A vector of the gun prototypes of this car, spider vehicle, artillery wagon, or turret.
8394
8405
  */
@@ -8538,6 +8549,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
8538
8549
  * The max belt stack size for this loader.
8539
8550
  */
8540
8551
  readonly loader_max_belt_stack_size?: uint8;
8552
+ readonly loader_respect_insert_limits?: boolean;
8541
8553
  /**
8542
8554
  * True if this loader will not drop items for which total amount is less than a full belt stack.
8543
8555
  */
@@ -9654,7 +9666,7 @@ interface LuaFluidBoxPrototype {
9654
9666
  /**
9655
9667
  * The render layer.
9656
9668
  */
9657
- readonly render_layer: string;
9669
+ readonly render_layer: RenderLayer;
9658
9670
  /**
9659
9671
  * The secondary draw orders for the 4 possible connection directions.
9660
9672
  */
@@ -9825,6 +9837,7 @@ interface LuaForce {
9825
9837
  copy_from(this: void, force: ForceID): void;
9826
9838
  /**
9827
9839
  * Creates the given group if it doesn't already exist.
9840
+ * @param type Defaults to `defines.logistic_group_type.with_trash`.
9828
9841
  */
9829
9842
  create_logistic_group(this: void, name: string, type?: defines.logistic_group_type): void;
9830
9843
  /**
@@ -9840,6 +9853,7 @@ interface LuaForce {
9840
9853
  }): LuaSpacePlatform | null;
9841
9854
  /**
9842
9855
  * Deletes the given logistic group if it exists.
9856
+ * @param type Defaults to `defines.logistic_group_type.with_trash`.
9843
9857
  */
9844
9858
  delete_logistic_group(this: void, name: string, type?: defines.logistic_group_type): void;
9845
9859
  /**
@@ -9961,10 +9975,12 @@ interface LuaForce {
9961
9975
  get_linked_inventory(this: void, prototype: EntityID, link_id: uint): LuaInventory | null;
9962
9976
  /**
9963
9977
  * Gets the information about the given logistic group.
9978
+ * @param type Defaults to `defines.logistic_group_type.with_trash`.
9964
9979
  */
9965
9980
  get_logistic_group(this: void, name: string, type?: defines.logistic_group_type): LogisticGroup | null;
9966
9981
  /**
9967
9982
  * Gets the names of the current logistic groups.
9983
+ * @param type Defaults to `defines.logistic_group_type.with_trash`.
9968
9984
  */
9969
9985
  get_logistic_groups(this: void, type?: defines.logistic_group_type): string[];
9970
9986
  get_spawn_position(this: void, surface: SurfaceIdentification): MapPosition;
@@ -10752,6 +10768,12 @@ interface LuaGameScript {
10752
10768
  * @param player The player to unmute.
10753
10769
  */
10754
10770
  unmute_player(this: void, player: PlayerIdentification): void;
10771
+ /**
10772
+ * Whether players who are not {@link admins | runtime:LuaPlayer::admin} can access all debug settings. Set this to false to disallow access to most debug settings for non-admins.
10773
+ *
10774
+ * The following debug settings are always available to all players: `"show-fps"`, `"show-clock"`, `"show-time-to-next-autosave"`, `"show-detailed-info"`, `"show-time-usage"`, `"show-entity-time-usage"`, `"show-gpu-time-usage"`, `"show-sprite-counts"`, `"show-particle-counts"`, `"show-collector-navmesh-time-usage"`, `"show-lua-object-statistics"`, `"show-heat-buffer-info"`, `"show-multiplayer-waiting-icon"`, `"show-multiplayer-statistics"`, `"show-multiplayer-server-name"`, `"show-debug-info-in-tooltips"`, `"show-resistances-in-tooltips-always"`, `"hide-mod-guis"`, `"show-tile-grid"`, `"show-blueprint-grid"`, `"show-intermediate-volume-of-working-sounds"`, `"show-decorative-names"`, `"allow-increased-zoom"`, `"show-train-no-path-details"`, `"show-entity-tick"`, `"show-update-tick"`
10775
+ */
10776
+ allow_debug_settings: boolean;
10755
10777
  /**
10756
10778
  * If the tips are allowed to be activated in this scenario, it is false by default.
10757
10779
  *
@@ -14231,6 +14253,8 @@ interface LuaPlayer extends LuaControl {
14231
14253
  add_custom_alert(this: void, entity: LuaEntity, icon: SignalID, message: LocalisedString, show_on_map: boolean): void;
14232
14254
  /**
14233
14255
  * Adds a pin to this player for the given pin specification. Either entity, player, or surface and position must be defined.
14256
+ * @param table.preview_distance Defaults to `16`.
14257
+ * @param table.always_visible Defaults to `true`.
14234
14258
  * @param table.entity The entity to pin.
14235
14259
  * @param table.player The player to pin.
14236
14260
  * @param table.surface The surface to create the pin on.
@@ -16123,6 +16147,10 @@ interface LuaRecord {
16123
16147
  * Is this blueprint record a preview? A preview record must be synced by the player before entity and tile data can be read.
16124
16148
  */
16125
16149
  readonly is_blueprint_preview: boolean;
16150
+ /**
16151
+ * Checks if this record is in a preview state.
16152
+ */
16153
+ readonly is_preview: boolean;
16126
16154
  /**
16127
16155
  * The current count of mappers in the upgrade item.
16128
16156
  */
@@ -16276,6 +16304,10 @@ interface LuaRenderObject {
16276
16304
  * Dash length of this line.
16277
16305
  */
16278
16306
  dash_length: double;
16307
+ /**
16308
+ * Starting offset to apply to dashes of this line. Cannot be greater than dash_length + gap_length.
16309
+ */
16310
+ dash_offset: double;
16279
16311
  /**
16280
16312
  * If this object is being drawn on the ground, under most entities and sprites.
16281
16313
  *
@@ -18988,7 +19020,7 @@ interface BaseLuaSurfaceCreateEntityParams {
18988
19020
  */
18989
19021
  'burner_fuel_inventory'?: BlueprintInventoryWithFilters;
18990
19022
  /**
18991
- * Cause entity / force. The entity or force that triggered the chain of events that led to this entity being created. Used for beams, projectiles, stickers, etc. so that the damage receiver can know which entity or force to retaliate against.
19023
+ * Cause entity / force. The entity or force that triggered the chain of events that led to this entity being created. Used for beams, projectiles, stickers, etc. so that the damage receiver can know which entity or force to retaliate against. Defaults to the value of `source`.
18992
19024
  */
18993
19025
  'cause'?: LuaEntity | ForceID;
18994
19026
  /**
@@ -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.64
5
+ // Factorio version 2.0.66
6
6
  // API version 6
7
7
 
8
8
  declare namespace runtime {
@@ -52,8 +52,17 @@ interface AddRecordData {
52
52
  * When `rail` is given, this can be provided to further narrow down direction from which that rail should be approached.
53
53
  */
54
54
  rail_direction?: defines.rail_direction;
55
+ /**
56
+ * Defaults to `false`.
57
+ */
55
58
  temporary?: boolean;
59
+ /**
60
+ * Defaults to `false`.
61
+ */
56
62
  created_by_interrupt?: boolean;
63
+ /**
64
+ * Defaults to `true`.
65
+ */
57
66
  allows_unloading?: boolean;
58
67
  wait_conditions?: WaitCondition[];
59
68
  /**
@@ -3113,9 +3122,9 @@ interface GuiAnchor {
3113
3122
  */
3114
3123
  names?: string[];
3115
3124
  /**
3116
- * One of `'both'`, `'only_ghosts'`, or `'only_real'`
3125
+ * Defaults to `"only_real"`.
3117
3126
  */
3118
- ghost_mode?: string;
3127
+ ghost_mode?: 'both' | 'only_ghosts' | 'only_real';
3119
3128
  }
3120
3129
  /**
3121
3130
  * Used for specifying where a GUI arrow should point to.
@@ -3317,6 +3326,21 @@ type HeatSettingMode = 'at-least' | 'at-most' | 'exactly' | 'add' | 'remove';
3317
3326
  * All base prototype types.
3318
3327
  */
3319
3328
  type IDType = 'custom-input' | 'equipment-grid' | 'entity' | 'particle' | 'item' | 'collision-layer' | 'airborne-pollutant' | 'tile' | 'decorative' | 'recipe-category' | 'item-group' | 'item-subgroup' | 'recipe' | 'fluid' | 'ammo-category' | 'fuel-category' | 'resource-category' | 'technology' | 'noise-function' | 'noise-expression' | 'autoplace-control' | 'equipment' | 'damage-type' | 'virtual-signal' | 'achievement' | 'module-category' | 'equipment-category' | 'mod-setting' | 'trivial-smoke' | 'asteroid-chunk' | 'quality' | 'surface-property' | 'procession-layer-inheritance-group' | 'procession' | 'space-location' | 'space-connection' | 'active-trigger' | 'shortcut' | 'burner-usage' | 'surface' | 'mod-data' | 'custom-event';
3329
+ interface IconDrawSpecification {
3330
+ shift: Vector;
3331
+ scale: float;
3332
+ scale_for_many: float;
3333
+ render_layer?: 'entity-info-icon-below' | 'entity-info-icon-above' | 'air-entity-info-icon';
3334
+ }
3335
+ interface IconSequencePositioning {
3336
+ inventory_index: defines.inventory;
3337
+ max_icons_per_row: uint8;
3338
+ max_icon_rows: uint8;
3339
+ shift: Vector;
3340
+ scale: float;
3341
+ separation_multiplier: float;
3342
+ multi_row_initial_height_modifier: float;
3343
+ }
3320
3344
  /**
3321
3345
  * A single filter used by an infinity-filters instance.
3322
3346
  */
@@ -3851,7 +3875,7 @@ type ItemPrototypeFlag = /**
3851
3875
  * Makes construction bots prefer this item when building the entity specified by its `place_result`.
3852
3876
  */
3853
3877
  'primary-place-result' | /**
3854
- * Allows the item to be opened by the player, firing the `on_mod_item_opened` event. Only has an effect for selection tool items.
3878
+ * Allows the item to be opened by the player, firing the {@link on_mod_item_opened | runtime:on_mod_item_opened} event.
3855
3879
  */
3856
3880
  'mod-openable' | /**
3857
3881
  * Makes it so the item is deleted when clearing the cursor, instead of being put into the player's inventory. The copy-paste tools use this by default, for example.
@@ -6916,6 +6940,7 @@ interface PlaceAsTileResult {
6916
6940
  condition_size: uint;
6917
6941
  condition: CollisionMask;
6918
6942
  invert: boolean;
6943
+ tile_condition: LuaTilePrototype[];
6919
6944
  }
6920
6945
  interface PlatformSchedule {
6921
6946
  /**
@@ -8264,9 +8289,9 @@ interface SelectorCombinatorParametersQualityTransfer extends BaseSelectorCombin
8264
8289
  'quality_destination_signal': SignalID;
8265
8290
  'quality_source_signal'?: SignalIDBase;
8266
8291
  /**
8267
- * Defaults to normal quality.
8292
+ * The name of the quality prototype. Defaults to `"normal"`.
8268
8293
  */
8269
- 'quality_source_static'?: QualityID;
8294
+ 'quality_source_static'?: string;
8270
8295
  /**
8271
8296
  * Defaults to `false`.
8272
8297
  */
@@ -8298,7 +8323,7 @@ interface SelectorCombinatorParametersSelect extends BaseSelectorCombinatorParam
8298
8323
  /**
8299
8324
  * The signal index to use if not using a specific `index_signal`. Defaults to `0`.
8300
8325
  */
8301
- 'index_constant'?: uint;
8326
+ 'index_constant'?: int;
8302
8327
  /**
8303
8328
  * The signal to use, if any.
8304
8329
  */
@@ -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.64
5
+ // Factorio version 2.0.66
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.64
5
+ // Factorio version 2.0.66
6
6
  // API version 6
7
7
 
8
8
  declare namespace defines {
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.64
5
+ // Factorio version 2.0.66
6
6
  // API version 6
7
7
 
8
8
  declare namespace runtime {
@@ -4511,7 +4511,7 @@ interface on_tower_mined_plant {
4511
4511
  tower: LuaEntity;
4512
4512
  }
4513
4513
  /**
4514
- * Called before an agricultural tower planets a seed.
4514
+ * Called before an agricultural tower plants a seed.
4515
4515
  */
4516
4516
  interface on_tower_planted_seed {
4517
4517
  /**
@@ -4519,7 +4519,7 @@ interface on_tower_planted_seed {
4519
4519
  */
4520
4520
  name: defines.events;
4521
4521
  /**
4522
- * The plant which was planted.
4522
+ * The plant that was planted.
4523
4523
  */
4524
4524
  plant: LuaEntity;
4525
4525
  /**
@@ -4531,7 +4531,7 @@ interface on_tower_planted_seed {
4531
4531
  */
4532
4532
  tick: uint;
4533
4533
  /**
4534
- * The tower that's did the planting.
4534
+ * The tower that did the planting.
4535
4535
  */
4536
4536
  tower: LuaEntity;
4537
4537
  }
@@ -4544,7 +4544,7 @@ interface on_tower_pre_mined_plant {
4544
4544
  */
4545
4545
  name: defines.events;
4546
4546
  /**
4547
- * The plant which is about to be mined.
4547
+ * The plant that is about to be mined.
4548
4548
  */
4549
4549
  plant: LuaEntity;
4550
4550
  /**
@@ -4552,7 +4552,7 @@ interface on_tower_pre_mined_plant {
4552
4552
  */
4553
4553
  tick: uint;
4554
4554
  /**
4555
- * The tower that's about to do the mining.
4555
+ * The tower that is about to do the mining.
4556
4556
  */
4557
4557
  tower: LuaEntity;
4558
4558
  }
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.64
5
+ // Factorio version 2.0.66
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.64
5
+ // Factorio version 2.0.66
6
6
  // API version 6
7
7
 
8
8
  declare namespace prototype {
@@ -1531,10 +1531,6 @@ interface CharacterPrototype extends EntityWithOwnerPrototype {
1531
1531
  damage_hit_tint: Color;
1532
1532
  distance_per_frame: double;
1533
1533
  drop_item_distance: uint32;
1534
- /**
1535
- * The sound played when the character eats (fish for example).
1536
- */
1537
- eat: Sound;
1538
1534
  /**
1539
1535
  * Must be >= 0.
1540
1536
  */
@@ -1569,7 +1565,7 @@ interface CharacterPrototype extends EntityWithOwnerPrototype {
1569
1565
  /**
1570
1566
  * The sound played when the character's health is low.
1571
1567
  */
1572
- heartbeat: Sound;
1568
+ heartbeat?: Sound;
1573
1569
  /**
1574
1570
  * Number of slots in the main inventory. May be 0.
1575
1571
  */
@@ -1906,7 +1902,11 @@ interface CorpsePrototype extends EntityPrototype {
1906
1902
  decay_animation?: RotatedAnimationVariations;
1907
1903
  decay_frame_transition_duration?: float;
1908
1904
  /**
1909
- * An array of arrays of integers. The inner arrays are called "groups" and must all have the same size.
1905
+ * May not be an empty array. May not be used if there is no `animation` defined.
1906
+ *
1907
+ * The inner arrays are called "groups" and must all have the same size.
1908
+ *
1909
+ * The indices map to the directions of `animation` and they are 1-indexed. After the `shuffle_directions_at_frame` frame of the `animation`, these indices are used as the direction when choosing which frame to render. The chosen shuffled direction can be any direction in the same group as the non-shuffled direction. Which direction is chosen from the group depends on the shuffle variation which is `dying_graphics_variation % group_size`.
1910
1910
  */
1911
1911
  direction_shuffle?: uint16[][];
1912
1912
  /**
@@ -1927,6 +1927,9 @@ interface CorpsePrototype extends EntityPrototype {
1927
1927
  ground_patch_render_layer?: RenderLayer;
1928
1928
  remove_on_entity_placement?: boolean;
1929
1929
  remove_on_tile_placement?: boolean;
1930
+ /**
1931
+ * Defines after which frame in the `animation` the `direction_shuffle` should be applied. Can be set to `0`, frames are 1-indexed.
1932
+ */
1930
1933
  shuffle_directions_at_frame?: uint8;
1931
1934
  splash?: AnimationVariations;
1932
1935
  splash_render_layer?: RenderLayer;
@@ -2009,6 +2012,8 @@ interface CraftingMachinePrototype extends EntityWithOwnerPrototype {
2009
2012
  fast_transfer_modules_into_module_slots_only?: boolean;
2010
2013
  /**
2011
2014
  * The crafting machine's fluid boxes. If an assembling machine has fluid boxes *and* {@link AssemblingMachinePrototype::fluid_boxes_off_when_no_fluid_recipe | prototype:AssemblingMachinePrototype::fluid_boxes_off_when_no_fluid_recipe} is true, the assembling machine can only be rotated when a recipe consuming or producing fluid is set, or if it has one of the other properties listed at the top of this page.
2015
+ *
2016
+ * For assembling machines, any {@link filters | prototype:FluidBox::filter} set on the fluidboxes are ignored.
2012
2017
  * @example ```
2013
2018
  fluid_boxes =
2014
2019
  {
@@ -3180,6 +3185,7 @@ interface EntityPrototype extends Prototype {
3180
3185
  */
3181
3186
  deconstruction_alternative?: EntityID;
3182
3187
  diagonal_tile_grid_size?: TilePosition;
3188
+ draw_stateless_visualisations_in_ghost?: boolean;
3183
3189
  /**
3184
3190
  * Specification of extra vertical space needed to see the whole entity in GUIs. This is used to calculate the correct zoom and positioning in the entity info gui, for example in the entity tooltip.
3185
3191
  * @example ```
@@ -3220,7 +3226,7 @@ interface EntityPrototype extends Prototype {
3220
3226
  */
3221
3227
  icon?: FileName;
3222
3228
  /**
3223
- * Used to specify where and how should be the alt-mode icons of entities should be drawn.
3229
+ * Used to specify where and how the alt-mode icons should be drawn.
3224
3230
  * @example ```
3225
3231
  icon_draw_specification = {shift = {0, 0.5}, scale = 0.75, scale_for_many = 0.5, render_layer = "entity-info-icon"}
3226
3232
  ```
@@ -5054,7 +5060,7 @@ interface LabPrototype extends EntityWithOwnerPrototype {
5054
5060
  science_pack_drain_rate_percent?: uint8;
5055
5061
  trash_inventory_size?: ItemStackIndex;
5056
5062
  /**
5057
- * Whether the {@link QualityPrototype::science_pack_drain_multiplier | prototype:QualityPrototype::science_pack_drain_multiplier} of the quality of the science pack should be considered by the lab.
5063
+ * Whether the {@link QualityPrototype::science_pack_drain_multiplier | prototype:QualityPrototype::science_pack_drain_multiplier} of the quality of this lab should affect how much science is consumed to research one unit of technology.
5058
5064
  */
5059
5065
  uses_quality_drain_modifier?: boolean;
5060
5066
  }
@@ -5408,10 +5414,14 @@ interface LoaderPrototype extends TransportBeltConnectablePrototype {
5408
5414
  * If filters are per lane. Can only be set to true if filter_count is equal to 2.
5409
5415
  */
5410
5416
  per_lane_filters?: boolean;
5417
+ /**
5418
+ * When set, this loader will respect the same automated insertion limits as inserters do, instead of inserting up to the full ingredient stack capacity.
5419
+ */
5420
+ respect_insert_limits?: boolean;
5411
5421
  structure?: LoaderStructure;
5412
5422
  structure_render_layer?: RenderLayer;
5413
5423
  /**
5414
- * When set, loader will ignore items for which there is not enough to create a full belt stack. Relevant only when loader can create belt stacks.
5424
+ * When set, this loader will ignore items for which there is not enough to create a full belt stack. Relevant only when loader can create belt stacks.
5415
5425
  */
5416
5426
  wait_for_full_stack?: boolean;
5417
5427
  }
@@ -6566,10 +6576,14 @@ interface QualityPrototype extends Prototype {
6566
6576
  range_multiplier?: double;
6567
6577
  /**
6568
6578
  * Must be in range `[0, 1]`.
6579
+ *
6580
+ * Only affects labs with {@link LabPrototype::uses_quality_drain_modifier | prototype:LabPrototype::uses_quality_drain_modifier} set.
6569
6581
  */
6570
6582
  science_pack_drain_multiplier?: float;
6571
6583
  /**
6572
6584
  * Must be >= 0.01.
6585
+ *
6586
+ * Affects the durability of {@link tool items | prototype:ToolPrototype} like science packs, repair tools and armor.
6573
6587
  */
6574
6588
  tool_durability_multiplier?: double;
6575
6589
  }
@@ -8428,7 +8442,7 @@ interface SpaceLocationPrototype extends Prototype {
8428
8442
  asteroid_spawn_influence?: double;
8429
8443
  auto_save_on_first_trip?: boolean;
8430
8444
  /**
8431
- * Distance from the location's parent body in map coordinates.
8445
+ * Distance from the sun in map coordinates.
8432
8446
  */
8433
8447
  distance: double;
8434
8448
  /**
@@ -8468,7 +8482,7 @@ interface SpaceLocationPrototype extends Prototype {
8468
8482
  */
8469
8483
  magnitude?: double;
8470
8484
  /**
8471
- * Angle in relation to the parent body.
8485
+ * Angle in relation to the sun.
8472
8486
  */
8473
8487
  orientation: RealOrientation;
8474
8488
  /**
@@ -8493,7 +8507,7 @@ interface SpaceLocationPrototype extends Prototype {
8493
8507
  */
8494
8508
  starmap_icon?: FileName;
8495
8509
  /**
8496
- * Orientation of the starmap icon, defaults to pointing towards the parent body.
8510
+ * Orientation of the starmap icon, defaults to pointing towards the sun.
8497
8511
  */
8498
8512
  starmap_icon_orientation?: RealOrientation;
8499
8513
  /**
@@ -9318,7 +9332,7 @@ interface TilePrototype extends Prototype {
9318
9332
  * If items dropped on this tile are destroyed.
9319
9333
  */
9320
9334
  destroys_dropped_items?: boolean;
9321
- driving_sound?: Sound;
9335
+ driving_sound?: InterruptibleSound;
9322
9336
  /**
9323
9337
  * Triggers when a foundation tile is destroyed by an asteroid.
9324
9338
  */
@@ -9846,7 +9860,7 @@ interface TutorialDefinition extends PrototypeBase {
9846
9860
  */
9847
9861
  order?: Order;
9848
9862
  /**
9849
- * Name of the folder for this tutorial scenario in the {@link `tutorials` folder | https://wiki.factorio.com/Tutorial:Mod_structure#Subfolders}.
9863
+ * Name of the folder for this tutorial scenario in the {@link `tutorials` folder | runtime:mod-structure}.
9850
9864
  */
9851
9865
  scenario: string;
9852
9866
  }
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.64
5
+ // Factorio version 2.0.66
6
6
  // API version 6
7
7
 
8
8
  declare namespace prototype {
@@ -4961,6 +4961,9 @@ interface FrequencySizeRichness {
4961
4961
  type FuelCategoryID = string;
4962
4962
  interface FusionGeneratorDirectionGraphicsSet {
4963
4963
  animation?: Animation;
4964
+ /**
4965
+ * The amount of items in this array has to match the amount of {@link input fluid connections | prototype:FusionGeneratorPrototype::input_fluid_box}. Empty tables can be used as items to fulfill this requirement without defining graphics.
4966
+ */
4964
4967
  fluid_input_graphics?: FusionGeneratorFluidInputGraphics[];
4965
4968
  fusion_effect_uv_map?: Sprite;
4966
4969
  working_light?: Animation;
@@ -5225,9 +5228,6 @@ interface HeatEnergySource extends BaseEnergySource {
5225
5228
  */
5226
5229
  connections?: HeatConnection[];
5227
5230
  default_temperature?: double;
5228
- /**
5229
- * Heat energy sources do not support producing pollution.
5230
- */
5231
5231
  emissions_per_minute?: Record<AirbornePollutantID, double>;
5232
5232
  heat_glow?: Sprite4Way;
5233
5233
  heat_picture?: Sprite4Way;
@@ -5352,7 +5352,7 @@ interface IconData {
5352
5352
  tint?: Color;
5353
5353
  }
5354
5354
  /**
5355
- * Specification of where and how should be the alt-mode icons of entities be drawn.
5355
+ * Specification of where and how the alt-mode icons of entities should be drawn.
5356
5356
  */
5357
5357
  interface IconDrawSpecification {
5358
5358
  /**
@@ -5612,7 +5612,7 @@ type ItemPrototypeFlags = (/**
5612
5612
  * Item will be preferred by construction bots when building the entity specified by the item's {@link place_result | prototype:ItemPrototype::place_result}.
5613
5613
  */
5614
5614
  'primary-place-result' | /**
5615
- * Only works for {@link SelectionToolPrototype | prototype:SelectionToolPrototype} and derived classes. Corresponds to the runtime {@link on_mod_item_opened | runtime:on_mod_item_opened} event.
5615
+ * Allows the item to be opened by the player, firing the {@link on_mod_item_opened | runtime:on_mod_item_opened} event.
5616
5616
  */
5617
5617
  'mod-openable' | /**
5618
5618
  * Item is deleted when removed from the cursor by pressing `Q` ("clear cursor"). Used for example by the copy/paste tools.
@@ -9947,6 +9947,12 @@ interface SpriteSheet extends SpriteParameters {
9947
9947
  * Same as `dice` above, but this specifies only how many slices there are on the y axis.
9948
9948
  */
9949
9949
  dice_y?: SpriteSizeType;
9950
+ /**
9951
+ * Only loaded, and mandatory if `layers` and `filenames` are not defined.
9952
+ *
9953
+ * The path to the sprite file to use.
9954
+ */
9955
+ filename?: FileName;
9950
9956
  filenames?: FileName[];
9951
9957
  /**
9952
9958
  * If this property is present, all SpriteSheet definitions have to be placed as entries in the array, and they will all be loaded from there. `layers` may not be an empty table. Each definition in the array may also have the `layers` property.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "factorio-types",
3
- "version": "1.2.46",
3
+ "version": "1.2.48",
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.64",
26
+ "factorioVersion": "2.0.66",
27
27
  "dependencies": {
28
28
  "lua-types": "^2.13.1"
29
29
  },