factorio-types 1.2.57 → 1.2.58
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 +85 -45
- package/dist/concepts.d.ts +497 -31
- package/dist/datacollection.d.ts +1 -1
- package/dist/defines.d.ts +5 -5
- package/dist/events.d.ts +443 -443
- package/dist/global.d.ts +1 -1
- package/dist/prototypes.d.ts +245 -15
- package/dist/types.d.ts +76 -27
- package/package.json +2 -2
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.
|
|
5
|
+
// Factorio version 2.0.77
|
|
6
6
|
// API version 6
|
|
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 2.0.
|
|
5
|
+
// Factorio version 2.0.77
|
|
6
6
|
// API version 6
|
|
7
7
|
|
|
8
8
|
declare namespace prototype {
|
|
@@ -665,6 +665,12 @@ interface ArrowPrototype extends EntityPrototype {
|
|
|
665
665
|
arrow_picture: Sprite;
|
|
666
666
|
blinking?: boolean;
|
|
667
667
|
circle_picture?: Sprite;
|
|
668
|
+
/**
|
|
669
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
670
|
+
*
|
|
671
|
+
* The value `0` will be treated the same as `nil`.
|
|
672
|
+
*/
|
|
673
|
+
selection_priority?: uint8;
|
|
668
674
|
}
|
|
669
675
|
/**
|
|
670
676
|
* The entity spawned by the {@link artillery targeting remote | https://wiki.factorio.com/Artillery_targeting_remote}.
|
|
@@ -733,6 +739,12 @@ interface ArtilleryProjectilePrototype extends EntityPrototype {
|
|
|
733
739
|
* Whether the picture of the projectile is rotated to match the direction of travel.
|
|
734
740
|
*/
|
|
735
741
|
rotatable?: boolean;
|
|
742
|
+
/**
|
|
743
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
744
|
+
*
|
|
745
|
+
* The value `0` will be treated the same as `nil`.
|
|
746
|
+
*/
|
|
747
|
+
selection_priority?: uint8;
|
|
736
748
|
shadow?: Sprite;
|
|
737
749
|
}
|
|
738
750
|
/**
|
|
@@ -887,7 +899,7 @@ interface AssemblingMachinePrototype extends CraftingMachinePrototype {
|
|
|
887
899
|
*/
|
|
888
900
|
gui_title_key?: string;
|
|
889
901
|
/**
|
|
890
|
-
* Sets the maximum number of ingredients this machine can craft with. Any recipe with more ingredients than this will be unavailable in this machine.
|
|
902
|
+
* Sets the maximum number of item ingredients this machine can craft with. Any recipe with more item ingredients than this will be unavailable in this machine.
|
|
891
903
|
*
|
|
892
904
|
* This only counts item ingredients, not fluid ingredients! This means if ingredient count is 2, and the recipe has 2 item ingredients and 1 fluid ingredient, it can still be crafted in the machine.
|
|
893
905
|
*/
|
|
@@ -1104,6 +1116,12 @@ interface BeamPrototype extends EntityPrototype {
|
|
|
1104
1116
|
damage_interval: uint32;
|
|
1105
1117
|
graphics_set: BeamGraphicsSet;
|
|
1106
1118
|
random_target_offset?: boolean;
|
|
1119
|
+
/**
|
|
1120
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
1121
|
+
*
|
|
1122
|
+
* The value `0` will be treated the same as `nil`.
|
|
1123
|
+
*/
|
|
1124
|
+
selection_priority?: uint8;
|
|
1107
1125
|
target_offset?: Vector;
|
|
1108
1126
|
width: float;
|
|
1109
1127
|
}
|
|
@@ -1442,6 +1460,12 @@ interface CargoPodPrototype extends EntityWithOwnerPrototype {
|
|
|
1442
1460
|
inventory_size: ItemStackIndex;
|
|
1443
1461
|
procession_audio_catalogue?: ProcessionAudioCatalogue;
|
|
1444
1462
|
procession_graphic_catalogue?: ProcessionGraphicCatalogue;
|
|
1463
|
+
/**
|
|
1464
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
1465
|
+
*
|
|
1466
|
+
* The value `0` will be treated the same as `nil`.
|
|
1467
|
+
*/
|
|
1468
|
+
selection_priority?: uint8;
|
|
1445
1469
|
shadow_slave_entity?: EntityID;
|
|
1446
1470
|
spawned_container: EntityID;
|
|
1447
1471
|
}
|
|
@@ -1512,7 +1536,9 @@ interface ChangedSurfaceAchievementPrototype extends AchievementPrototype {
|
|
|
1512
1536
|
*/
|
|
1513
1537
|
interface CharacterCorpsePrototype extends EntityPrototype {
|
|
1514
1538
|
/**
|
|
1515
|
-
*
|
|
1539
|
+
* A mapping of {@link ArmorPrototype | prototype:ArmorPrototype} name to a number. The number is the Animation that is associated with the armor, e.g. using `1` will associate the armor with the first Animation in the `pictures` table.
|
|
1540
|
+
*
|
|
1541
|
+
* This mapping can be empty to have no sprite changes based on armor.
|
|
1516
1542
|
*/
|
|
1517
1543
|
armor_picture_mapping?: Record<ItemID, int32>;
|
|
1518
1544
|
/**
|
|
@@ -1525,7 +1551,7 @@ interface CharacterCorpsePrototype extends EntityPrototype {
|
|
|
1525
1551
|
pictures?: AnimationVariations;
|
|
1526
1552
|
render_layer?: RenderLayer;
|
|
1527
1553
|
/**
|
|
1528
|
-
* 0 for infinite.
|
|
1554
|
+
* In ticks. 0 for infinite.
|
|
1529
1555
|
*/
|
|
1530
1556
|
time_to_live: uint32;
|
|
1531
1557
|
}
|
|
@@ -1614,6 +1640,9 @@ interface CharacterPrototype extends EntityWithOwnerPrototype {
|
|
|
1614
1640
|
```
|
|
1615
1641
|
*/
|
|
1616
1642
|
mining_with_tool_particles_animation_positions: float[];
|
|
1643
|
+
/**
|
|
1644
|
+
* List of positions in the running animation when the moving sound is played.
|
|
1645
|
+
*/
|
|
1617
1646
|
moving_sound_animation_positions: float[];
|
|
1618
1647
|
reach_distance: uint32;
|
|
1619
1648
|
reach_resource_distance: double;
|
|
@@ -1944,6 +1973,12 @@ interface CorpsePrototype extends EntityPrototype {
|
|
|
1944
1973
|
protected_from_tile_building?: boolean;
|
|
1945
1974
|
remove_on_entity_placement?: boolean;
|
|
1946
1975
|
remove_on_tile_placement?: boolean;
|
|
1976
|
+
/**
|
|
1977
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
1978
|
+
*
|
|
1979
|
+
* The value `0` will be treated the same as `nil`.
|
|
1980
|
+
*/
|
|
1981
|
+
selection_priority?: uint8;
|
|
1947
1982
|
/**
|
|
1948
1983
|
* Defines after which frame in the `animation` the `direction_shuffle` should be applied. Can be set to `0`, frames are 1-indexed.
|
|
1949
1984
|
*/
|
|
@@ -2976,6 +3011,12 @@ interface ElevatedCurvedRailAPrototype extends CurvedRailAPrototype {
|
|
|
2976
3011
|
* Requires Space Age to create prototypes with name not starting with `dummy-`. Dummy prototypes cannot be built.
|
|
2977
3012
|
*/
|
|
2978
3013
|
name: string;
|
|
3014
|
+
/**
|
|
3015
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
3016
|
+
*
|
|
3017
|
+
* The value `0` will be treated the same as `nil`.
|
|
3018
|
+
*/
|
|
3019
|
+
selection_priority?: uint8;
|
|
2979
3020
|
}
|
|
2980
3021
|
/**
|
|
2981
3022
|
* An elevated curved-B rail.
|
|
@@ -2987,6 +3028,12 @@ interface ElevatedCurvedRailBPrototype extends CurvedRailBPrototype {
|
|
|
2987
3028
|
* Requires Space Age to create prototypes with name not starting with `dummy-`. Dummy prototypes cannot be built.
|
|
2988
3029
|
*/
|
|
2989
3030
|
name: string;
|
|
3031
|
+
/**
|
|
3032
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
3033
|
+
*
|
|
3034
|
+
* The value `0` will be treated the same as `nil`.
|
|
3035
|
+
*/
|
|
3036
|
+
selection_priority?: uint8;
|
|
2990
3037
|
}
|
|
2991
3038
|
/**
|
|
2992
3039
|
* An elevated half diagonal rail.
|
|
@@ -2998,6 +3045,12 @@ interface ElevatedHalfDiagonalRailPrototype extends HalfDiagonalRailPrototype {
|
|
|
2998
3045
|
* Requires Space Age to create prototypes with name not starting with `dummy-`. Dummy prototypes cannot be built.
|
|
2999
3046
|
*/
|
|
3000
3047
|
name: string;
|
|
3048
|
+
/**
|
|
3049
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
3050
|
+
*
|
|
3051
|
+
* The value `0` will be treated the same as `nil`.
|
|
3052
|
+
*/
|
|
3053
|
+
selection_priority?: uint8;
|
|
3001
3054
|
}
|
|
3002
3055
|
/**
|
|
3003
3056
|
* An elevated straight rail.
|
|
@@ -3009,6 +3062,12 @@ interface ElevatedStraightRailPrototype extends StraightRailPrototype {
|
|
|
3009
3062
|
* Requires Space Age to create prototypes with name not starting with `dummy-`. Dummy prototypes cannot be built.
|
|
3010
3063
|
*/
|
|
3011
3064
|
name: string;
|
|
3065
|
+
/**
|
|
3066
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
3067
|
+
*
|
|
3068
|
+
* The value `0` will be treated the same as `nil`.
|
|
3069
|
+
*/
|
|
3070
|
+
selection_priority?: uint8;
|
|
3012
3071
|
}
|
|
3013
3072
|
/**
|
|
3014
3073
|
* Can spawn entities. Used for biter/spitter nests.
|
|
@@ -3045,7 +3104,7 @@ interface EnemySpawnerPrototype extends EntityWithOwnerPrototype {
|
|
|
3045
3104
|
*/
|
|
3046
3105
|
max_friends_around_to_spawn: uint32;
|
|
3047
3106
|
/**
|
|
3048
|
-
* Max richness to determine spawn shift. Spawn shift is linear interpolation between 0 and max_spawn_shift.
|
|
3107
|
+
* Max richness to determine spawn shift. Spawn shift is a linear interpolation between 0 and max_spawn_shift.
|
|
3049
3108
|
*/
|
|
3050
3109
|
max_richness_for_spawn_shift: double;
|
|
3051
3110
|
/**
|
|
@@ -3067,6 +3126,8 @@ interface EnemySpawnerPrototype extends EntityWithOwnerPrototype {
|
|
|
3067
3126
|
spawn_decorations_on_expansion?: boolean;
|
|
3068
3127
|
/**
|
|
3069
3128
|
* Ticks for cooldown after unit is spawned. The first member of the tuple is min, the second member of the tuple is max.
|
|
3129
|
+
*
|
|
3130
|
+
* The resulting spawning cooldown is a linear interpolation between min and max based on the current evolution factor.
|
|
3070
3131
|
*/
|
|
3071
3132
|
spawning_cooldown: [
|
|
3072
3133
|
double,
|
|
@@ -3323,6 +3384,19 @@ interface EntityPrototype extends Prototype {
|
|
|
3323
3384
|
* When this is true, this entity prototype should be included during tile collision checks with tiles that have {@link TilePrototype::check_collision_with_entities | prototype:TilePrototype::check_collision_with_entities} set to true.
|
|
3324
3385
|
*/
|
|
3325
3386
|
protected_from_tile_building?: boolean;
|
|
3387
|
+
/**
|
|
3388
|
+
* @example ```
|
|
3389
|
+
radius_visualisation_specification =
|
|
3390
|
+
{
|
|
3391
|
+
sprite =
|
|
3392
|
+
{
|
|
3393
|
+
filename = "__base__/graphics/entity/electric-mining-drill/electric-mining-drill-radius-visualization.png",
|
|
3394
|
+
size = 10
|
|
3395
|
+
},
|
|
3396
|
+
distance = 6
|
|
3397
|
+
}
|
|
3398
|
+
```
|
|
3399
|
+
*/
|
|
3326
3400
|
radius_visualisation_specification?: RadiusVisualisationSpecification;
|
|
3327
3401
|
/**
|
|
3328
3402
|
* The entity that remains when this one is mined, deconstructed or fast-replaced. The entity wont actually be spawned if it would collide with the entity that is in the process of being mined.
|
|
@@ -3685,6 +3759,12 @@ interface ExplosionPrototype extends EntityPrototype {
|
|
|
3685
3759
|
scale_initial?: float;
|
|
3686
3760
|
scale_initial_deviation?: float;
|
|
3687
3761
|
scale_out_duration?: uint8;
|
|
3762
|
+
/**
|
|
3763
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
3764
|
+
*
|
|
3765
|
+
* The value `0` will be treated the same as `nil`.
|
|
3766
|
+
*/
|
|
3767
|
+
selection_priority?: uint8;
|
|
3688
3768
|
/**
|
|
3689
3769
|
* Mandatory if `smoke_count` > 0.
|
|
3690
3770
|
*/
|
|
@@ -3750,6 +3830,12 @@ interface FireFlamePrototype extends EntityPrototype {
|
|
|
3750
3830
|
secondary_picture_fade_out_start?: uint32;
|
|
3751
3831
|
secondary_pictures?: AnimationVariations;
|
|
3752
3832
|
secondary_render_layer?: RenderLayer;
|
|
3833
|
+
/**
|
|
3834
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
3835
|
+
*
|
|
3836
|
+
* The value `0` will be treated the same as `nil`.
|
|
3837
|
+
*/
|
|
3838
|
+
selection_priority?: uint8;
|
|
3753
3839
|
small_tree_fire_pictures?: AnimationVariations;
|
|
3754
3840
|
smoke?: SmokeSource[];
|
|
3755
3841
|
smoke_fade_in_duration?: uint32;
|
|
@@ -3767,7 +3853,7 @@ interface FireFlamePrototype extends EntityPrototype {
|
|
|
3767
3853
|
uses_alternative_behavior?: boolean;
|
|
3768
3854
|
}
|
|
3769
3855
|
/**
|
|
3770
|
-
* Entity that spawns in water tiles, which can be mined. Moves around unless
|
|
3856
|
+
* Entity that spawns in water tiles, which can be mined. Moves around unless it is {@link LuaEntity::disabled_by_script | runtime:LuaEntity::disabled_by_script} or marked for deconstruction.
|
|
3771
3857
|
* @example ```
|
|
3772
3858
|
{
|
|
3773
3859
|
type = "fish",
|
|
@@ -3944,6 +4030,12 @@ interface FluidStreamPrototype extends EntityPrototype {
|
|
|
3944
4030
|
* The point in the particles projectile arc to start spawning smoke. 0.5 (the default) starts spawning smoke at the halfway point between the source and target.
|
|
3945
4031
|
*/
|
|
3946
4032
|
progress_to_create_smoke?: float;
|
|
4033
|
+
/**
|
|
4034
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
4035
|
+
*
|
|
4036
|
+
* The value `0` will be treated the same as `nil`.
|
|
4037
|
+
*/
|
|
4038
|
+
selection_priority?: uint8;
|
|
3947
4039
|
shadow?: Animation;
|
|
3948
4040
|
shadow_scale_enabled?: boolean;
|
|
3949
4041
|
/**
|
|
@@ -4062,6 +4154,12 @@ interface FlyingRobotPrototype extends EntityWithOwnerPrototype {
|
|
|
4062
4154
|
* Used only by {@link robots with logistic interface | prototype:RobotWithLogisticInterfacePrototype}.
|
|
4063
4155
|
*/
|
|
4064
4156
|
min_to_charge?: float;
|
|
4157
|
+
/**
|
|
4158
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
4159
|
+
*
|
|
4160
|
+
* The value `0` will be treated the same as `nil`.
|
|
4161
|
+
*/
|
|
4162
|
+
selection_priority?: uint8;
|
|
4065
4163
|
/**
|
|
4066
4164
|
* The flying speed of the robot, in tiles/tick.
|
|
4067
4165
|
*/
|
|
@@ -4455,6 +4553,12 @@ interface HeatPipePrototype extends EntityWithOwnerPrototype {
|
|
|
4455
4553
|
* Must be >= 0.
|
|
4456
4554
|
*/
|
|
4457
4555
|
heating_radius?: float;
|
|
4556
|
+
/**
|
|
4557
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
4558
|
+
*
|
|
4559
|
+
* The value `0` will be treated the same as `nil`.
|
|
4560
|
+
*/
|
|
4561
|
+
selection_priority?: uint8;
|
|
4458
4562
|
}
|
|
4459
4563
|
/**
|
|
4460
4564
|
* Used to attach graphics for {@link cursor boxes | prototype:CursorBoxType} to entities during runtime. HighlightBoxEntity can also be independent from entities so it is simply drawn somewhere in the world. See {@link LuaSurface::create_entity | runtime:LuaSurface::create_entity} for the available options for type "highlight-box".
|
|
@@ -4462,6 +4566,12 @@ interface HeatPipePrototype extends EntityWithOwnerPrototype {
|
|
|
4462
4566
|
* The {@link collision_box | prototype:EntityPrototype::collision_box} of the highlight box prototype is ignored during runtime, instead the "bounding_box" given in create_entity() or the selection box of the target entity is used.
|
|
4463
4567
|
*/
|
|
4464
4568
|
interface HighlightBoxEntityPrototype extends EntityPrototype {
|
|
4569
|
+
/**
|
|
4570
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
4571
|
+
*
|
|
4572
|
+
* The value `0` will be treated the same as `nil`.
|
|
4573
|
+
*/
|
|
4574
|
+
selection_priority?: uint8;
|
|
4465
4575
|
}
|
|
4466
4576
|
/**
|
|
4467
4577
|
* @example ```
|
|
@@ -5275,6 +5385,12 @@ interface LandMinePrototype extends EntityWithOwnerPrototype {
|
|
|
5275
5385
|
* The sprite of the landmine of an enemy force when it is armed.
|
|
5276
5386
|
*/
|
|
5277
5387
|
picture_set_enemy?: Sprite;
|
|
5388
|
+
/**
|
|
5389
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
5390
|
+
*
|
|
5391
|
+
* The value `0` will be treated the same as `nil`.
|
|
5392
|
+
*/
|
|
5393
|
+
selection_priority?: uint8;
|
|
5278
5394
|
/**
|
|
5279
5395
|
* Time between placing and the landmine being armed, in ticks.
|
|
5280
5396
|
*/
|
|
@@ -5774,7 +5890,23 @@ interface MiningDrillPrototype extends EntityWithOwnerPrototype {
|
|
|
5774
5890
|
wet_mining_graphics_set?: MiningDrillGraphicsSet;
|
|
5775
5891
|
}
|
|
5776
5892
|
/**
|
|
5777
|
-
* Block of arbitrary data set by mods in
|
|
5893
|
+
* Block of arbitrary data set by mods in prototype stage.
|
|
5894
|
+
*
|
|
5895
|
+
* During runtime stage, this arbitrary data can be accessed through {@link LuaPrototypes::mod_data | runtime:LuaPrototypes::mod_data}.
|
|
5896
|
+
* @example ```
|
|
5897
|
+
{
|
|
5898
|
+
type = "mod-data",
|
|
5899
|
+
name = "my-own-great-mod-data",
|
|
5900
|
+
data_type = "my-mod.my-data-type",
|
|
5901
|
+
data =
|
|
5902
|
+
{
|
|
5903
|
+
a_string = "a string",
|
|
5904
|
+
a_number = 6.7,
|
|
5905
|
+
a_table = {x=2, y=3, z="yes"},
|
|
5906
|
+
a_bool = true,
|
|
5907
|
+
}
|
|
5908
|
+
}
|
|
5909
|
+
```
|
|
5778
5910
|
*/
|
|
5779
5911
|
interface ModData extends Prototype {
|
|
5780
5912
|
data: Record<string, AnyBasic>;
|
|
@@ -6088,6 +6220,12 @@ interface ParticleSourcePrototype extends EntityPrototype {
|
|
|
6088
6220
|
* Mandatory if `smoke` is not defined.
|
|
6089
6221
|
*/
|
|
6090
6222
|
particle?: ParticleID;
|
|
6223
|
+
/**
|
|
6224
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
6225
|
+
*
|
|
6226
|
+
* The value `0` will be treated the same as `nil`.
|
|
6227
|
+
*/
|
|
6228
|
+
selection_priority?: uint8;
|
|
6091
6229
|
/**
|
|
6092
6230
|
* Mandatory if `particle` is not defined.
|
|
6093
6231
|
*/
|
|
@@ -6191,6 +6329,12 @@ interface PlayerDamagedAchievementPrototype extends AchievementPrototype {
|
|
|
6191
6329
|
* Deprecated in 2.0.
|
|
6192
6330
|
*/
|
|
6193
6331
|
interface PlayerPortPrototype extends EntityWithOwnerPrototype {
|
|
6332
|
+
/**
|
|
6333
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
6334
|
+
*
|
|
6335
|
+
* The value `0` will be treated the same as `nil`.
|
|
6336
|
+
*/
|
|
6337
|
+
selection_priority?: uint8;
|
|
6194
6338
|
}
|
|
6195
6339
|
/**
|
|
6196
6340
|
* A {@link power switch | https://wiki.factorio.com/Power_switch}.
|
|
@@ -6369,6 +6513,12 @@ interface ProjectilePrototype extends EntityPrototype {
|
|
|
6369
6513
|
* Whether the animation of the projectile is rotated to match the direction of travel.
|
|
6370
6514
|
*/
|
|
6371
6515
|
rotatable?: boolean;
|
|
6516
|
+
/**
|
|
6517
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
6518
|
+
*
|
|
6519
|
+
* The value `0` will be treated the same as `nil`.
|
|
6520
|
+
*/
|
|
6521
|
+
selection_priority?: uint8;
|
|
6372
6522
|
shadow?: RotatedAnimationVariations;
|
|
6373
6523
|
smoke?: SmokeSource[];
|
|
6374
6524
|
speed_modifier?: Vector;
|
|
@@ -6744,7 +6894,7 @@ interface RailChainSignalPrototype extends RailSignalBasePrototype {
|
|
|
6744
6894
|
interface RailPlannerPrototype extends ItemPrototype {
|
|
6745
6895
|
manual_length_limit?: double;
|
|
6746
6896
|
/**
|
|
6747
|
-
* May not be an empty array. Entities must be rails
|
|
6897
|
+
* May not be an empty array. Entities must be rails.
|
|
6748
6898
|
*/
|
|
6749
6899
|
rails: EntityID[];
|
|
6750
6900
|
/**
|
|
@@ -6775,6 +6925,12 @@ interface RailPrototype extends EntityWithOwnerPrototype {
|
|
|
6775
6925
|
* The rail {@link selection_boxes | prototype:EntityPrototype::selection_box} are automatically calculated from the collision boxes, which are hardcoded. So effectively the selection boxes also hardcoded.
|
|
6776
6926
|
*/
|
|
6777
6927
|
selection_box?: BoundingBox;
|
|
6928
|
+
/**
|
|
6929
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
6930
|
+
*
|
|
6931
|
+
* The value `0` will be treated the same as `nil`.
|
|
6932
|
+
*/
|
|
6933
|
+
selection_priority?: uint8;
|
|
6778
6934
|
/**
|
|
6779
6935
|
* Sound played when a character walks over this rail.
|
|
6780
6936
|
*/
|
|
@@ -6848,6 +7004,12 @@ interface RailSignalBasePrototype extends EntityWithOwnerPrototype {
|
|
|
6848
7004
|
*/
|
|
6849
7005
|
flags?: EntityPrototypeFlags;
|
|
6850
7006
|
ground_picture_set: RailSignalPictureSet;
|
|
7007
|
+
/**
|
|
7008
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
7009
|
+
*
|
|
7010
|
+
* The value `0` will be treated the same as `nil`.
|
|
7011
|
+
*/
|
|
7012
|
+
selection_priority?: uint8;
|
|
6851
7013
|
}
|
|
6852
7014
|
/**
|
|
6853
7015
|
* A {@link rail signal | https://wiki.factorio.com/Rail_signal}.
|
|
@@ -7117,7 +7279,7 @@ interface RecipePrototype extends Prototype {
|
|
|
7117
7279
|
/**
|
|
7118
7280
|
* A table containing ingredient names and amounts. Can also contain information about fluid temperature and whether some of the amount is ignored by production statistics.
|
|
7119
7281
|
*
|
|
7120
|
-
*
|
|
7282
|
+
* Can be set to an empty table to create a recipe that needs no ingredients. {@link Assembling machines | prototype:AssemblingMachinePrototype::ingredient_count} do not support recipes with more than 65 535 different item ingredients.
|
|
7121
7283
|
*
|
|
7122
7284
|
* Duplicate ingredients, e.g. two entries with the same name, are *not* allowed. In-game, the item ingredients are ordered by {@link ItemGroup::order_in_recipe | prototype:ItemGroup::order_in_recipe}.
|
|
7123
7285
|
* @example ```
|
|
@@ -7167,7 +7329,9 @@ interface RecipePrototype extends Prototype {
|
|
|
7167
7329
|
/**
|
|
7168
7330
|
* A table containing result names and amounts. Products also contain information such as fluid temperature, probability of results and whether some of the amount is ignored by productivity.
|
|
7169
7331
|
*
|
|
7170
|
-
* Can be set to an empty table to create a recipe that produces nothing.
|
|
7332
|
+
* Can be set to an empty table to create a recipe that produces nothing. {@link Assembling machines | prototype:AssemblingMachinePrototype::max_item_product_count} do not support recipes with more than 65 535 different item products.
|
|
7333
|
+
*
|
|
7334
|
+
* Duplicate results, e.g. two entries with the same name, are allowed.
|
|
7171
7335
|
* @example ```
|
|
7172
7336
|
results =
|
|
7173
7337
|
{
|
|
@@ -7391,6 +7555,12 @@ interface ResourceEntityPrototype extends EntityPrototype {
|
|
|
7391
7555
|
* When hovering over this resource in the map view: How far to search for other resource patches of this type to display as one (summing amount, white outline).
|
|
7392
7556
|
*/
|
|
7393
7557
|
resource_patch_search_radius?: uint32;
|
|
7558
|
+
/**
|
|
7559
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
7560
|
+
*
|
|
7561
|
+
* The value `0` will be treated the same as `nil`.
|
|
7562
|
+
*/
|
|
7563
|
+
selection_priority?: uint8;
|
|
7394
7564
|
/**
|
|
7395
7565
|
* Number of stages the animation has.
|
|
7396
7566
|
*/
|
|
@@ -7864,6 +8034,12 @@ interface RocketSiloRocketPrototype extends EntityPrototype {
|
|
|
7864
8034
|
rocket_smoke_top3_animation?: Animation;
|
|
7865
8035
|
rocket_sprite?: Sprite;
|
|
7866
8036
|
rocket_visible_distance_from_center: float;
|
|
8037
|
+
/**
|
|
8038
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
8039
|
+
*
|
|
8040
|
+
* The value `0` will be treated the same as `nil`.
|
|
8041
|
+
*/
|
|
8042
|
+
selection_priority?: uint8;
|
|
7867
8043
|
shadow_fade_out_end_ratio: double;
|
|
7868
8044
|
shadow_fade_out_start_ratio: double;
|
|
7869
8045
|
shadow_slave_entity?: EntityID;
|
|
@@ -7883,6 +8059,12 @@ interface RocketSiloRocketPrototype extends EntityPrototype {
|
|
|
7883
8059
|
```
|
|
7884
8060
|
*/
|
|
7885
8061
|
interface RocketSiloRocketShadowPrototype extends EntityPrototype {
|
|
8062
|
+
/**
|
|
8063
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
8064
|
+
*
|
|
8065
|
+
* The value `0` will be treated the same as `nil`.
|
|
8066
|
+
*/
|
|
8067
|
+
selection_priority?: uint8;
|
|
7886
8068
|
}
|
|
7887
8069
|
/**
|
|
7888
8070
|
* The abstract base of all rolling stock.
|
|
@@ -8328,6 +8510,12 @@ interface SmokePrototype extends EntityPrototype {
|
|
|
8328
8510
|
*/
|
|
8329
8511
|
movement_slow_down_factor?: double;
|
|
8330
8512
|
render_layer?: RenderLayer;
|
|
8513
|
+
/**
|
|
8514
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
8515
|
+
*
|
|
8516
|
+
* The value `0` will be treated the same as `nil`.
|
|
8517
|
+
*/
|
|
8518
|
+
selection_priority?: uint8;
|
|
8331
8519
|
show_when_smoke_off?: boolean;
|
|
8332
8520
|
spread_duration?: uint32;
|
|
8333
8521
|
start_scale?: double;
|
|
@@ -8672,6 +8860,12 @@ interface SpectatorControllerPrototype {
|
|
|
8672
8860
|
*/
|
|
8673
8861
|
interface SpeechBubblePrototype extends EntityPrototype {
|
|
8674
8862
|
fade_in_out_ticks?: uint32;
|
|
8863
|
+
/**
|
|
8864
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
8865
|
+
*
|
|
8866
|
+
* The value `0` will be treated the same as `nil`.
|
|
8867
|
+
*/
|
|
8868
|
+
selection_priority?: uint8;
|
|
8675
8869
|
/**
|
|
8676
8870
|
* Needs a style of the type "speech_bubble_style", defined inside the gui styles.
|
|
8677
8871
|
*/
|
|
@@ -8709,6 +8903,12 @@ interface SpiderLegPrototype extends EntityWithOwnerPrototype {
|
|
|
8709
8903
|
minimal_step_size: double;
|
|
8710
8904
|
movement_acceleration: double;
|
|
8711
8905
|
movement_based_position_selection_distance: double;
|
|
8906
|
+
/**
|
|
8907
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
8908
|
+
*
|
|
8909
|
+
* The value `0` will be treated the same as `nil`.
|
|
8910
|
+
*/
|
|
8911
|
+
selection_priority?: uint8;
|
|
8712
8912
|
/**
|
|
8713
8913
|
* A scalar that controls the amount of influence this leg has over the position of the torso. Must be greater than 0.
|
|
8714
8914
|
*/
|
|
@@ -9080,6 +9280,12 @@ interface StickerPrototype extends EntityPrototype {
|
|
|
9080
9280
|
* 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.
|
|
9081
9281
|
*/
|
|
9082
9282
|
selection_box_type?: CursorBoxType;
|
|
9283
|
+
/**
|
|
9284
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
9285
|
+
*
|
|
9286
|
+
* The value `0` will be treated the same as `nil`.
|
|
9287
|
+
*/
|
|
9288
|
+
selection_priority?: uint8;
|
|
9083
9289
|
single_particle?: boolean;
|
|
9084
9290
|
/**
|
|
9085
9291
|
* If this is given, this sticker is considered a "fire sticker" for some functions, such as {@link BaseAttackParameters::fire_penalty | prototype:BaseAttackParameters::fire_penalty} and {@link EntityPrototypeFlags::not-flammable | prototype:EntityPrototypeFlags::not_flammable}.
|
|
@@ -9273,6 +9479,11 @@ interface TechnologyPrototype extends Prototype {
|
|
|
9273
9479
|
```
|
|
9274
9480
|
*/
|
|
9275
9481
|
effects?: Modifier[];
|
|
9482
|
+
/**
|
|
9483
|
+
* This can be `false` to disable the technology at the start of the game, or `true` to leave it enabled.
|
|
9484
|
+
*
|
|
9485
|
+
* Changes to this property do not affect existing save files, as the enabled state is saved in the save file and not reloaded from the prototype.
|
|
9486
|
+
*/
|
|
9276
9487
|
enabled?: boolean;
|
|
9277
9488
|
/**
|
|
9278
9489
|
* Whether the technology should be shown in the technology tree GUI when "Show only essential technologies" is enabled.
|
|
@@ -9349,6 +9560,8 @@ interface TechnologyPrototype extends Prototype {
|
|
|
9349
9560
|
upgrade?: boolean;
|
|
9350
9561
|
/**
|
|
9351
9562
|
* Controls whether the technology is shown in the tech GUI when it is not `enabled`.
|
|
9563
|
+
*
|
|
9564
|
+
* Changes to this property do not affect existing save files, as the visible_when_disabled state is saved in the save file and not reloaded from the prototype.
|
|
9352
9565
|
*/
|
|
9353
9566
|
visible_when_disabled?: boolean;
|
|
9354
9567
|
}
|
|
@@ -9731,6 +9944,12 @@ interface TransportBeltConnectablePrototype extends EntityWithOwnerPrototype {
|
|
|
9731
9944
|
* Transport belt connectable entities cannot have the `"building-direction-8-way"` flag.
|
|
9732
9945
|
*/
|
|
9733
9946
|
flags?: EntityPrototypeFlags;
|
|
9947
|
+
/**
|
|
9948
|
+
* The entity with the higher number is selectable before the entity with the lower number.
|
|
9949
|
+
*
|
|
9950
|
+
* The value `0` will be treated the same as `nil`.
|
|
9951
|
+
*/
|
|
9952
|
+
selection_priority?: uint8;
|
|
9734
9953
|
/**
|
|
9735
9954
|
* The speed of the belt: `speed × 480 = x Items/second`.
|
|
9736
9955
|
*
|
|
@@ -10027,7 +10246,13 @@ interface UndergroundBeltPrototype extends TransportBeltConnectablePrototype {
|
|
|
10027
10246
|
* Entity that moves around and attacks players, for example {@link biters and spitters | https://wiki.factorio.com/Enemies#Creatures}.
|
|
10028
10247
|
*/
|
|
10029
10248
|
interface UnitPrototype extends EntityWithOwnerPrototype {
|
|
10249
|
+
/**
|
|
10250
|
+
* The pollution amount that has to be absorbed by the unit's {@link spawner | prototype:EnemySpawnerPrototype} before the unit will leave the spawner and attack the source of the pollution.
|
|
10251
|
+
*/
|
|
10030
10252
|
absorptions_to_join_attack?: Record<AirbornePollutantID, float>;
|
|
10253
|
+
/**
|
|
10254
|
+
* Whether this unit is affected by tile {@link walking speed modifiers | prototype:TilePrototype::walking_speed_modifier}.
|
|
10255
|
+
*/
|
|
10031
10256
|
affected_by_tiles?: boolean;
|
|
10032
10257
|
ai_settings?: UnitAISettings;
|
|
10033
10258
|
/**
|
|
@@ -10036,7 +10261,7 @@ interface UnitPrototype extends EntityWithOwnerPrototype {
|
|
|
10036
10261
|
allow_run_time_change_of_is_military_target?: false;
|
|
10037
10262
|
alternative_attacking_frame_sequence?: UnitAlternativeFrameSequence;
|
|
10038
10263
|
/**
|
|
10039
|
-
* Requires animation in attack_parameters. Requires ammo_type in attack_parameters.
|
|
10264
|
+
* Requires `animation` in attack_parameters. Requires `ammo_type` in attack_parameters.
|
|
10040
10265
|
*/
|
|
10041
10266
|
attack_parameters: AttackParameters;
|
|
10042
10267
|
can_open_gates?: boolean;
|
|
@@ -10048,11 +10273,11 @@ interface UnitPrototype extends EntityWithOwnerPrototype {
|
|
|
10048
10273
|
distance_per_frame: float;
|
|
10049
10274
|
distraction_cooldown: uint32;
|
|
10050
10275
|
/**
|
|
10051
|
-
* The sound file to play
|
|
10276
|
+
* The sound file to play this unit dies.
|
|
10052
10277
|
*/
|
|
10053
10278
|
dying_sound?: Sound;
|
|
10054
10279
|
/**
|
|
10055
|
-
* If
|
|
10280
|
+
* If this unit is immune to movement by belts.
|
|
10056
10281
|
*/
|
|
10057
10282
|
has_belt_immunity?: boolean;
|
|
10058
10283
|
/**
|
|
@@ -10067,7 +10292,7 @@ interface UnitPrototype extends EntityWithOwnerPrototype {
|
|
|
10067
10292
|
min_pursue_time?: uint32;
|
|
10068
10293
|
move_while_shooting?: boolean;
|
|
10069
10294
|
/**
|
|
10070
|
-
* Movement speed of
|
|
10295
|
+
* Movement speed of this unit in the world, in tiles per tick. Must be equal to or greater than 0.
|
|
10071
10296
|
*/
|
|
10072
10297
|
movement_speed: float;
|
|
10073
10298
|
/**
|
|
@@ -10078,9 +10303,14 @@ interface UnitPrototype extends EntityWithOwnerPrototype {
|
|
|
10078
10303
|
rotation_speed?: float;
|
|
10079
10304
|
run_animation: RotatedAnimation;
|
|
10080
10305
|
/**
|
|
10306
|
+
* List of positions in the `run_animation` when the `walking_sound` is played.
|
|
10307
|
+
*
|
|
10081
10308
|
* Only loaded if `walking_sound` is defined.
|
|
10082
10309
|
*/
|
|
10083
10310
|
running_sound_animation_positions?: float[];
|
|
10311
|
+
/**
|
|
10312
|
+
* Multiplier for the {@link EnemySpawnerPrototype::spawning_cooldown | prototype:EnemySpawnerPrototype::spawning_cooldown} after it spawns this unit.
|
|
10313
|
+
*/
|
|
10084
10314
|
spawning_time_modifier?: double;
|
|
10085
10315
|
/**
|
|
10086
10316
|
* Max is 100.
|
|
@@ -10090,7 +10320,7 @@ interface UnitPrototype extends EntityWithOwnerPrototype {
|
|
|
10090
10320
|
vision_distance: double;
|
|
10091
10321
|
walking_sound?: Sound;
|
|
10092
10322
|
/**
|
|
10093
|
-
* A sound
|
|
10323
|
+
* A sound this unit makes when it sets out to attack.
|
|
10094
10324
|
*/
|
|
10095
10325
|
warcry?: Sound;
|
|
10096
10326
|
}
|