typed-factorio 0.19.0 → 0.20.0
Sign up to get free protection for your applications and to get access to all the features.
- package/Changelog.md +14 -8
- package/README.md +19 -14
- package/custom-index-template.d.ts +22 -0
- package/generated/classes.d.ts +241 -220
- package/generated/concepts.d.ts +9 -6
- package/generated/events.d.ts +137 -139
- package/generated/index-types.d.ts +49 -0
- package/package.json +2 -5
- package/runtime/index.d.ts +9 -1
- package/runtime/pairs.d.ts +4 -8
- package/strict-index-types.d.ts +3 -0
- package/generated/index.d.ts +0 -9
package/generated/concepts.d.ts
CHANGED
@@ -218,7 +218,8 @@ interface OldTileAndPosition {
|
|
218
218
|
*
|
219
219
|
* {@link https://lua-api.factorio.com/latest/Concepts.html#Tags View documentation}
|
220
220
|
* @example
|
221
|
-
|
221
|
+
*
|
222
|
+
* ```
|
222
223
|
* {a = 1, b = true, c = "three", d = {e = "f"}}
|
223
224
|
* ```
|
224
225
|
*/
|
@@ -257,7 +258,8 @@ interface SmokeSource {
|
|
257
258
|
*
|
258
259
|
* {@link https://lua-api.factorio.com/latest/Concepts.html#Vector View documentation}
|
259
260
|
* @example
|
260
|
-
|
261
|
+
*
|
262
|
+
* ```
|
261
263
|
* right = {1.0, 0.0}
|
262
264
|
* ```
|
263
265
|
*/
|
@@ -344,7 +346,8 @@ type ColorArray = readonly [r?: float, g?: float, b?: float, a?: float]
|
|
344
346
|
*
|
345
347
|
* {@link https://lua-api.factorio.com/latest/Concepts.html#Color View documentation}
|
346
348
|
* @example
|
347
|
-
|
349
|
+
*
|
350
|
+
* ```
|
348
351
|
* red1 = {r = 0.5, g = 0, b = 0, a = 0.5} -- Half-opacity red
|
349
352
|
* red2 = {r = 0.5, a = 0.5} -- Same color as red1
|
350
353
|
* black = {} -- All channels omitted: black
|
@@ -2475,7 +2478,7 @@ type TechnologyIdentification = string | LuaTechnology | LuaTechnologyPrototype
|
|
2475
2478
|
*
|
2476
2479
|
* {@link https://lua-api.factorio.com/latest/Concepts.html#SurfaceIdentification View documentation}
|
2477
2480
|
*/
|
2478
|
-
type SurfaceIdentification =
|
2481
|
+
type SurfaceIdentification = SurfaceIndex | string | LuaSurface
|
2479
2482
|
|
2480
2483
|
/**
|
2481
2484
|
* - uint: The player index.
|
@@ -2486,7 +2489,7 @@ type SurfaceIdentification = uint | string | LuaSurface
|
|
2486
2489
|
*
|
2487
2490
|
* {@link https://lua-api.factorio.com/latest/Concepts.html#PlayerIdentification View documentation}
|
2488
2491
|
*/
|
2489
|
-
type PlayerIdentification =
|
2492
|
+
type PlayerIdentification = PlayerIndex | string | LuaPlayer
|
2490
2493
|
|
2491
2494
|
type ItemStackIdentification = SimpleItemStack | LuaItemStack
|
2492
2495
|
|
@@ -3331,7 +3334,7 @@ interface CustomCommandData {
|
|
3331
3334
|
/**
|
3332
3335
|
* The player who issued the command, or `nil` if it was issued from the server console.
|
3333
3336
|
*/
|
3334
|
-
readonly player_index?:
|
3337
|
+
readonly player_index?: PlayerIndex
|
3335
3338
|
/**
|
3336
3339
|
* The parameter passed after the command, if there is one.
|
3337
3340
|
*/
|