factorio-types 0.0.46 → 0.0.47
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 +210 -150
- package/dist/concepts.d.ts +474 -529
- package/dist/core.d.ts +3 -0
- package/dist/defines.d.ts +5 -1
- package/dist/events.d.ts +3 -3
- package/dist/global.d.ts +1 -1
- package/dist/prototypes.d.ts +99 -31
- package/dist/types.d.ts +153 -11
- package/package.json +2 -2
package/dist/core.d.ts
CHANGED
|
@@ -24,6 +24,9 @@ declare const serpent: Serpent;
|
|
|
24
24
|
// can eventually fix these on a per-case basis
|
|
25
25
|
type Table = any;
|
|
26
26
|
|
|
27
|
+
// https://lua-api.factorio.com/latest/types/DataExtendMethod.html
|
|
28
|
+
type DataExtendMethod = (data: prototype.Data, ...otherData: any[]) => void;
|
|
29
|
+
|
|
27
30
|
// The docs and json definition make reference to these types but have no information as to what they are
|
|
28
31
|
type BlueprintCircuitConnection = any;
|
|
29
32
|
type BlueprintControlBehavior = any;
|
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.102
|
|
6
6
|
// API version 4
|
|
7
7
|
|
|
8
8
|
declare namespace defines {
|
|
@@ -372,6 +372,10 @@ declare namespace defines {
|
|
|
372
372
|
* Used by crafting machines.
|
|
373
373
|
*/
|
|
374
374
|
fluid_ingredient_shortage,
|
|
375
|
+
/**
|
|
376
|
+
* Used by burner energy sources.
|
|
377
|
+
*/
|
|
378
|
+
full_burnt_result_output,
|
|
375
379
|
/**
|
|
376
380
|
* Used by crafting machines, boilers, burner energy sources and reactors: Reactor/burner has full burnt result inventory, boiler has full output fluidbox.
|
|
377
381
|
*/
|
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.102
|
|
6
6
|
// API version 4
|
|
7
7
|
|
|
8
8
|
declare namespace runtime {
|
|
@@ -1283,7 +1283,7 @@ interface on_player_created extends event {
|
|
|
1283
1283
|
player_index: number
|
|
1284
1284
|
}
|
|
1285
1285
|
/**
|
|
1286
|
-
* Called after a player's {@link cursor stack | runtime:LuaControl::cursor_stack} changed in some way.
|
|
1286
|
+
* Called after a player's {@link cursor stack | runtime:LuaControl::cursor_stack} changed in some way. This is fired in the same tick that the change happens, but not instantly.
|
|
1287
1287
|
*/
|
|
1288
1288
|
interface on_player_cursor_stack_changed extends event {
|
|
1289
1289
|
player_index: number
|
|
@@ -1907,7 +1907,7 @@ interface on_pre_entity_settings_pasted extends event {
|
|
|
1907
1907
|
source: LuaEntity
|
|
1908
1908
|
}
|
|
1909
1909
|
/**
|
|
1910
|
-
* Called before a ghost entity is destroyed as a result of being marked for deconstruction. Can be filtered using {@link LuaPreGhostDeconstructedEventFilter | runtime:LuaPreGhostDeconstructedEventFilter}.
|
|
1910
|
+
* Called before a ghost entity is destroyed as a result of being marked for deconstruction. Also called for item request proxies before they are destroyed as a result of being marked for deconstruction. Can be filtered using {@link LuaPreGhostDeconstructedEventFilter | runtime:LuaPreGhostDeconstructedEventFilter}.
|
|
1911
1911
|
*/
|
|
1912
1912
|
interface on_pre_ghost_deconstructed extends event {
|
|
1913
1913
|
ghost: LuaEntity
|
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.102
|
|
6
6
|
// API version 4
|
|
7
7
|
|
|
8
8
|
/**
|
package/dist/prototypes.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 1.1.
|
|
5
|
+
// Factorio version 1.1.102
|
|
6
6
|
// API version 4
|
|
7
7
|
|
|
8
8
|
declare namespace prototype {
|
|
@@ -349,7 +349,7 @@ Mandatory if `icons` is not defined.
|
|
|
349
349
|
icon_mipmaps?: IconMipMapType,
|
|
350
350
|
|
|
351
351
|
/**
|
|
352
|
-
* The size of the square icon, in pixels
|
|
352
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
353
353
|
|
|
354
354
|
Mandatory if `icons` is not defined, or if `icon_size` is not specified for all instances of `icons`.
|
|
355
355
|
*/
|
|
@@ -1053,6 +1053,10 @@ The picture of the beacon when it is not on.
|
|
|
1053
1053
|
*/
|
|
1054
1054
|
distribution_effectivity: number,
|
|
1055
1055
|
energy_source: ElectricEnergySource | VoidEnergySource,
|
|
1056
|
+
|
|
1057
|
+
/**
|
|
1058
|
+
* The constant power usage of this beacon.
|
|
1059
|
+
*/
|
|
1056
1060
|
energy_usage: Energy,
|
|
1057
1061
|
|
|
1058
1062
|
/**
|
|
@@ -2696,7 +2700,7 @@ interface EntityParticlePrototype extends EntityPrototype{
|
|
|
2696
2700
|
}
|
|
2697
2701
|
|
|
2698
2702
|
/**
|
|
2699
|
-
* Abstract base of all entities in the game. Entity is nearly everything that can be on the map(except tiles).
|
|
2703
|
+
* Abstract base of all entities in the game. Entity is nearly everything that can be on the map (except tiles).
|
|
2700
2704
|
*
|
|
2701
2705
|
* For in game script access to entity, take a look at {@link LuaEntity | runtime:LuaEntity}.
|
|
2702
2706
|
* @example
|
|
@@ -2819,7 +2823,7 @@ Only loaded if `icons` is not defined.
|
|
|
2819
2823
|
icon_mipmaps?: IconMipMapType,
|
|
2820
2824
|
|
|
2821
2825
|
/**
|
|
2822
|
-
* The size of the square icon, in pixels
|
|
2826
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
2823
2827
|
|
|
2824
2828
|
Only loaded if `icons` is not defined, or if `icon_size` is not specified for all instances of `icons`.
|
|
2825
2829
|
*/
|
|
@@ -2848,7 +2852,7 @@ Either this or `icon` is mandatory for entities that have at least one of these
|
|
|
2848
2852
|
/**
|
|
2849
2853
|
* Name of the entity that will be automatically selected as the upgrade of this entity when using the {@link upgrade planner | https://wiki.factorio.com/Upgrade_planner} without configuration.
|
|
2850
2854
|
|
|
2851
|
-
This entity may not have "not-upgradable" flag set and must be minable. This entity mining result must not contain item product with "hidden" flag set. Mining results with no item products are allowed.
|
|
2855
|
+
This entity may not have "not-upgradable" flag set and must be minable. This entity mining result must not contain item product with "hidden" flag set. Mining results with no item products are allowed. This entity may not be a {@link RollingStockPrototype | prototype:RollingStockPrototype}.
|
|
2852
2856
|
|
|
2853
2857
|
The upgrade target entity needs to have the same bounding box, collision mask, and fast replaceable group as this entity. The upgrade target entity must have least 1 item that builds it that isn't hidden.
|
|
2854
2858
|
*/
|
|
@@ -3399,7 +3403,7 @@ Mandatory if `icons` is not defined.
|
|
|
3399
3403
|
icon_mipmaps?: IconMipMapType,
|
|
3400
3404
|
|
|
3401
3405
|
/**
|
|
3402
|
-
* The size of the square icon, in pixels
|
|
3406
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
3403
3407
|
|
|
3404
3408
|
Mandatory if `icons` is not defined, or if `icon_size` is not specified for all instances of `icons`.
|
|
3405
3409
|
*/
|
|
@@ -3562,9 +3566,17 @@ interface FlyingRobotPrototype extends EntityWithOwnerPrototype{
|
|
|
3562
3566
|
collision_mask?: CollisionMask,
|
|
3563
3567
|
|
|
3564
3568
|
/**
|
|
3565
|
-
* How much does it cost to move 1 tile.
|
|
3569
|
+
* How much energy does it cost to move 1 tile.
|
|
3570
|
+
|
|
3571
|
+
Used only by {@link robots with logistic interface | prototype:RobotWithLogisticInterfacePrototype}.
|
|
3566
3572
|
*/
|
|
3567
3573
|
energy_per_move?: Energy,
|
|
3574
|
+
|
|
3575
|
+
/**
|
|
3576
|
+
* How much energy does it cost to fly for 1 tick.
|
|
3577
|
+
|
|
3578
|
+
Used only by {@link robots with logistic interface | prototype:RobotWithLogisticInterfacePrototype}.
|
|
3579
|
+
*/
|
|
3568
3580
|
energy_per_tick?: Energy,
|
|
3569
3581
|
|
|
3570
3582
|
/**
|
|
@@ -3574,27 +3586,39 @@ interface FlyingRobotPrototype extends EntityWithOwnerPrototype{
|
|
|
3574
3586
|
|
|
3575
3587
|
/**
|
|
3576
3588
|
* How much energy can be stored in the batteries.
|
|
3589
|
+
|
|
3590
|
+
Used only by {@link robots with logistic interface | prototype:RobotWithLogisticInterfacePrototype}.
|
|
3577
3591
|
*/
|
|
3578
3592
|
max_energy?: Energy,
|
|
3579
3593
|
|
|
3580
3594
|
/**
|
|
3581
|
-
* The maximum speed of the robot. Useful to limit the impact of {@link worker robot speed (research) | https://wiki.factorio.com/Worker_robot_speed_(research}).
|
|
3595
|
+
* The maximum flying speed of the robot, in tiles/tick. Useful to limit the impact of {@link worker robot speed (research) | https://wiki.factorio.com/Worker_robot_speed_(research}).
|
|
3582
3596
|
*/
|
|
3583
3597
|
max_speed?: number,
|
|
3584
3598
|
|
|
3585
3599
|
/**
|
|
3586
|
-
* If the robot
|
|
3600
|
+
* If the robot's battery fill ratio is more than this, it does not need to charge before stationing.
|
|
3601
|
+
|
|
3602
|
+
Used only by {@link robots with logistic interface | prototype:RobotWithLogisticInterfacePrototype}.
|
|
3587
3603
|
*/
|
|
3588
3604
|
max_to_charge?: number,
|
|
3589
3605
|
|
|
3590
3606
|
/**
|
|
3591
|
-
* The robot will go to charge when
|
|
3607
|
+
* The robot will go to charge when its battery fill ratio is less than this.
|
|
3608
|
+
|
|
3609
|
+
Used only by {@link robots with logistic interface | prototype:RobotWithLogisticInterfacePrototype}.
|
|
3592
3610
|
*/
|
|
3593
3611
|
min_to_charge?: number,
|
|
3612
|
+
|
|
3613
|
+
/**
|
|
3614
|
+
* The flying speed of the robot, in tiles/tick.
|
|
3615
|
+
*/
|
|
3594
3616
|
speed: number,
|
|
3595
3617
|
|
|
3596
3618
|
/**
|
|
3597
3619
|
* Some robots simply crash, some slowdown but keep going. 0 means crash.
|
|
3620
|
+
|
|
3621
|
+
Used only by {@link robots with logistic interface | prototype:RobotWithLogisticInterfacePrototype}.
|
|
3598
3622
|
*/
|
|
3599
3623
|
speed_multiplier_when_out_of_energy?: number
|
|
3600
3624
|
}
|
|
@@ -3667,6 +3691,14 @@ interface FontPrototype {
|
|
|
3667
3691
|
|
|
3668
3692
|
/**
|
|
3669
3693
|
* Each item which has a fuel_value must have a fuel category. The fuel categories are used to allow only certain fuels to be used in {@link EnergySource | prototype:EnergySource}.
|
|
3694
|
+
* @example
|
|
3695
|
+
* ```
|
|
3696
|
+
* {
|
|
3697
|
+
* type = "fuel-category",
|
|
3698
|
+
* name = "best-fuel"
|
|
3699
|
+
* }
|
|
3700
|
+
* ```
|
|
3701
|
+
*
|
|
3670
3702
|
*/
|
|
3671
3703
|
interface FuelCategory extends PrototypeBase{
|
|
3672
3704
|
|
|
@@ -4082,9 +4114,21 @@ Note, that for buildings, it is customary to leave 0.1 wide border between the e
|
|
|
4082
4114
|
}
|
|
4083
4115
|
|
|
4084
4116
|
/**
|
|
4085
|
-
* An item group. Item groups are shown above the list of craftable items in the player's inventory. The built-in groups are "logistics", "production", "intermediate-products" and "combat" but mods can define their own.
|
|
4117
|
+
* An item group. Item groups are the tabs shown above the list of craftable items in the player's inventory GUI. The built-in groups are "logistics", "production", "intermediate-products" and "combat" but mods can define their own.
|
|
4086
4118
|
*
|
|
4087
|
-
* Items are sorted into item groups by sorting them into a {@link subgroup | prototype:ItemPrototype::subgroup} which then belongs to
|
|
4119
|
+
* Items are sorted into item groups by sorting them into a {@link subgroup | prototype:ItemPrototype::subgroup} which then belongs to an {@link item group | prototype:ItemSubGroup::group}.
|
|
4120
|
+
* @example
|
|
4121
|
+
* ```
|
|
4122
|
+
* {
|
|
4123
|
+
* type = "item-group",
|
|
4124
|
+
* name = "logistics",
|
|
4125
|
+
* order = "a",
|
|
4126
|
+
* icon = "__base__/graphics/item-group/logistics.png",
|
|
4127
|
+
* icon_size = 128,
|
|
4128
|
+
* icon_mipmaps = 2
|
|
4129
|
+
* }
|
|
4130
|
+
* ```
|
|
4131
|
+
*
|
|
4088
4132
|
*/
|
|
4089
4133
|
interface ItemGroup extends PrototypeBase{
|
|
4090
4134
|
|
|
@@ -4101,7 +4145,7 @@ Mandatory if `icons` is not defined.
|
|
|
4101
4145
|
icon_mipmaps?: IconMipMapType,
|
|
4102
4146
|
|
|
4103
4147
|
/**
|
|
4104
|
-
* The size of the square icon, in pixels
|
|
4148
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
4105
4149
|
|
|
4106
4150
|
Mandatory if `icons` is not defined, or if `icon_size` is not specified for all instances of `icons`.
|
|
4107
4151
|
*/
|
|
@@ -4130,7 +4174,9 @@ interface ItemPrototype extends PrototypeBase{
|
|
|
4130
4174
|
close_sound?: Sound,
|
|
4131
4175
|
|
|
4132
4176
|
/**
|
|
4133
|
-
*
|
|
4177
|
+
* If this is set, it is used to show items in alt-mode instead of the normal item icon. This can be useful to increase the contrast of the icon with the dark alt-mode {@link icon outline | prototype:UtilityConstants::item_outline_color}.
|
|
4178
|
+
|
|
4179
|
+
Path to the icon file.
|
|
4134
4180
|
|
|
4135
4181
|
Only loaded if `dark_background_icons` is not defined.
|
|
4136
4182
|
|
|
@@ -4165,7 +4211,9 @@ Uses the basic `icon_size` and `icon_mipmaps` properties.
|
|
|
4165
4211
|
fuel_top_speed_multiplier?: number,
|
|
4166
4212
|
|
|
4167
4213
|
/**
|
|
4168
|
-
*
|
|
4214
|
+
* Amount of energy the item gives when used as fuel.
|
|
4215
|
+
|
|
4216
|
+
Mandatory if `fuel_acceleration_multiplier`, `fuel_top_speed_multiplier` or `fuel_emissions_multiplier` or `fuel_glow_color` are used.
|
|
4169
4217
|
*/
|
|
4170
4218
|
fuel_value?: Energy,
|
|
4171
4219
|
|
|
@@ -4184,7 +4232,7 @@ This definition applies to all icon-type properties, both on here and on any chi
|
|
|
4184
4232
|
icon_mipmaps?: IconMipMapType,
|
|
4185
4233
|
|
|
4186
4234
|
/**
|
|
4187
|
-
* The size of the square icon, in pixels
|
|
4235
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
4188
4236
|
|
|
4189
4237
|
This definition applies to all icon-type properties, both on here and on any children.
|
|
4190
4238
|
|
|
@@ -4201,7 +4249,7 @@ Mandatory if `icons` is not defined, or if `icon_size` is not specified for all
|
|
|
4201
4249
|
/**
|
|
4202
4250
|
* Used to give the item multiple different icons so that they look less uniform on belts. For inventory icons and similar, `icon/icons` will be used. Maximum number of variations is 16.
|
|
4203
4251
|
|
|
4204
|
-
|
|
4252
|
+
The expected size for icons of items on belts is 16px. So when using sprites of size `64` (same as base game icons), the `scale` should be set to 0.25.
|
|
4205
4253
|
*/
|
|
4206
4254
|
pictures?: SpriteVariations,
|
|
4207
4255
|
place_as_tile?: PlaceAsTile,
|
|
@@ -4250,7 +4298,19 @@ interface ItemRequestProxyPrototype extends EntityPrototype{
|
|
|
4250
4298
|
}
|
|
4251
4299
|
|
|
4252
4300
|
/**
|
|
4253
|
-
* An item subgroup.
|
|
4301
|
+
* An item subgroup. Item subgroups are the rows in the recipe list in the player's inventory GUI. The subgroup of a prototype also determines its item {@link group | prototype:ItemGroup::group} (tab in the recipe list).
|
|
4302
|
+
*
|
|
4303
|
+
* The built-in subgroups can be found {@link here | https://wiki.factorio.com/Data.raw#item-subgroup}. See {@link ItemPrototype::subgroup | prototype:ItemPrototype::subgroup} for setting the subgroup of an item.
|
|
4304
|
+
* @example
|
|
4305
|
+
* ```
|
|
4306
|
+
* {
|
|
4307
|
+
* type = "item-subgroup",
|
|
4308
|
+
* name = "train-transport",
|
|
4309
|
+
* group = "logistics",
|
|
4310
|
+
* order = "e"
|
|
4311
|
+
* }
|
|
4312
|
+
* ```
|
|
4313
|
+
*
|
|
4254
4314
|
*/
|
|
4255
4315
|
interface ItemSubGroup extends PrototypeBase{
|
|
4256
4316
|
|
|
@@ -5210,7 +5270,7 @@ interface MovementBonusEquipmentPrototype extends EquipmentPrototype{
|
|
|
5210
5270
|
*
|
|
5211
5271
|
* Alternate expressions can be made available in the map generator GUI by setting their `intended_property` to the name of the property they should override.
|
|
5212
5272
|
*
|
|
5213
|
-
* Named noise expressions can also be used by {@link noise variables | prototype:
|
|
5273
|
+
* Named noise expressions can also be used by {@link noise variables | prototype:NoiseVariable}, e.g. `noise.var("my-named-expression")`.
|
|
5214
5274
|
*/
|
|
5215
5275
|
interface NamedNoiseExpression extends PrototypeBase{
|
|
5216
5276
|
|
|
@@ -5224,7 +5284,7 @@ interface NamedNoiseExpression extends PrototypeBase{
|
|
|
5224
5284
|
|
|
5225
5285
|
Note that the "Map type" dropdown in the map generation GUI is actually a selector for "elevation" generators. If generators are available for other properties, the "Map type" dropdown in the GUI will be renamed to "elevation" and shown along with selectors for the other selectable properties.
|
|
5226
5286
|
|
|
5227
|
-
For example if a noise expression is intended to be used as an alternative temperature generator, `intended_property` should be "temperature". The base game uses the intended_properties elevation, temperature, moisture and aux. For how the named noise expression with those intended_properties are used in the base game see the notable named noise expression list on {@link
|
|
5287
|
+
For example if a noise expression is intended to be used as an alternative temperature generator, `intended_property` should be "temperature". The base game uses the intended_properties elevation, temperature, moisture and aux. For how the named noise expression with those intended_properties are used in the base game see the notable named noise expression list on {@link BaseNamedNoiseExpressions | prototype:BaseNamedNoiseExpressions}. Mods may add any other intended_property or modify the existing noise expressions to change/remove their intended properties. Furthermore, mods may remove the use of those named noise expressions from the map generation code or change what they affect.
|
|
5228
5288
|
|
|
5229
5289
|
**intended_property in the base game:** The base game defines two named noise expressions that have the `intended_property` "elevation" so that are selectable via the "Map type" dropdown (which actually selects elevation generators)
|
|
5230
5290
|
|
|
@@ -5249,7 +5309,7 @@ data:extend{
|
|
|
5249
5309
|
|
|
5250
5310
|
**Mods can define any intended_property with any name**. This examples aims to show what this is useful for.
|
|
5251
5311
|
|
|
5252
|
-
A {@link
|
|
5312
|
+
A {@link NoiseVariable | prototype:NoiseVariable} can reference a named noise expression, so by defining the "test" named noise expression, `noise.var("test")` may be used in other {@link noise expressions | prototype:NoiseExpression}. Intended_property allows to override what the variable references: With the example, if "more-test" is selected in the dropdown in the map generator GUI, its `expression` (`noise.ridge(noise.var("y"), -10, 6`) will provide the value for the noise variable "test" instead.
|
|
5253
5313
|
|
|
5254
5314
|
For easy demonstration, that value is assigned to the "elevation" named noise expression, so changing the "test" generator changes the `noise.var("test")` which in turn is used by the "elevation" named noise expression. The "elevation" noise variable is used by water generation, so changing the test generators is immediately visible in the map generation preview.
|
|
5255
5315
|
|
|
@@ -5794,7 +5854,7 @@ interface RadarPrototype extends EntityWithOwnerPrototype{
|
|
|
5794
5854
|
/**
|
|
5795
5855
|
* The amount of energy the radar has to consume for nearby scan to be performed. This value doesn't have any effect on sector scanning.
|
|
5796
5856
|
|
|
5797
|
-
Performance warning: nearby scan causes re-charting of many chunks, which is expensive operation. If you want to make a radar that updates map more in real time, you should keep its range low. If you are making radar with high range, you should set this value such that nearby scan is performed once a second or so. For example if you set `energy_usage` to 100kW, setting`
|
|
5857
|
+
Performance warning: nearby scan causes re-charting of many chunks, which is expensive operation. If you want to make a radar that updates map more in real time, you should keep its range low. If you are making radar with high range, you should set this value such that nearby scan is performed once a second or so. For example if you set `energy_usage` to 100kW, setting `energy_per_nearby_scan` to 100kJ will cause nearby scan to happen once per second.
|
|
5798
5858
|
*/
|
|
5799
5859
|
energy_per_nearby_scan: Energy,
|
|
5800
5860
|
|
|
@@ -6044,6 +6104,14 @@ The input energy source, in vanilla it is a burner energy source.
|
|
|
6044
6104
|
* A recipe category. The built-in categories can be found {@link here | https://wiki.factorio.com/Data.raw#recipe-category}. See {@link RecipePrototype::category | prototype:RecipePrototype::category}. Recipe categories can be used to specify which {@link machine | prototype:CraftingMachinePrototype::crafting_categories} can craft which {@link recipes | prototype:RecipePrototype}.
|
|
6045
6105
|
*
|
|
6046
6106
|
* The recipe category with the name "crafting" cannot contain recipes with fluid ingredients or products.
|
|
6107
|
+
* @example
|
|
6108
|
+
* ```
|
|
6109
|
+
* {
|
|
6110
|
+
* type = "recipe-category",
|
|
6111
|
+
* name = "my-category"
|
|
6112
|
+
* }
|
|
6113
|
+
* ```
|
|
6114
|
+
*
|
|
6047
6115
|
*/
|
|
6048
6116
|
interface RecipeCategory extends PrototypeBase{
|
|
6049
6117
|
|
|
@@ -6258,9 +6326,9 @@ Mandatory if `icons` is not defined for a recipe with more than one product and
|
|
|
6258
6326
|
icon_mipmaps?: IconMipMapType,
|
|
6259
6327
|
|
|
6260
6328
|
/**
|
|
6261
|
-
* The size of the square icon, in pixels
|
|
6329
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
6262
6330
|
|
|
6263
|
-
|
|
6331
|
+
Only loaded if `icons` is not defined, or if `icon_size` is not specified for all instances of `icons`.
|
|
6264
6332
|
*/
|
|
6265
6333
|
icon_size?: SpriteSizeType,
|
|
6266
6334
|
|
|
@@ -6334,7 +6402,7 @@ Mandatory if neither `normal` nor `expensive` are defined.
|
|
|
6334
6402
|
results?: ProductPrototype[],
|
|
6335
6403
|
|
|
6336
6404
|
/**
|
|
6337
|
-
* Whether the recipe name should have the product amount in front of it
|
|
6405
|
+
* Whether the recipe name should have the product amount in front of it. E.g. "2x Transport belt".
|
|
6338
6406
|
|
|
6339
6407
|
Only loaded if neither `normal` nor `expensive` are defined.
|
|
6340
6408
|
*/
|
|
@@ -8123,7 +8191,7 @@ Mandatory if `icons` is not defined.
|
|
|
8123
8191
|
icon_mipmaps?: IconMipMapType,
|
|
8124
8192
|
|
|
8125
8193
|
/**
|
|
8126
|
-
* The size of the square icon, in pixels
|
|
8194
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
8127
8195
|
|
|
8128
8196
|
Mandatory if `icons` is not defined, or if `icon_size` is not specified for all instances of `icons`.
|
|
8129
8197
|
*/
|
|
@@ -8135,7 +8203,7 @@ Mandatory if `icons` is not defined, or if `icon_size` is not specified for all
|
|
|
8135
8203
|
icons?: IconData[],
|
|
8136
8204
|
|
|
8137
8205
|
/**
|
|
8138
|
-
* Controls whether the technology cost ignores the tech cost multiplier set in the {@link DifficultySettings | runtime:DifficultySettings}
|
|
8206
|
+
* Controls whether the technology cost ignores the tech cost multiplier set in the {@link DifficultySettings | runtime:DifficultySettings}. E.g. `4` for the default expensive difficulty.
|
|
8139
8207
|
|
|
8140
8208
|
Only loaded if neither `normal` nor `expensive` are defined.
|
|
8141
8209
|
*/
|
|
@@ -8308,7 +8376,7 @@ Only loaded if `icons` is not defined.
|
|
|
8308
8376
|
icon_mipmaps?: IconMipMapType,
|
|
8309
8377
|
|
|
8310
8378
|
/**
|
|
8311
|
-
* The size of the square icon, in pixels
|
|
8379
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
8312
8380
|
|
|
8313
8381
|
Only loaded if `icons` is not defined, or if `icon_size` is not specified for all instances of `icons`.
|
|
8314
8382
|
*/
|
|
@@ -8886,12 +8954,12 @@ Controls the speed of the prepared_animation: `1 ÷ prepared_speed_secondary = d
|
|
|
8886
8954
|
}
|
|
8887
8955
|
|
|
8888
8956
|
/**
|
|
8889
|
-
* The definition of the tutorial to be used in the tips and tricks, see {@link TipsAndTricksItem | prototype:TipsAndTricksItem}. The actual tutorial code is defined in the
|
|
8957
|
+
* The definition of the tutorial to be used in the tips and tricks, see {@link TipsAndTricksItem | prototype:TipsAndTricksItem}. The actual tutorial scripting code is defined in the tutorial scenario. The scenario must be placed in the `tutorials` folder in the mod.
|
|
8890
8958
|
*/
|
|
8891
8959
|
interface TutorialDefinition extends PrototypeBase{
|
|
8892
8960
|
|
|
8893
8961
|
/**
|
|
8894
|
-
* Name of the folder for this tutorial in the tutorials folder.
|
|
8962
|
+
* Name of the folder for this tutorial scenario in the {@link `tutorials` folder | https://wiki.factorio.com/Tutorial:Mod_structure#Subfolders}.
|
|
8895
8963
|
*/
|
|
8896
8964
|
scenario: string
|
|
8897
8965
|
}
|
|
@@ -9934,7 +10002,7 @@ Mandatory if `icons` is not defined.
|
|
|
9934
10002
|
icon_mipmaps?: IconMipMapType,
|
|
9935
10003
|
|
|
9936
10004
|
/**
|
|
9937
|
-
* The size of the square icon, in pixels
|
|
10005
|
+
* The size of the square icon, in pixels. E.g. `32` for a 32px by 32px icon.
|
|
9938
10006
|
|
|
9939
10007
|
Mandatory if `icons` is not defined, or if `icon_size` is not specified for all instances of `icons`.
|
|
9940
10008
|
*/
|