factorio-types 0.0.35 → 0.0.36
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 +108 -20
- package/dist/concepts.d.ts +9 -9
- package/dist/defines.d.ts +19 -1
- package/dist/events.d.ts +48 -1
- package/dist/global.d.ts +1 -1
- package/package.json +1 -1
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 1.1.
|
|
5
|
+
// Factorio version 1.1.84
|
|
6
6
|
// API version 3
|
|
7
7
|
|
|
8
8
|
/**
|
|
@@ -1076,7 +1076,12 @@ interface LuaControl {
|
|
|
1076
1076
|
get_main_inventory(this: void): void
|
|
1077
1077
|
|
|
1078
1078
|
/**
|
|
1079
|
-
* The
|
|
1079
|
+
* The highest index of all inventories this entity can use. Allows iteration over all of them if desired.
|
|
1080
|
+
* @example
|
|
1081
|
+
* ```
|
|
1082
|
+
* for k = 1, entity.get_max_inventory_index() do [...] end
|
|
1083
|
+
* ```
|
|
1084
|
+
*
|
|
1080
1085
|
*/
|
|
1081
1086
|
get_max_inventory_index(this: void): void
|
|
1082
1087
|
|
|
@@ -1655,6 +1660,16 @@ interface LuaCustomInputPrototype {
|
|
|
1655
1660
|
*/
|
|
1656
1661
|
readonly consuming: string
|
|
1657
1662
|
|
|
1663
|
+
/**
|
|
1664
|
+
* The default controller alternative key sequence for this custom input, if any
|
|
1665
|
+
*/
|
|
1666
|
+
readonly controller_alternative_key_sequence?: string
|
|
1667
|
+
|
|
1668
|
+
/**
|
|
1669
|
+
* The default controller key sequence for this custom input, if any
|
|
1670
|
+
*/
|
|
1671
|
+
readonly controller_key_sequence?: string
|
|
1672
|
+
|
|
1658
1673
|
/**
|
|
1659
1674
|
* Whether this custom input is enabled. Disabled custom inputs exist but are not used by the game.
|
|
1660
1675
|
*/
|
|
@@ -3090,12 +3105,12 @@ interface LuaEntity extends LuaControl {
|
|
|
3090
3105
|
readonly belt_neighbours: {[key: string]: LuaEntity[]}
|
|
3091
3106
|
|
|
3092
3107
|
/**
|
|
3093
|
-
*
|
|
3108
|
+
* Whether this underground belt goes into or out of the ground.
|
|
3094
3109
|
* @remarks
|
|
3095
3110
|
* Applies to subclasses: TransportBeltToGround
|
|
3096
3111
|
*
|
|
3097
3112
|
*/
|
|
3098
|
-
readonly belt_to_ground_type:
|
|
3113
|
+
readonly belt_to_ground_type: 'input' | 'output'
|
|
3099
3114
|
|
|
3100
3115
|
/**
|
|
3101
3116
|
* The bonus mining progress for this mining drill. Read yields a number in range [0, mining_target.prototype.mineable_properties.mining_time]. `nil` if this isn't a mining drill.
|
|
@@ -3660,12 +3675,12 @@ interface LuaEntity extends LuaControl {
|
|
|
3660
3675
|
readonly loader_container?: LuaEntity
|
|
3661
3676
|
|
|
3662
3677
|
/**
|
|
3663
|
-
*
|
|
3678
|
+
* Whether this loader gets items from or puts item into a container.
|
|
3664
3679
|
* @remarks
|
|
3665
3680
|
* Applies to subclasses: Loader
|
|
3666
3681
|
*
|
|
3667
3682
|
*/
|
|
3668
|
-
loader_type:
|
|
3683
|
+
loader_type: 'input' | 'output'
|
|
3669
3684
|
|
|
3670
3685
|
readonly localised_description: LocalisedString
|
|
3671
3686
|
|
|
@@ -4092,7 +4107,7 @@ interface LuaEntity extends LuaControl {
|
|
|
4092
4107
|
/**
|
|
4093
4108
|
* The ticks left before a ghost, combat robot, highlight box or smoke with trigger is destroyed.
|
|
4094
4109
|
*
|
|
4095
|
-
* - for ghosts set to uint32 max (4
|
|
4110
|
+
* - for ghosts set to uint32 max (4'294'967'295) to never expire.
|
|
4096
4111
|
* - for ghosts Cannot be set higher than {@link LuaForce::ghost_time_to_live | LuaForce::ghost_time_to_live} of the entity's force.
|
|
4097
4112
|
*/
|
|
4098
4113
|
time_to_live: number
|
|
@@ -7224,8 +7239,10 @@ interface LuaForce {
|
|
|
7224
7239
|
|
|
7225
7240
|
/**
|
|
7226
7241
|
* Force a rechart of the whole chart.
|
|
7242
|
+
* @param surface - Which surface to rechart or all if not given.
|
|
7227
7243
|
*/
|
|
7228
|
-
rechart(this: void
|
|
7244
|
+
rechart(this: void,
|
|
7245
|
+
surface?: SurfaceIdentification): void
|
|
7229
7246
|
|
|
7230
7247
|
/**
|
|
7231
7248
|
* Research all technologies.
|
|
@@ -7763,7 +7780,7 @@ interface LuaGameScript {
|
|
|
7763
7780
|
/**
|
|
7764
7781
|
* Create a new surface.
|
|
7765
7782
|
* @remarks
|
|
7766
|
-
* The game currently supports a maximum of 4
|
|
7783
|
+
* The game currently supports a maximum of 4'294'967'295 surfaces, including the default surface.
|
|
7767
7784
|
* Surface names must be unique.
|
|
7768
7785
|
*
|
|
7769
7786
|
* @param name - Name of the new surface.
|
|
@@ -8015,7 +8032,7 @@ interface LuaGameScript {
|
|
|
8015
8032
|
is_demo(this: void): void
|
|
8016
8033
|
|
|
8017
8034
|
/**
|
|
8018
|
-
*
|
|
8035
|
+
* Whether the save is loaded as a multiplayer map.
|
|
8019
8036
|
*/
|
|
8020
8037
|
is_multiplayer(this: void): void
|
|
8021
8038
|
|
|
@@ -8445,7 +8462,7 @@ interface LuaGameScript {
|
|
|
8445
8462
|
readonly font_prototypes: {[key: string]: LuaFontPrototype}
|
|
8446
8463
|
|
|
8447
8464
|
/**
|
|
8448
|
-
* Get a table of all the forces that currently exist. This sparse table allows you to find forces by indexing it with either their `name` or `index`. Iterating this table with `pairs()` will only iterate the
|
|
8465
|
+
* Get a table of all the forces that currently exist. This sparse table allows you to find forces by indexing it with either their `name` or `index`. Iterating this table with `pairs()` will only iterate the hash part of the table. Iterating with `ipairs()` will not work at all.
|
|
8449
8466
|
*/
|
|
8450
8467
|
readonly forces: {[key: string]: LuaForce}
|
|
8451
8468
|
|
|
@@ -8588,7 +8605,7 @@ interface LuaGameScript {
|
|
|
8588
8605
|
readonly styles: {[key: string]: string}
|
|
8589
8606
|
|
|
8590
8607
|
/**
|
|
8591
|
-
* Get a table of all the surfaces that currently exist. This sparse table allows you to find surfaces by indexing it with either their `name` or `index`. Iterating this table with `pairs()` will only iterate the
|
|
8608
|
+
* Get a table of all the surfaces that currently exist. This sparse table allows you to find surfaces by indexing it with either their `name` or `index`. Iterating this table with `pairs()` will only iterate the hash part of the table. Iterating with `ipairs()` will not work at all.
|
|
8592
8609
|
*/
|
|
8593
8610
|
readonly surfaces: {[key: string]: LuaSurface}
|
|
8594
8611
|
|
|
@@ -8608,11 +8625,9 @@ interface LuaGameScript {
|
|
|
8608
8625
|
tick_paused: boolean
|
|
8609
8626
|
|
|
8610
8627
|
/**
|
|
8611
|
-
* The number of ticks since this game was
|
|
8612
|
-
*
|
|
8613
|
-
* This differs
|
|
8614
|
-
* This value has no relation with {@link LuaGameScript::tick | LuaGameScript::tick} and can be completely different values.
|
|
8615
|
-
*
|
|
8628
|
+
* The number of ticks since this game was created using either "new game" or "new game from scenario". Notably, this number progresses even when the game is {@link tick_paused | LuaGameScript::tick_paused}.
|
|
8629
|
+
*
|
|
8630
|
+
* This differs from {@link LuaGameScript::tick | LuaGameScript::tick} in that creating a game from a scenario always starts with this value at `0`, even if the scenario has its own level data where the `tick` has progressed past `0`.
|
|
8616
8631
|
*/
|
|
8617
8632
|
readonly ticks_played: number
|
|
8618
8633
|
|
|
@@ -8833,7 +8848,7 @@ interface LuaGui {
|
|
|
8833
8848
|
* - `"progressbar"`: A partially filled bar that can be used to indicate progress.
|
|
8834
8849
|
* - `"table"`: An invisible container that lays out its children in a specific number of columns. The width of each column is determined by the widest element it contains.
|
|
8835
8850
|
* - `"textfield"`: A single-line box the user can type into. Relevant events: {@link on_gui_text_changed | on_gui_text_changed}, {@link on_gui_confirmed | on_gui_confirmed}
|
|
8836
|
-
* - `"radiobutton"`: An element that is similar to a `checkbox`, but with a circular appearance. Clicking a selected radio button will not
|
|
8851
|
+
* - `"radiobutton"`: An element that is similar to a `checkbox`, but with a circular appearance. Clicking a selected radio button will not unselect it. Radio buttons are not linked to each other in any way. Relevant event: {@link on_gui_checked_state_changed | on_gui_checked_state_changed}
|
|
8837
8852
|
* - `"sprite"`: An element that shows an image.
|
|
8838
8853
|
* - `"scroll-pane"`: An invisible element that is similar to a `flow`, but has the ability to show and use scroll bars.
|
|
8839
8854
|
* - `"drop-down"`: A drop-down containing strings of text. Relevant event: {@link on_gui_selection_state_changed | on_gui_selection_state_changed}
|
|
@@ -9215,6 +9230,14 @@ interface LuaGuiElement {
|
|
|
9215
9230
|
*/
|
|
9216
9231
|
auto_center: boolean
|
|
9217
9232
|
|
|
9233
|
+
/**
|
|
9234
|
+
* Whether this button will automatically toggle when clicked.
|
|
9235
|
+
* @remarks
|
|
9236
|
+
* Applies to subclasses: button,sprite-button
|
|
9237
|
+
*
|
|
9238
|
+
*/
|
|
9239
|
+
auto_toggle: boolean
|
|
9240
|
+
|
|
9218
9241
|
/**
|
|
9219
9242
|
* The text to display after the normal tab text (designed to work with numbers)
|
|
9220
9243
|
* @remarks
|
|
@@ -9380,6 +9403,11 @@ interface LuaGuiElement {
|
|
|
9380
9403
|
*/
|
|
9381
9404
|
force?: string
|
|
9382
9405
|
|
|
9406
|
+
/**
|
|
9407
|
+
* How this element should interact with game controllers.
|
|
9408
|
+
*/
|
|
9409
|
+
game_controller_interaction: defines.game_controller_interaction
|
|
9410
|
+
|
|
9383
9411
|
/**
|
|
9384
9412
|
* The GUI this element is a child of.
|
|
9385
9413
|
*/
|
|
@@ -9665,6 +9693,14 @@ interface LuaGuiElement {
|
|
|
9665
9693
|
*/
|
|
9666
9694
|
text: string
|
|
9667
9695
|
|
|
9696
|
+
/**
|
|
9697
|
+
* Whether this button is currently toggled. When a button is toggled, it will use the `selected_graphical_set` and `selected_font_color` defined in its style.
|
|
9698
|
+
* @remarks
|
|
9699
|
+
* Applies to subclasses: button,sprite-button
|
|
9700
|
+
*
|
|
9701
|
+
*/
|
|
9702
|
+
toggled: boolean
|
|
9703
|
+
|
|
9668
9704
|
tooltip: LocalisedString
|
|
9669
9705
|
|
|
9670
9706
|
/**
|
|
@@ -12126,6 +12162,11 @@ interface LuaModSettingPrototype {
|
|
|
12126
12162
|
|
|
12127
12163
|
readonly setting_type: string
|
|
12128
12164
|
|
|
12165
|
+
/**
|
|
12166
|
+
* Type of this prototype.
|
|
12167
|
+
*/
|
|
12168
|
+
readonly type: string
|
|
12169
|
+
|
|
12129
12170
|
/**
|
|
12130
12171
|
* Is this object valid? This Lua object holds a reference to an object within the game engine. It is possible that the game-engine object is removed whilst a mod still holds the corresponding Lua object. If that happens, the object becomes invalid, i.e. this attribute will be `false`. Mods are advised to check for object validity if any change to the game state might have occurred between the creation of the Lua object and its access.
|
|
12131
12172
|
*/
|
|
@@ -13062,6 +13103,11 @@ interface LuaPlayer extends LuaControl {
|
|
|
13062
13103
|
*/
|
|
13063
13104
|
infinity_inventory_filters: InfinityInventoryFilter[]
|
|
13064
13105
|
|
|
13106
|
+
/**
|
|
13107
|
+
* The input method of the player, mouse and keyboard or game controller
|
|
13108
|
+
*/
|
|
13109
|
+
readonly input_method: defines.input_method
|
|
13110
|
+
|
|
13065
13111
|
/**
|
|
13066
13112
|
* At what tick this player was last online.
|
|
13067
13113
|
*/
|
|
@@ -16069,6 +16115,14 @@ interface LuaSurface {
|
|
|
16069
16115
|
use_map_generation_bounding_box: boolean,
|
|
16070
16116
|
direction?: defines.direction): void
|
|
16071
16117
|
|
|
16118
|
+
/**
|
|
16119
|
+
* Find the logistic network with a cell closest to a given position.
|
|
16120
|
+
* @param force - Force the logistic network should belong to.
|
|
16121
|
+
*/
|
|
16122
|
+
find_closest_logistic_network_by_position(this: void,
|
|
16123
|
+
position: MapPosition,
|
|
16124
|
+
force: ForceIdentification): void
|
|
16125
|
+
|
|
16072
16126
|
/**
|
|
16073
16127
|
* Find decoratives of a given name in a given area.
|
|
16074
16128
|
*
|
|
@@ -16172,7 +16226,7 @@ interface LuaSurface {
|
|
|
16172
16226
|
}): void
|
|
16173
16227
|
|
|
16174
16228
|
/**
|
|
16175
|
-
* Find
|
|
16229
|
+
* Find an entity of the given type at the given position. This checks both the exact position and the bounding box of the entity.
|
|
16176
16230
|
* @param entity - Entity to look for.
|
|
16177
16231
|
* @param position - Coordinates to look at.
|
|
16178
16232
|
* @example
|
|
@@ -16336,12 +16390,16 @@ interface LuaSurface {
|
|
|
16336
16390
|
* @remarks
|
|
16337
16391
|
* This won't find tiles in non-generated chunks.
|
|
16338
16392
|
*
|
|
16393
|
+
* @param area - The area to find connected tiles in. If provided the start position must be in this area.
|
|
16394
|
+
* @param include_diagonal - Include tiles that are connected diagonally.
|
|
16339
16395
|
* @param position - The tile position to start at.
|
|
16340
16396
|
* @param tiles - The tiles to search for.
|
|
16341
16397
|
*/
|
|
16342
16398
|
get_connected_tiles(this: void,
|
|
16343
16399
|
position: TilePosition,
|
|
16344
|
-
tiles: string[]
|
|
16400
|
+
tiles: string[],
|
|
16401
|
+
include_diagonal?: boolean,
|
|
16402
|
+
area?: BoundingBox): void
|
|
16345
16403
|
|
|
16346
16404
|
/**
|
|
16347
16405
|
* Returns all the military targets (entities with force) on this chunk for the given force.
|
|
@@ -18043,6 +18101,11 @@ interface LuaGuiElementAddParams {
|
|
|
18043
18101
|
*/
|
|
18044
18102
|
'enabled'?: boolean
|
|
18045
18103
|
|
|
18104
|
+
/**
|
|
18105
|
+
* How the element should interact with game controllers. Defaults to {@link defines.game_controller_interaction.normal | defines.game_controller_interaction.normal}.
|
|
18106
|
+
*/
|
|
18107
|
+
'game_controller_interaction'?: defines.game_controller_interaction
|
|
18108
|
+
|
|
18046
18109
|
/**
|
|
18047
18110
|
* Whether the child element is ignored by interaction. Defaults to `false`.
|
|
18048
18111
|
*/
|
|
@@ -18058,6 +18121,11 @@ interface LuaGuiElementAddParams {
|
|
|
18058
18121
|
*/
|
|
18059
18122
|
'name'?: string
|
|
18060
18123
|
|
|
18124
|
+
/**
|
|
18125
|
+
* Whether this element will raise {@link on_gui_hover | on_gui_hover} and {@link on_gui_leave | on_gui_leave}. Defaults to `false`.
|
|
18126
|
+
*/
|
|
18127
|
+
'raise_hover_events'?: boolean
|
|
18128
|
+
|
|
18061
18129
|
/**
|
|
18062
18130
|
* The name of the style prototype to apply to the new element.
|
|
18063
18131
|
*/
|
|
@@ -18091,11 +18159,21 @@ interface LuaGuiElementAddParams {
|
|
|
18091
18159
|
*
|
|
18092
18160
|
*/
|
|
18093
18161
|
interface LuaGuiElementAddParamsButton extends LuaGuiElementAddParams {
|
|
18162
|
+
/**
|
|
18163
|
+
* Whether the button will automatically toggle when clicked. Defaults to `false`.
|
|
18164
|
+
*/
|
|
18165
|
+
'auto_toggle'?: boolean
|
|
18166
|
+
|
|
18094
18167
|
/**
|
|
18095
18168
|
* Which mouse buttons the button responds to. Defaults to `"left-and-right"`.
|
|
18096
18169
|
*/
|
|
18097
18170
|
'mouse_button_filter'?: MouseButtonFlags
|
|
18098
18171
|
|
|
18172
|
+
/**
|
|
18173
|
+
* The initial toggled state of the button. Defaults to `false`.
|
|
18174
|
+
*/
|
|
18175
|
+
'toggled'?: boolean
|
|
18176
|
+
|
|
18099
18177
|
}
|
|
18100
18178
|
|
|
18101
18179
|
/**
|
|
@@ -18421,6 +18499,11 @@ interface LuaGuiElementAddParamsSprite extends LuaGuiElementAddParams {
|
|
|
18421
18499
|
*
|
|
18422
18500
|
*/
|
|
18423
18501
|
interface LuaGuiElementAddParamsSpriteButton extends LuaGuiElementAddParams {
|
|
18502
|
+
/**
|
|
18503
|
+
* Whether the button will automatically toggle when clicked. Defaults to `false`.
|
|
18504
|
+
*/
|
|
18505
|
+
'auto_toggle'?: boolean
|
|
18506
|
+
|
|
18424
18507
|
/**
|
|
18425
18508
|
* Path to the image to display on the button when it is clicked.
|
|
18426
18509
|
*/
|
|
@@ -18451,6 +18534,11 @@ interface LuaGuiElementAddParamsSpriteButton extends LuaGuiElementAddParams {
|
|
|
18451
18534
|
*/
|
|
18452
18535
|
'sprite'?: SpritePath
|
|
18453
18536
|
|
|
18537
|
+
/**
|
|
18538
|
+
* The initial toggled state of the button. Defaults to `false`.
|
|
18539
|
+
*/
|
|
18540
|
+
'toggled'?: boolean
|
|
18541
|
+
|
|
18454
18542
|
}
|
|
18455
18543
|
|
|
18456
18544
|
/**
|
package/dist/concepts.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 1.1.
|
|
5
|
+
// Factorio version 1.1.84
|
|
6
6
|
// API version 3
|
|
7
7
|
|
|
8
8
|
/**
|
|
@@ -323,7 +323,7 @@ interface BlueprintSignalIcon {
|
|
|
323
323
|
}
|
|
324
324
|
|
|
325
325
|
/**
|
|
326
|
-
* Two positions, specifying the top-left and bottom-right corner of the box respectively. Like with {@link MapPosition | MapPosition}, the names of the members may be omitted. When read from the game, the third member `orientation` is present if it is non-zero
|
|
326
|
+
* Two positions, specifying the top-left and bottom-right corner of the box respectively. Like with {@link MapPosition | MapPosition}, the names of the members may be omitted. When read from the game, the third member `orientation` is present if it is non-zero.
|
|
327
327
|
* @example
|
|
328
328
|
* Explicit definition:
|
|
329
329
|
* ```
|
|
@@ -838,7 +838,7 @@ interface EnemyExpansionMapSettings {
|
|
|
838
838
|
max_colliding_tiles_coefficient: number,
|
|
839
839
|
|
|
840
840
|
/**
|
|
841
|
-
* The maximum time between expansions in ticks. The actual cooldown is adjusted to the current evolution levels. Defaults to `60*3
|
|
841
|
+
* The maximum time between expansions in ticks. The actual cooldown is adjusted to the current evolution levels. Defaults to `60*3'600=216'000` ticks.
|
|
842
842
|
*/
|
|
843
843
|
max_expansion_cooldown: number,
|
|
844
844
|
|
|
@@ -848,7 +848,7 @@ interface EnemyExpansionMapSettings {
|
|
|
848
848
|
max_expansion_distance: number,
|
|
849
849
|
|
|
850
850
|
/**
|
|
851
|
-
* The minimum time between expansions in ticks. The actual cooldown is adjusted to the current evolution levels. Defaults to `4*3
|
|
851
|
+
* The minimum time between expansions in ticks. The actual cooldown is adjusted to the current evolution levels. Defaults to `4*3'600=14'400` ticks.
|
|
852
852
|
*/
|
|
853
853
|
min_expansion_cooldown: number,
|
|
854
854
|
|
|
@@ -2004,12 +2004,12 @@ interface PathFinderMapSettings {
|
|
|
2004
2004
|
max_clients_to_accept_short_new_request: number,
|
|
2005
2005
|
|
|
2006
2006
|
/**
|
|
2007
|
-
* The maximum number of nodes that are expanded per tick. Defaults to `1
|
|
2007
|
+
* The maximum number of nodes that are expanded per tick. Defaults to `1'000`.
|
|
2008
2008
|
*/
|
|
2009
2009
|
max_steps_worked_per_tick: number,
|
|
2010
2010
|
|
|
2011
2011
|
/**
|
|
2012
|
-
* The maximum amount of work each pathfinding job is allowed to do per tick. Defaults to `8
|
|
2012
|
+
* The maximum amount of work each pathfinding job is allowed to do per tick. Defaults to `8'000`.
|
|
2013
2013
|
*/
|
|
2014
2014
|
max_work_done_per_tick: number,
|
|
2015
2015
|
|
|
@@ -2723,7 +2723,7 @@ interface UnitGroupMapSettings {
|
|
|
2723
2723
|
max_gathering_unit_groups: number,
|
|
2724
2724
|
|
|
2725
2725
|
/**
|
|
2726
|
-
* The maximum amount of time in ticks a group will spend gathering before setting off. The actual time is a random time between the minimum and maximum times. Defaults to `10*3
|
|
2726
|
+
* The maximum amount of time in ticks a group will spend gathering before setting off. The actual time is a random time between the minimum and maximum times. Defaults to `10*3'600=36'000` ticks.
|
|
2727
2727
|
*/
|
|
2728
2728
|
max_group_gathering_time: number,
|
|
2729
2729
|
|
|
@@ -2758,7 +2758,7 @@ interface UnitGroupMapSettings {
|
|
|
2758
2758
|
max_unit_group_size: number,
|
|
2759
2759
|
|
|
2760
2760
|
/**
|
|
2761
|
-
* After gathering has finished, the group is allowed to wait this long in ticks for delayed members. New members are not accepted anymore however. Defaults to `2*3
|
|
2761
|
+
* After gathering has finished, the group is allowed to wait this long in ticks for delayed members. New members are not accepted anymore however. Defaults to `2*3'600=7'200` ticks.
|
|
2762
2762
|
*/
|
|
2763
2763
|
max_wait_time_for_late_members: number,
|
|
2764
2764
|
|
|
@@ -2768,7 +2768,7 @@ interface UnitGroupMapSettings {
|
|
|
2768
2768
|
member_disown_distance: number,
|
|
2769
2769
|
|
|
2770
2770
|
/**
|
|
2771
|
-
* The minimum amount of time in ticks a group will spend gathering before setting off. The actual time is a random time between the minimum and maximum times. Defaults to `3
|
|
2771
|
+
* The minimum amount of time in ticks a group will spend gathering before setting off. The actual time is a random time between the minimum and maximum times. Defaults to `3'600` ticks.
|
|
2772
2772
|
*/
|
|
2773
2773
|
min_group_gathering_time: number,
|
|
2774
2774
|
|
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 1.1.
|
|
5
|
+
// Factorio version 1.1.84
|
|
6
6
|
// API version 3
|
|
7
7
|
|
|
8
8
|
declare namespace defines {
|
|
@@ -515,9 +515,12 @@ declare namespace defines {
|
|
|
515
515
|
on_console_chat,
|
|
516
516
|
on_console_command,
|
|
517
517
|
on_cutscene_cancelled,
|
|
518
|
+
on_cutscene_finished,
|
|
519
|
+
on_cutscene_started,
|
|
518
520
|
on_cutscene_waypoint_reached,
|
|
519
521
|
on_difficulty_settings_changed,
|
|
520
522
|
on_entity_cloned,
|
|
523
|
+
on_entity_color_changed,
|
|
521
524
|
on_entity_damaged,
|
|
522
525
|
on_entity_destroyed,
|
|
523
526
|
on_entity_died,
|
|
@@ -587,6 +590,7 @@ declare namespace defines {
|
|
|
587
590
|
on_player_fast_transferred,
|
|
588
591
|
on_player_flushed_fluid,
|
|
589
592
|
on_player_gun_inventory_changed,
|
|
593
|
+
on_player_input_method_changed,
|
|
590
594
|
on_player_joined_game,
|
|
591
595
|
on_player_kicked,
|
|
592
596
|
on_player_left_game,
|
|
@@ -687,6 +691,20 @@ declare namespace defines {
|
|
|
687
691
|
ten_minutes,
|
|
688
692
|
two_hundred_fifty_hours,
|
|
689
693
|
}
|
|
694
|
+
enum game_controller_interaction {
|
|
695
|
+
/**
|
|
696
|
+
* Game controller will always hover this element regardless of type or state.
|
|
697
|
+
*/
|
|
698
|
+
always,
|
|
699
|
+
/**
|
|
700
|
+
* Hover according to the element type and implementation.
|
|
701
|
+
*/
|
|
702
|
+
never,
|
|
703
|
+
/**
|
|
704
|
+
* Never hover this element with a game controller.
|
|
705
|
+
*/
|
|
706
|
+
normal,
|
|
707
|
+
}
|
|
690
708
|
enum group_state {
|
|
691
709
|
attacking_distraction,
|
|
692
710
|
attacking_target,
|
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 1.1.
|
|
5
|
+
// Factorio version 1.1.84
|
|
6
6
|
// API version 3
|
|
7
7
|
|
|
8
8
|
/**
|
|
@@ -25,6 +25,10 @@ interface event {
|
|
|
25
25
|
* Called when a {@link CustomInput | https://wiki.factorio.com/Prototype/CustomInput} is activated.
|
|
26
26
|
*/
|
|
27
27
|
interface CustomInputEvent extends event {
|
|
28
|
+
/**
|
|
29
|
+
* The mouse cursor display location when the custom input was activated.
|
|
30
|
+
*/
|
|
31
|
+
cursor_display_location: GuiLocation
|
|
28
32
|
/**
|
|
29
33
|
* The mouse cursor position when the custom input was activated.
|
|
30
34
|
*/
|
|
@@ -274,6 +278,24 @@ interface on_cutscene_cancelled extends event {
|
|
|
274
278
|
*/
|
|
275
279
|
player_index: number
|
|
276
280
|
}
|
|
281
|
+
/**
|
|
282
|
+
* Called when a cutscene finishes naturally (was not cancelled).
|
|
283
|
+
*/
|
|
284
|
+
interface on_cutscene_finished extends event {
|
|
285
|
+
/**
|
|
286
|
+
* The player the cutscene was shown to.
|
|
287
|
+
*/
|
|
288
|
+
player_index: number
|
|
289
|
+
}
|
|
290
|
+
/**
|
|
291
|
+
* Called when a cutscene starts.
|
|
292
|
+
*/
|
|
293
|
+
interface on_cutscene_started extends event {
|
|
294
|
+
/**
|
|
295
|
+
* The player the cutscene is being shown to.
|
|
296
|
+
*/
|
|
297
|
+
player_index: number
|
|
298
|
+
}
|
|
277
299
|
/**
|
|
278
300
|
* Called when a cutscene is playing, each time it reaches a waypoint in that cutscene.
|
|
279
301
|
*
|
|
@@ -309,6 +331,15 @@ interface on_entity_cloned extends event {
|
|
|
309
331
|
destination: LuaEntity
|
|
310
332
|
source: LuaEntity
|
|
311
333
|
}
|
|
334
|
+
/**
|
|
335
|
+
* Called after an entity has been recolored either by the player or through script.
|
|
336
|
+
*/
|
|
337
|
+
interface on_entity_color_changed extends event {
|
|
338
|
+
/**
|
|
339
|
+
* The entity that was recolored.
|
|
340
|
+
*/
|
|
341
|
+
entity: LuaEntity
|
|
342
|
+
}
|
|
312
343
|
/**
|
|
313
344
|
* Called when an entity is damaged. Can be filtered using {@link LuaEntityDamagedEventFilter | LuaEntityDamagedEventFilter}.
|
|
314
345
|
* @remarks
|
|
@@ -585,6 +616,10 @@ interface on_gui_click extends event {
|
|
|
585
616
|
* If control was pressed.
|
|
586
617
|
*/
|
|
587
618
|
control: boolean
|
|
619
|
+
/**
|
|
620
|
+
* The display location of the player's cursor.
|
|
621
|
+
*/
|
|
622
|
+
cursor_display_location: GuiLocation
|
|
588
623
|
/**
|
|
589
624
|
* The clicked element.
|
|
590
625
|
*/
|
|
@@ -1383,6 +1418,18 @@ interface on_player_flushed_fluid extends event {
|
|
|
1383
1418
|
interface on_player_gun_inventory_changed extends event {
|
|
1384
1419
|
player_index: number
|
|
1385
1420
|
}
|
|
1421
|
+
/**
|
|
1422
|
+
* Called when a player's input method changes.
|
|
1423
|
+
* @remarks
|
|
1424
|
+
* See {@link LuaPlayer::input_method | LuaPlayer::input_method}.
|
|
1425
|
+
*
|
|
1426
|
+
*/
|
|
1427
|
+
interface on_player_input_method_changed extends event {
|
|
1428
|
+
/**
|
|
1429
|
+
* The player whose input method changed.
|
|
1430
|
+
*/
|
|
1431
|
+
player_index: number
|
|
1432
|
+
}
|
|
1386
1433
|
/**
|
|
1387
1434
|
* Called after a player joins the game. This is not called when loading a save file in singleplayer, as the player doesn't actually leave the game, and the save is just on pause until they rejoin.
|
|
1388
1435
|
*/
|
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 1.1.
|
|
5
|
+
// Factorio version 1.1.84
|
|
6
6
|
// API version 3
|
|
7
7
|
|
|
8
8
|
/**
|