factorio-types 1.2.42 → 1.2.44
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 +698 -71
- package/dist/concepts.d.ts +6160 -4178
- package/dist/datacollection.d.ts +1 -1
- package/dist/defines.d.ts +339 -266
- package/dist/events.d.ts +296 -24
- package/dist/global.d.ts +1 -1
- package/dist/prototypes.d.ts +45 -34
- package/dist/types.d.ts +25 -23
- package/package.json +2 -2
package/dist/types.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Factorio API reference https://lua-api.factorio.com/latest/index.html
|
|
3
3
|
// Generated from JSON source https://lua-api.factorio.com/latest/prototype-api.json
|
|
4
4
|
// Definition source https://github.com/sguest/factorio-types
|
|
5
|
-
// Factorio version 2.0.
|
|
5
|
+
// Factorio version 2.0.61
|
|
6
6
|
// API version 6
|
|
7
7
|
|
|
8
8
|
declare namespace prototype {
|
|
@@ -2027,7 +2027,7 @@ interface BonusGuiOrdering {
|
|
|
2027
2027
|
}
|
|
2028
2028
|
interface BoolModifier extends BaseModifier {
|
|
2029
2029
|
/**
|
|
2030
|
-
* The
|
|
2030
|
+
* The state this modifier will be in upon researching.
|
|
2031
2031
|
*/
|
|
2032
2032
|
modifier: boolean;
|
|
2033
2033
|
}
|
|
@@ -2055,7 +2055,7 @@ interface BorderImageSet {
|
|
|
2055
2055
|
*
|
|
2056
2056
|
* BoundingBoxes are usually specified with the short-hand notation of passing an array of exactly 2 or 3 items.
|
|
2057
2057
|
*
|
|
2058
|
-
* The first tuple item is left_top, the second tuple item is right_bottom.
|
|
2058
|
+
* The first tuple item is left_top, the second tuple item is right_bottom. The third tuple item is a {@link float | prototype:float} that represents the orientation.
|
|
2059
2059
|
*
|
|
2060
2060
|
* Positive x goes towards east, positive y goes towards south. This means that the upper-left point is the least dimension in x and y, and lower-right is the greatest.
|
|
2061
2061
|
* @example ```
|
|
@@ -2068,9 +2068,6 @@ interface BorderImageSet {
|
|
|
2068
2068
|
*/
|
|
2069
2069
|
type BoundingBox = {
|
|
2070
2070
|
left_top: MapPosition;
|
|
2071
|
-
/**
|
|
2072
|
-
* Unused.
|
|
2073
|
-
*/
|
|
2074
2071
|
orientation?: RealOrientation;
|
|
2075
2072
|
right_bottom: MapPosition;
|
|
2076
2073
|
} | [
|
|
@@ -3441,7 +3438,7 @@ type CursorBoxType = /**
|
|
|
3441
3438
|
interface CustomTooltipField {
|
|
3442
3439
|
name: LocalisedString;
|
|
3443
3440
|
/**
|
|
3444
|
-
* Ordering within all description items (modded and
|
|
3441
|
+
* Ordering within all description items (modded and un-modded). Items with smaller order values are shown above items with larger values.
|
|
3445
3442
|
*/
|
|
3446
3443
|
order?: uint8;
|
|
3447
3444
|
quality_header?: string;
|
|
@@ -3792,7 +3789,7 @@ interface Effect {
|
|
|
3792
3789
|
*/
|
|
3793
3790
|
productivity?: EffectValue;
|
|
3794
3791
|
/**
|
|
3795
|
-
* Adds a bonus chance to increase a product's quality. The minimum possible sum is 0%.
|
|
3792
|
+
* Adds a bonus chance to increase a product's quality. The minimum possible sum is 0%. The quality effect is is multiplied by {@link QualityPrototype::next_probability | prototype:QualityPrototype::next_probability}. For example, if a module's quality effect is 0.2 and the current quality's next_probability is 0.1, then the chance to get the next quality item is 2%.
|
|
3796
3793
|
*/
|
|
3797
3794
|
quality?: EffectValue;
|
|
3798
3795
|
/**
|
|
@@ -3869,12 +3866,12 @@ type EffectTypeLimitation = (/**
|
|
|
3869
3866
|
/**
|
|
3870
3867
|
* Precision is ignored beyond two decimals - `0.567` results in `0.56` and means 56% etc. Values can range from `-327.68` to `327.67`. Numbers outside of this range will wrap around.
|
|
3871
3868
|
*
|
|
3872
|
-
* Quality values are
|
|
3869
|
+
* Quality values are multiplied by {@link QualityPrototype::next_probability | prototype:QualityPrototype::next_probability}. For example, if a module's quality effect is 0.2 and the current quality's next_probability is 0.1, then the chance to get the next quality item is 2%.
|
|
3873
3870
|
* @example ```
|
|
3874
3871
|
{speed = 0.07} -- 7% bonus
|
|
3875
3872
|
```
|
|
3876
3873
|
* @example ```
|
|
3877
|
-
{quality = 0.25} -- 2.5% bonus
|
|
3874
|
+
{quality = 0.25} -- multiplied by quality normal next_probability = 0.1 -> 2.5% bonus
|
|
3878
3875
|
```
|
|
3879
3876
|
*/
|
|
3880
3877
|
type EffectValue = float;
|
|
@@ -8425,15 +8422,11 @@ interface RotateEntityTipTrigger extends CountBasedTipTrigger {
|
|
|
8425
8422
|
}
|
|
8426
8423
|
interface RotatedAnimation extends AnimationParameters {
|
|
8427
8424
|
/**
|
|
8425
|
+
* Used to fix the inconsistency of direction of the entity in 3d when rendered and direction on the screen (where the 45 degree angle for projection is used).
|
|
8426
|
+
*
|
|
8428
8427
|
* Only loaded if `layers` is not defined.
|
|
8429
8428
|
*/
|
|
8430
8429
|
apply_projection?: boolean;
|
|
8431
|
-
/**
|
|
8432
|
-
* Only loaded if `layers` is not defined.
|
|
8433
|
-
*
|
|
8434
|
-
* If `true`, `direction_count` must be greater than `1`.
|
|
8435
|
-
*/
|
|
8436
|
-
axially_symmetrical?: boolean;
|
|
8437
8430
|
/**
|
|
8438
8431
|
* Only loaded if `layers` is not defined.
|
|
8439
8432
|
*/
|
|
@@ -8558,12 +8551,6 @@ interface RotatedSprite extends SpriteParameters {
|
|
|
8558
8551
|
* Used to fix the inconsistency of direction of the entity in 3d when rendered and direction on the screen (where the 45 degree angle for projection is used).
|
|
8559
8552
|
*/
|
|
8560
8553
|
apply_projection?: boolean;
|
|
8561
|
-
/**
|
|
8562
|
-
* Only loaded if `layers` is not defined.
|
|
8563
|
-
*
|
|
8564
|
-
* When `true`, the same picture is used for left/right direction, just flipped, which can save half of the space required, but is not usable once the picture contains shadows, etc.
|
|
8565
|
-
*/
|
|
8566
|
-
axially_symmetrical?: boolean;
|
|
8567
8554
|
/**
|
|
8568
8555
|
* Only loaded if `layers` is not defined.
|
|
8569
8556
|
*/
|
|
@@ -8708,7 +8695,7 @@ interface SegmentEngineSpecification {
|
|
|
8708
8695
|
segments: SegmentSpecification[];
|
|
8709
8696
|
}
|
|
8710
8697
|
/**
|
|
8711
|
-
* A container for
|
|
8698
|
+
* A container for a single reference to a {@link SegmentPrototype | prototype:SegmentPrototype} within a {@link SegmentEngineSpecification | prototype:SegmentEngineSpecification}.
|
|
8712
8699
|
*/
|
|
8713
8700
|
interface SegmentSpecification {
|
|
8714
8701
|
/**
|
|
@@ -9516,6 +9503,11 @@ interface SpiderLegPart {
|
|
|
9516
9503
|
* Used by {@link SpiderEngineSpecification | prototype:SpiderEngineSpecification} for {@link SpiderVehiclePrototype | prototype:SpiderVehiclePrototype}.
|
|
9517
9504
|
*/
|
|
9518
9505
|
interface SpiderLegSpecification {
|
|
9506
|
+
/**
|
|
9507
|
+
* The unprojected offset from the center of the spider's non-elevated torso to the position where the leg touches the ground when the spider is facing due north.
|
|
9508
|
+
*
|
|
9509
|
+
* This value rotates with the spider's orientation, which is rounded to match either the spider torso's {@link SpiderTorsoGraphicsSet::base_animation | prototype:SpiderTorsoGraphicsSet::base_animation} directions or if not base sprite is defined, its {@link SpiderTorsoGraphicsSet::animation | prototype:SpiderTorsoGraphicsSet::animation} directions if defined.
|
|
9510
|
+
*/
|
|
9519
9511
|
ground_position: Vector;
|
|
9520
9512
|
/**
|
|
9521
9513
|
* Name of a {@link SpiderLegPrototype | prototype:SpiderLegPrototype}.
|
|
@@ -9529,6 +9521,15 @@ interface SpiderLegSpecification {
|
|
|
9529
9521
|
* Triggers to activate whenever the leg hits the ground and the owning spider is actively attacking an entity. These effects will trigger after `leg_hit_the_ground_trigger` have triggered. For triggers, the source is the let entity and the target is the leg's current position. Certain effects may not raise as desired.
|
|
9530
9522
|
*/
|
|
9531
9523
|
leg_hit_the_ground_when_attacking_trigger?: TriggerEffect;
|
|
9524
|
+
/**
|
|
9525
|
+
* Projected offset from the center of the spider's elevated torso to the point where the leg connects to the body of the spider when the spider is facing due north.
|
|
9526
|
+
*
|
|
9527
|
+
* This offset should already be projected, meaning that it should apply the camera's 45 degree overhead angle, same as the spider's torso sprites should. If this mount position rotates with the spider's torso and the torso sprite(s) apply projection, the mount position will automatically account for the camera projection when rotating. See {@link RotatedAnimation::apply_projection | prototype:RotatedAnimation::apply_projection}.
|
|
9528
|
+
*
|
|
9529
|
+
* If the spider's torso sprites do not apply projection, then this mount_position should not apply projection either.
|
|
9530
|
+
*
|
|
9531
|
+
* This value rotates with the spider's orientation, which is rounded to match either the spider torso's {@link SpiderTorsoGraphicsSet::base_animation | prototype:SpiderTorsoGraphicsSet::base_animation} directions or if not base sprite is defined, its {@link SpiderTorsoGraphicsSet::animation | prototype:SpiderTorsoGraphicsSet::animation} directions if defined.
|
|
9532
|
+
*/
|
|
9532
9533
|
mount_position: Vector;
|
|
9533
9534
|
/**
|
|
9534
9535
|
* The walking group this leg belongs to. Legs in the same walking group move or stay still at the same time, according to the engine that drives them. Walking groups must start at 1 and increment upward without skipping any numbers. If all legs are part of the same walking_group, they will all move simultaneously.
|
|
@@ -11468,6 +11469,7 @@ interface TrainVisualizationConstants {
|
|
|
11468
11469
|
joint_distance: float;
|
|
11469
11470
|
last_box_color: Color;
|
|
11470
11471
|
not_last_box_color: Color;
|
|
11472
|
+
reverse_box_color: Color;
|
|
11471
11473
|
stock_number_scale: float;
|
|
11472
11474
|
}
|
|
11473
11475
|
interface TransitionApplication {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "factorio-types",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.44",
|
|
4
4
|
"description": "Typescript declarations for the Factorio mod API",
|
|
5
5
|
"main": "index.d.ts",
|
|
6
6
|
"repository": "https://github.com/sguest/factorio-types.git",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"src/**/*.d.ts",
|
|
24
24
|
"dist/**/*.d.ts"
|
|
25
25
|
],
|
|
26
|
-
"factorioVersion": "2.0.
|
|
26
|
+
"factorioVersion": "2.0.61",
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"lua-types": "^2.13.1"
|
|
29
29
|
},
|