factorio-types 1.2.68 → 1.2.69
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 +33 -36
- package/dist/concepts.d.ts +7 -8
- package/dist/datacollection.d.ts +1 -1
- package/dist/defines.d.ts +1 -1
- package/dist/events.d.ts +1 -1
- package/dist/global.d.ts +1 -1
- package/dist/prototypes.d.ts +8 -6
- package/dist/types.d.ts +12 -2
- package/package.json +2 -2
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.1.
|
|
5
|
+
// Factorio version 2.1.20
|
|
6
6
|
// API version 6
|
|
7
7
|
|
|
8
8
|
declare namespace runtime {
|
|
@@ -8676,7 +8676,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
8676
8676
|
/**
|
|
8677
8677
|
* The crafting speed of this crafting-machine or character.
|
|
8678
8678
|
*/
|
|
8679
|
-
get_crafting_speed(this: void, quality?: QualityID): double;
|
|
8679
|
+
get_crafting_speed(this: void, quality?: QualityID): double | null;
|
|
8680
8680
|
get_duration(this: void, quality?: QualityID): uint32 | null;
|
|
8681
8681
|
get_energy_distribution_efficiency(this: void, quality?: QualityID): double | null;
|
|
8682
8682
|
/**
|
|
@@ -8750,7 +8750,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
8750
8750
|
/**
|
|
8751
8751
|
* The pumping speed of this offshore pump or normal pump.
|
|
8752
8752
|
*/
|
|
8753
|
-
get_pumping_speed(this: void, quality?: QualityID): double;
|
|
8753
|
+
get_pumping_speed(this: void, quality?: QualityID): double | null;
|
|
8754
8754
|
/**
|
|
8755
8755
|
* The base researching speed of this lab prototype.
|
|
8756
8756
|
*/
|
|
@@ -8758,24 +8758,24 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
8758
8758
|
/**
|
|
8759
8759
|
* The supply area of this electric pole or beacon prototype.
|
|
8760
8760
|
*/
|
|
8761
|
-
get_supply_area_distance(this: void, quality?: QualityID): double;
|
|
8761
|
+
get_supply_area_distance(this: void, quality?: QualityID): double | null;
|
|
8762
8762
|
/**
|
|
8763
8763
|
* The maximum flow rate through this valve.
|
|
8764
8764
|
*/
|
|
8765
|
-
get_valve_flow_rate(this: void, quality?: QualityID): double;
|
|
8765
|
+
get_valve_flow_rate(this: void, quality?: QualityID): double | null;
|
|
8766
8766
|
/**
|
|
8767
8767
|
* Test whether this entity prototype has a certain flag set.
|
|
8768
8768
|
* @param flag The flag to test.
|
|
8769
8769
|
* @returns `true` if this prototype has the given flag set.
|
|
8770
8770
|
*/
|
|
8771
8771
|
has_flag(this: void, flag: EntityPrototypeFlag): boolean;
|
|
8772
|
-
readonly absorptions_per_second
|
|
8772
|
+
readonly absorptions_per_second?: Record<string, EnemySpawnerAbsorption>;
|
|
8773
8773
|
/**
|
|
8774
8774
|
* A table of pollutions amounts that has to be absorbed by the unit's spawner before the unit will leave the spawner and attack the source of the pollution, indexed by the name of each absorbed pollution type.
|
|
8775
8775
|
*/
|
|
8776
8776
|
readonly absorptions_to_join_attack?: Record<string, float>;
|
|
8777
8777
|
readonly acceleration?: double;
|
|
8778
|
-
readonly acceleration_rate
|
|
8778
|
+
readonly acceleration_rate?: double;
|
|
8779
8779
|
readonly accepted_seeds?: string[];
|
|
8780
8780
|
readonly action?: TriggerItem[];
|
|
8781
8781
|
readonly action_cooldown?: uint32;
|
|
@@ -8802,7 +8802,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
8802
8802
|
*/
|
|
8803
8803
|
readonly air_resistance?: double;
|
|
8804
8804
|
readonly alarm_trigger?: TriggerEffectItem[];
|
|
8805
|
-
readonly alert_after_time
|
|
8805
|
+
readonly alert_after_time?: uint32;
|
|
8806
8806
|
/**
|
|
8807
8807
|
* The alert icon scale of this entity prototype.
|
|
8808
8808
|
*/
|
|
@@ -8901,11 +8901,11 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
8901
8901
|
* The attack result of this entity, if any.
|
|
8902
8902
|
*/
|
|
8903
8903
|
readonly attack_result?: TriggerItem[];
|
|
8904
|
-
readonly attack_target_mask
|
|
8904
|
+
readonly attack_target_mask?: TriggerTargetMask;
|
|
8905
8905
|
readonly attacking_speed?: double;
|
|
8906
8906
|
readonly attractor_hit_effect?: TriggerItem[];
|
|
8907
8907
|
readonly auto_connect_up_to_n_wires?: uint8;
|
|
8908
|
-
readonly auto_setup_collision_box
|
|
8908
|
+
readonly auto_setup_collision_box?: boolean;
|
|
8909
8909
|
readonly auto_sort_inventory?: boolean;
|
|
8910
8910
|
/**
|
|
8911
8911
|
* The amount of ammo that inserters automatically insert into this ammo turret, artillery turret or artillery wagon.
|
|
@@ -9011,7 +9011,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
9011
9011
|
readonly color?: Color;
|
|
9012
9012
|
readonly combat_robot_friction?: double;
|
|
9013
9013
|
readonly connectable_box?: BoundingBox;
|
|
9014
|
-
readonly connection_category
|
|
9014
|
+
readonly connection_category?: string[];
|
|
9015
9015
|
readonly connection_distance?: double;
|
|
9016
9016
|
readonly connects_to_other_radars?: boolean;
|
|
9017
9017
|
/**
|
|
@@ -9037,7 +9037,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
9037
9037
|
* The value in the dictionary is meaningless and exists just to allow for easy lookup.
|
|
9038
9038
|
*/
|
|
9039
9039
|
readonly crafting_categories?: Record<string, true>;
|
|
9040
|
-
readonly crafting_speed_quality_multiplier
|
|
9040
|
+
readonly crafting_speed_quality_multiplier?: LuaTable<QualityID, double>;
|
|
9041
9041
|
/**
|
|
9042
9042
|
* The crane energy usage of this agricultural tower prototype.
|
|
9043
9043
|
*/
|
|
@@ -9225,14 +9225,14 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
9225
9225
|
* The direct energy usage of this entity, if any.
|
|
9226
9226
|
*/
|
|
9227
9227
|
readonly energy_usage?: double;
|
|
9228
|
-
readonly energy_usage_quality_multiplier
|
|
9228
|
+
readonly energy_usage_quality_multiplier?: LuaTable<QualityID, double>;
|
|
9229
9229
|
readonly energy_usage_quality_scaling?: float;
|
|
9230
9230
|
/**
|
|
9231
9231
|
* The engine starting speed for this rocket silo rocket prototype.
|
|
9232
9232
|
*/
|
|
9233
9233
|
readonly engine_starting_speed?: double;
|
|
9234
9234
|
readonly enraged_duration?: MapTick;
|
|
9235
|
-
readonly enraged_speed
|
|
9235
|
+
readonly enraged_speed?: double;
|
|
9236
9236
|
readonly enter_drop_mode_if_held_stack_spoiled?: boolean;
|
|
9237
9237
|
readonly enter_vehicle_distance?: double;
|
|
9238
9238
|
readonly erase_contents_when_mined?: boolean;
|
|
@@ -9386,7 +9386,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
9386
9386
|
* The icon positioning for inventories of this entity, if defined.
|
|
9387
9387
|
*/
|
|
9388
9388
|
readonly icons_positioning?: IconSequencePositioning[];
|
|
9389
|
-
readonly ignore_target_mask
|
|
9389
|
+
readonly ignore_target_mask?: TriggerTargetMask;
|
|
9390
9390
|
readonly immune_to_all_impacts?: boolean;
|
|
9391
9391
|
readonly immune_to_cliff_impacts?: boolean;
|
|
9392
9392
|
readonly immune_to_rock_impacts?: boolean;
|
|
@@ -9713,7 +9713,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
9713
9713
|
* Returns the inventory size if this entity is of normal quality. Use {@link LuaEntityPrototype::get_inventory_size | runtime:LuaEntityPrototype::get_inventory_size} for other qualities.
|
|
9714
9714
|
*/
|
|
9715
9715
|
readonly module_inventory_size?: uint32;
|
|
9716
|
-
readonly module_slots_quality_bonus
|
|
9716
|
+
readonly module_slots_quality_bonus?: LuaTable<QualityID, ItemStackIndex>;
|
|
9717
9717
|
/**
|
|
9718
9718
|
* Whether this unit prototype can move while shooting.
|
|
9719
9719
|
*/
|
|
@@ -9861,7 +9861,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
9861
9861
|
*/
|
|
9862
9862
|
readonly revenge_attack_parameters?: AttackParameters;
|
|
9863
9863
|
readonly reversing_power_modifier?: double;
|
|
9864
|
-
readonly rewire_neighbours_when_destroying
|
|
9864
|
+
readonly rewire_neighbours_when_destroying?: boolean;
|
|
9865
9865
|
/**
|
|
9866
9866
|
* The rising speed for this rocket silo rocket prototype.
|
|
9867
9867
|
*/
|
|
@@ -9904,7 +9904,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
9904
9904
|
/**
|
|
9905
9905
|
* How much science pack durability is required to research one science point.
|
|
9906
9906
|
*/
|
|
9907
|
-
readonly science_pack_drain_rate_percent
|
|
9907
|
+
readonly science_pack_drain_rate_percent?: uint8;
|
|
9908
9908
|
readonly search_radius?: double;
|
|
9909
9909
|
/**
|
|
9910
9910
|
* The secondary bounding box used for collision checking, if any. This is only used in rails and rail remnants.
|
|
@@ -9940,9 +9940,9 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
9940
9940
|
readonly smoke_count?: uint16;
|
|
9941
9941
|
readonly smoke_sources?: SmokeSource[];
|
|
9942
9942
|
readonly snap_to_spots_distance?: float;
|
|
9943
|
-
readonly solar_panel_performance_at_day
|
|
9944
|
-
readonly solar_panel_performance_at_night
|
|
9945
|
-
readonly solar_panel_solar_coefficient_property
|
|
9943
|
+
readonly solar_panel_performance_at_day?: double;
|
|
9944
|
+
readonly solar_panel_performance_at_night?: double;
|
|
9945
|
+
readonly solar_panel_solar_coefficient_property?: LuaSurfacePropertyPrototype;
|
|
9946
9946
|
readonly source_offset?: Vector;
|
|
9947
9947
|
readonly source_variance?: Vector;
|
|
9948
9948
|
readonly spawn_blocked_trigger?: TriggerItem[];
|
|
@@ -10068,7 +10068,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
10068
10068
|
*/
|
|
10069
10069
|
readonly torso_rotation_speed?: double;
|
|
10070
10070
|
readonly track_coverage_during_drag_building?: boolean;
|
|
10071
|
-
readonly track_particle_triggers
|
|
10071
|
+
readonly track_particle_triggers?: LuaTable<LuaTilePrototype, TriggerEffectItem[]>;
|
|
10072
10072
|
readonly transition_collision_mask?: CollisionMask;
|
|
10073
10073
|
/**
|
|
10074
10074
|
* If it is a tree, return the number of colors it supports.
|
|
@@ -10086,10 +10086,8 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
10086
10086
|
readonly trigger_radius?: double;
|
|
10087
10087
|
/**
|
|
10088
10088
|
* The trigger target mask for this entity prototype type.
|
|
10089
|
-
*
|
|
10090
|
-
* The values in the dictionary are meaningless and exists just to allow the dictionary type for easy lookup.
|
|
10091
10089
|
*/
|
|
10092
|
-
readonly trigger_target_mask: Record<string,
|
|
10090
|
+
readonly trigger_target_mask: Record<string, true>;
|
|
10093
10091
|
readonly turn_radius?: double;
|
|
10094
10092
|
readonly turn_smoothing?: double;
|
|
10095
10093
|
readonly turn_speed?: float;
|
|
@@ -10131,7 +10129,7 @@ interface LuaEntityPrototype extends LuaPrototypeBase {
|
|
|
10131
10129
|
/**
|
|
10132
10130
|
* If this lab uses the quality drain modifier when consuming science packs.
|
|
10133
10131
|
*/
|
|
10134
|
-
readonly uses_quality_drain_modifier
|
|
10132
|
+
readonly uses_quality_drain_modifier?: boolean;
|
|
10135
10133
|
/**
|
|
10136
10134
|
* 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.
|
|
10137
10135
|
*/
|
|
@@ -10912,7 +10910,7 @@ interface LuaForce {
|
|
|
10912
10910
|
*/
|
|
10913
10911
|
add_custom_alert(this: void, entity: LuaEntity, icon: SignalID, message: LocalisedString, show_on_map: boolean): void;
|
|
10914
10912
|
/**
|
|
10915
|
-
* Add this technology to the back of the research queue
|
|
10913
|
+
* Add this technology to the back of the research queue.
|
|
10916
10914
|
* @returns Whether the technology was successfully added.
|
|
10917
10915
|
*/
|
|
10918
10916
|
add_research(this: void, technology: TechnologyID): boolean;
|
|
@@ -11498,7 +11496,7 @@ interface LuaForce {
|
|
|
11498
11496
|
/**
|
|
11499
11497
|
* The research queue of this force. The first technology in the array is the currently active one. Reading this attribute gives an array of {@link LuaTechnology | runtime:LuaTechnology}.
|
|
11500
11498
|
*
|
|
11501
|
-
* To write to this, the entire table must be written. Providing an empty table or `nil` will empty the research queue and cancel the current research.
|
|
11499
|
+
* To write to this, the entire table must be written. Providing an empty table or `nil` will empty the research queue and cancel the current research.
|
|
11502
11500
|
*
|
|
11503
11501
|
* This only allows mods to queue research that this force is able to research in the first place. As an example, an already researched technology or one whose prerequisites are not fulfilled will not be queued, but dropped silently instead.
|
|
11504
11502
|
*/
|
|
@@ -12261,7 +12259,7 @@ interface LuaGuiElement {
|
|
|
12261
12259
|
*/
|
|
12262
12260
|
get_item(this: void, index: uint32): LocalisedString;
|
|
12263
12261
|
/**
|
|
12264
|
-
* The mod that owns this
|
|
12262
|
+
* The mod that owns this GUI element or `nil` if it's owned by the scenario script.
|
|
12265
12263
|
*
|
|
12266
12264
|
* This has a not-super-expensive, but non-free cost to get.
|
|
12267
12265
|
*/
|
|
@@ -14451,9 +14449,9 @@ interface LuaItemPrototype extends LuaPrototypeBase {
|
|
|
14451
14449
|
*/
|
|
14452
14450
|
readonly fuel_acceleration_multiplier_quality_bonus: double;
|
|
14453
14451
|
/**
|
|
14454
|
-
*
|
|
14452
|
+
* Fuel categories. Only provided when not empty.
|
|
14455
14453
|
*/
|
|
14456
|
-
readonly
|
|
14454
|
+
readonly fuel_categories?: string[];
|
|
14457
14455
|
/**
|
|
14458
14456
|
* The emissions multiplier if this is used as fuel.
|
|
14459
14457
|
*/
|
|
@@ -16495,10 +16493,6 @@ interface LuaPlayer extends LuaControl {
|
|
|
16495
16493
|
* If `true`, circle and name of given player is rendered on the map/chart.
|
|
16496
16494
|
*/
|
|
16497
16495
|
show_on_map: boolean;
|
|
16498
|
-
/**
|
|
16499
|
-
* If `true`, zoom-to-world noise effect will be disabled and environmental sounds will be based on zoom-to-world view instead of position of player's character.
|
|
16500
|
-
*/
|
|
16501
|
-
spectator: boolean;
|
|
16502
16496
|
/**
|
|
16503
16497
|
* All SpiderVehicles currently selected by the player, if they are holding a spidertron remote.
|
|
16504
16498
|
*/
|
|
@@ -19381,6 +19375,8 @@ interface LuaSpaceConnectionPrototype extends LuaPrototypeBase {
|
|
|
19381
19375
|
* The class name of this object. Available even when `valid` is false. For LuaStruct objects it may also be suffixed with a dotted path to a member of the struct.
|
|
19382
19376
|
*/
|
|
19383
19377
|
readonly object_name: string;
|
|
19378
|
+
readonly origin: MapPosition;
|
|
19379
|
+
readonly shape: 'arc' | 'line';
|
|
19384
19380
|
readonly to: LuaSpaceLocationPrototype;
|
|
19385
19381
|
/**
|
|
19386
19382
|
* 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.
|
|
@@ -19411,6 +19407,7 @@ interface LuaSpaceLocationPrototype extends LuaPrototypeBase {
|
|
|
19411
19407
|
*/
|
|
19412
19408
|
readonly object_name: string;
|
|
19413
19409
|
readonly orientation: RealOrientation;
|
|
19410
|
+
readonly origin: MapPosition;
|
|
19414
19411
|
readonly parked_platforms_orientation: RealOrientation;
|
|
19415
19412
|
readonly parked_platforms_position: MapPosition;
|
|
19416
19413
|
readonly player_effects?: TriggerItem[];
|
|
@@ -19763,7 +19760,7 @@ interface LuaStyle {
|
|
|
19763
19760
|
font: string;
|
|
19764
19761
|
font_color: Color;
|
|
19765
19762
|
/**
|
|
19766
|
-
*
|
|
19763
|
+
* GUI of the {@link LuaGuiElement | runtime:LuaGuiElement} of this style.
|
|
19767
19764
|
*/
|
|
19768
19765
|
readonly gui: LuaGui;
|
|
19769
19766
|
/**
|
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 2.1.
|
|
5
|
+
// Factorio version 2.1.20
|
|
6
6
|
// API version 6
|
|
7
7
|
|
|
8
8
|
declare namespace runtime {
|
|
@@ -7100,7 +7100,7 @@ interface MapLocation {
|
|
|
7100
7100
|
direction: defines.direction;
|
|
7101
7101
|
}
|
|
7102
7102
|
/**
|
|
7103
|
-
* Coordinates on a surface, for example of an entity. MapPositions may be specified either as a dictionary with `x`, `y` as keys, or simply as an array with two elements.
|
|
7103
|
+
* Coordinates on a surface, for example of an entity. MapPositions may be specified either as a dictionary with `x`, `y` as keys, or simply as an array with two elements. When reading this is always a dictionary.
|
|
7104
7104
|
*
|
|
7105
7105
|
* The coordinates are saved as a fixed-size 32 bit integer, with 8 bits reserved for decimal precision, meaning the smallest value step is `1/2^8 = 0.00390625` tiles.
|
|
7106
7106
|
* @example ```
|
|
@@ -7909,9 +7909,11 @@ interface ProcessionTimeline {
|
|
|
7909
7909
|
```
|
|
7910
7910
|
* @example ```
|
|
7911
7911
|
-- Products of the "advanced-oil-processing" recipe
|
|
7912
|
-
{
|
|
7913
|
-
{type="fluid", name="
|
|
7914
|
-
{type="fluid", name="
|
|
7912
|
+
{
|
|
7913
|
+
{type = "fluid", name = "heavy-oil", amount = 25},
|
|
7914
|
+
{type = "fluid", name = "light-oil", amount = 45},
|
|
7915
|
+
{type = "fluid", name = "petroleum-gas", amount = 55}
|
|
7916
|
+
}
|
|
7915
7917
|
```
|
|
7916
7918
|
* @example ```
|
|
7917
7919
|
-- What a custom recipe would look like that had a probability of 0.5 to return a
|
|
@@ -12101,8 +12103,6 @@ interface UtilityConstants {
|
|
|
12101
12103
|
logistic_gui_selected_network_highlight_tint: Color;
|
|
12102
12104
|
chart_search_highlight: Color;
|
|
12103
12105
|
selected_chart_search_highlight: Color;
|
|
12104
|
-
zoom_to_world_can_use_nightvision: boolean;
|
|
12105
|
-
zoom_to_world_effect_strength: float;
|
|
12106
12106
|
max_logistic_filter_count: LogisticFilterIndex;
|
|
12107
12107
|
/**
|
|
12108
12108
|
* Will be clamped to the range [1, 100].
|
|
@@ -12168,7 +12168,6 @@ interface UtilityConstants {
|
|
|
12168
12168
|
*/
|
|
12169
12169
|
merge_bonus_gui_production_bonuses?: boolean;
|
|
12170
12170
|
daytime_color_lookup: DaytimeColorLookupTable;
|
|
12171
|
-
zoom_to_world_daytime_color_lookup: DaytimeColorLookupTable;
|
|
12172
12171
|
frozen_color_lookup: ColorLookupTable;
|
|
12173
12172
|
default_platform_surface_render_parameters: SurfaceRenderParameters;
|
|
12174
12173
|
drop_item_radius: double;
|
package/dist/datacollection.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.1.
|
|
5
|
+
// Factorio version 2.1.20
|
|
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.1.
|
|
5
|
+
// Factorio version 2.1.20
|
|
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.1.
|
|
5
|
+
// Factorio version 2.1.20
|
|
6
6
|
// API version 6
|
|
7
7
|
|
|
8
8
|
declare namespace runtime {
|
package/dist/global.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Factorio API reference https://lua-api.factorio.com/latest/index.html
|
|
3
3
|
// Generated from JSON source https://lua-api.factorio.com/latest/runtime-api.json
|
|
4
4
|
// Definition source https://github.com/sguest/factorio-types
|
|
5
|
-
// Factorio version 2.1.
|
|
5
|
+
// Factorio version 2.1.20
|
|
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.1.
|
|
5
|
+
// Factorio version 2.1.20
|
|
6
6
|
// API version 6
|
|
7
7
|
|
|
8
8
|
declare namespace prototype {
|
|
@@ -5081,9 +5081,9 @@ interface ItemPrototype extends Prototype {
|
|
|
5081
5081
|
*/
|
|
5082
5082
|
fuel_acceleration_multiplier_quality_bonus?: double;
|
|
5083
5083
|
/**
|
|
5084
|
-
*
|
|
5084
|
+
* Mandatory with at least one fuel category when a nonzero fuel_value is defined.
|
|
5085
5085
|
*/
|
|
5086
|
-
|
|
5086
|
+
fuel_categories?: FuelCategoryID[];
|
|
5087
5087
|
fuel_emissions_multiplier?: double;
|
|
5088
5088
|
/**
|
|
5089
5089
|
* Colors the glow of the burner energy source when this fuel is burned. Can also be used to color the glow of reactors burning the fuel, see {@link ReactorPrototype::use_fuel_glow_color | prototype:ReactorPrototype::use_fuel_glow_color}.
|
|
@@ -9186,6 +9186,8 @@ interface SpaceConnectionPrototype extends Prototype {
|
|
|
9186
9186
|
* Cannot be 0.
|
|
9187
9187
|
*/
|
|
9188
9188
|
length?: uint32;
|
|
9189
|
+
origin?: MapPosition;
|
|
9190
|
+
shape?: 'arc' | 'line';
|
|
9189
9191
|
to: SpaceLocationID;
|
|
9190
9192
|
}
|
|
9191
9193
|
/**
|
|
@@ -9246,6 +9248,7 @@ interface SpaceLocationPrototype extends Prototype {
|
|
|
9246
9248
|
* Angle in relation to the sun.
|
|
9247
9249
|
*/
|
|
9248
9250
|
orientation: RealOrientation;
|
|
9251
|
+
origin?: MapPosition;
|
|
9249
9252
|
/**
|
|
9250
9253
|
* The orientation where parked space platforms will be drawn.
|
|
9251
9254
|
*/
|
|
@@ -10023,6 +10026,8 @@ interface TechnologyPrototype extends Prototype {
|
|
|
10023
10026
|
max_level?: uint32 | 'infinite';
|
|
10024
10027
|
/**
|
|
10025
10028
|
* If this name ends with `-<number>`, that number is ignored for localization purposes. E.g. if the name is `technology-3`, the game looks for the `technology-name.technology` localization. The technology tree will also show the number on the technology icon.
|
|
10029
|
+
*
|
|
10030
|
+
* The number is considered the level of the technology. There can't be technologies with noncontiguous levels, e.g. `technology-1` and `technology-3` without `technology-2` will cause a startup error.
|
|
10026
10031
|
*/
|
|
10027
10032
|
name: string;
|
|
10028
10033
|
/**
|
|
@@ -11271,9 +11276,6 @@ interface UtilityConstants extends PrototypeBase {
|
|
|
11271
11276
|
water_collision_mask: TileCollisionMaskConnector;
|
|
11272
11277
|
weapons_in_simulation_volume_modifier: float;
|
|
11273
11278
|
zero_count_value_tint: Color;
|
|
11274
|
-
zoom_to_world_can_use_nightvision: boolean;
|
|
11275
|
-
zoom_to_world_daytime_color_lookup: DaytimeColorLookupTable;
|
|
11276
|
-
zoom_to_world_effect_strength: float;
|
|
11277
11279
|
}
|
|
11278
11280
|
/**
|
|
11279
11281
|
* Sounds used by the game that are not specific to certain prototypes.
|
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.1.
|
|
5
|
+
// Factorio version 2.1.20
|
|
6
6
|
// API version 6
|
|
7
7
|
|
|
8
8
|
declare namespace prototype {
|
|
@@ -3782,7 +3782,7 @@ color_lookup = {{1, "identity"}}
|
|
|
3782
3782
|
color_lookup = {{0.5, "__core__/graphics/color_luts/nightvision.png"}}
|
|
3783
3783
|
```
|
|
3784
3784
|
* @example ```
|
|
3785
|
-
|
|
3785
|
+
daytime_color_lookup =
|
|
3786
3786
|
{
|
|
3787
3787
|
{0.25, "identity"},
|
|
3788
3788
|
{0.45, "__core__/graphics/color_luts/night.png"},
|
|
@@ -9787,6 +9787,16 @@ interface Settings {
|
|
|
9787
9787
|
*/
|
|
9788
9788
|
startup: Record<string, ModSetting>;
|
|
9789
9789
|
}
|
|
9790
|
+
/**
|
|
9791
|
+
* @example ```
|
|
9792
|
+
-- What a recipe's results would look like for a probability of 0.3 to return iron and 0.7 to return copper
|
|
9793
|
+
-- but always exactly 1 item, never no item or both items
|
|
9794
|
+
{
|
|
9795
|
+
{type = "item", name = "iron-plate", amount = 1, shared_probability = {min = 0, max = 0.3}},
|
|
9796
|
+
{type = "item", name = "copper-plate", amount = 1, shared_probability = {min = 0.3, max = 1}},
|
|
9797
|
+
}
|
|
9798
|
+
```
|
|
9799
|
+
*/
|
|
9790
9800
|
interface SharedProbabilityDefinition {
|
|
9791
9801
|
/**
|
|
9792
9802
|
* Upper end of the range of shared roll values that will allow product to be given. Must be >= `min` and <= `1`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "factorio-types",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.69",
|
|
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.1.
|
|
26
|
+
"factorioVersion": "2.1.20",
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"lua-types": "^2.13.1"
|
|
29
29
|
},
|