typed-factorio 1.3.1 → 1.3.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -152,8 +152,11 @@ interface LuaArithmeticCombinatorControlBehavior extends LuaCombinatorControlBeh
152
152
  /**
153
153
  * This arithmetic combinator's parameters.
154
154
  *
155
+ * **Note**
156
+ *
157
+ * Writing `nil` clears the combinator's parameters.
158
+ *
155
159
  * {@link https://lua-api.factorio.com/latest/LuaArithmeticCombinatorControlBehavior.html#LuaArithmeticCombinatorControlBehavior.parameters View documentation}
156
- * @remarks Writing `nil` clears the combinator's parameters.
157
160
  */
158
161
  parameters: ArithmeticCombinatorParameters
159
162
  /**
@@ -224,9 +227,12 @@ interface LuaBootstrap {
224
227
  /**
225
228
  * Register a function to be run on mod initialization. This is only called when a new save game is created or when a save file is loaded that previously didn't contain the mod. During it, the mod gets the chance to set up initial values that it will use for its lifetime. It has full access to {@link LuaGameScript} and the {@linkplain https://lua-api.factorio.com/latest/Global.html global} table and can change anything about them that it deems appropriate. No other events will be raised for the mod until it has finished this step.
226
229
  *
230
+ * **Note**
231
+ *
232
+ * For more context, refer to the {@linkplain https://lua-api.factorio.com/latest/Data-Lifecycle.html Data Lifecycle} page.
233
+ *
227
234
  * {@link https://lua-api.factorio.com/latest/LuaBootstrap.html#LuaBootstrap.on_init View documentation}
228
235
  * @param f The handler for this event. Passing `nil` will unregister it.
229
- * @remarks For more context, refer to the {@linkplain https://lua-api.factorio.com/latest/Data-Lifecycle.html Data Lifecycle} page.
230
236
  * @example Initialize a `players` table in `global` for later use.
231
237
  *
232
238
  * ```
@@ -246,17 +252,23 @@ interface LuaBootstrap {
246
252
  *
247
253
  * For all other purposes, {@link LuaBootstrap#on_init LuaBootstrap::on_init}, {@link LuaBootstrap#on_configuration_changed LuaBootstrap::on_configuration_changed} or {@linkplain https://lua-api.factorio.com/latest/Migrations.html migrations} should be used instead.
248
254
  *
255
+ * **Note**
256
+ *
257
+ * For more context, refer to the {@linkplain https://lua-api.factorio.com/latest/Data-Lifecycle.html Data Lifecycle} page.
258
+ *
249
259
  * {@link https://lua-api.factorio.com/latest/LuaBootstrap.html#LuaBootstrap.on_load View documentation}
250
260
  * @param f The handler for this event. Passing `nil` will unregister it.
251
- * @remarks For more context, refer to the {@linkplain https://lua-api.factorio.com/latest/Data-Lifecycle.html Data Lifecycle} page.
252
261
  */
253
262
  on_load(f: (() => void) | undefined): void
254
263
  /**
255
264
  * Register a function to be run when mod configuration changes. This is called when the major game version or any mod version changed, when any mod was added or removed, when a startup setting has changed, or when any prototypes have been added or removed. It allows the mod to make any changes it deems appropriate to both the data structures in its {@linkplain https://lua-api.factorio.com/latest/Global.html global} table or to the game state through {@link LuaGameScript}.
256
265
  *
266
+ * **Note**
267
+ *
268
+ * For more context, refer to the {@linkplain https://lua-api.factorio.com/latest/Data-Lifecycle.html Data Lifecycle} page.
269
+ *
257
270
  * {@link https://lua-api.factorio.com/latest/LuaBootstrap.html#LuaBootstrap.on_configuration_changed View documentation}
258
271
  * @param f The handler for this event. Passing `nil` will unregister it.
259
- * @remarks For more context, refer to the {@linkplain https://lua-api.factorio.com/latest/Data-Lifecycle.html Data Lifecycle} page.
260
272
  */
261
273
  on_configuration_changed(f: ((param1: ConfigurationChangedData) => void) | undefined): void
262
274
  /**
@@ -298,10 +310,13 @@ interface LuaBootstrap {
298
310
  /**
299
311
  * Registers an entity so that after it's destroyed, {@link OnEntityDestroyedEvent on_entity_destroyed} is called. Once an entity is registered, it stays registered until it is actually destroyed, even through save/load cycles. The registration is global across all mods, meaning once one mod registers an entity, all mods listening to {@link OnEntityDestroyedEvent on_entity_destroyed} will receive the event when it is destroyed. Registering the same entity multiple times will still only fire the destruction event once, and will return the same registration number.
300
312
  *
313
+ * **Note**
314
+ *
315
+ * Depending on when a given entity is destroyed, {@link OnEntityDestroyedEvent on_entity_destroyed} will either be fired at the end of the current tick or at the end of the next tick.
316
+ *
301
317
  * {@link https://lua-api.factorio.com/latest/LuaBootstrap.html#LuaBootstrap.register_on_entity_destroyed View documentation}
302
318
  * @param entity The entity to register.
303
319
  * @returns The registration number. It is used to identify the entity in the {@link OnEntityDestroyedEvent on_entity_destroyed} event.
304
- * @remarks Depending on when a given entity is destroyed, {@link OnEntityDestroyedEvent on_entity_destroyed} will either be fired at the end of the current tick or at the end of the next tick.
305
320
  */
306
321
  register_on_entity_destroyed(entity: LuaEntity): RegistrationNumber
307
322
  /**
@@ -633,22 +648,31 @@ interface LuaBurner {
633
648
  /**
634
649
  * The amount of energy left in the currently-burning fuel item.
635
650
  *
651
+ * **Note**
652
+ *
653
+ * Writing to this will silently do nothing if there's no {@link LuaBurner#currently_burning LuaBurner::currently_burning} set.
654
+ *
636
655
  * {@link https://lua-api.factorio.com/latest/LuaBurner.html#LuaBurner.remaining_burning_fuel View documentation}
637
- * @remarks Writing to this will silently do nothing if there's no {@link LuaBurner#currently_burning LuaBurner::currently_burning} set.
638
656
  */
639
657
  remaining_burning_fuel: double
640
658
  /**
641
659
  * The currently burning item, or `nil` if no item is burning.
642
660
  *
661
+ * **Note**
662
+ *
663
+ * Writing to this automatically handles correcting {@link LuaBurner#remaining_burning_fuel LuaBurner::remaining_burning_fuel}.
664
+ *
643
665
  * {@link https://lua-api.factorio.com/latest/LuaBurner.html#LuaBurner.currently_burning View documentation}
644
- * @remarks Writing to this automatically handles correcting {@link LuaBurner#remaining_burning_fuel LuaBurner::remaining_burning_fuel}.
645
666
  */
646
667
  currently_burning: LuaItemPrototype | undefined
647
668
  /**
648
669
  * The fuel categories this burner uses.
649
670
  *
671
+ * **Note**
672
+ *
673
+ * The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
674
+ *
650
675
  * {@link https://lua-api.factorio.com/latest/LuaBurner.html#LuaBurner.fuel_categories View documentation}
651
- * @remarks The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
652
676
  */
653
677
  readonly fuel_categories: Record<string, boolean>
654
678
  /**
@@ -700,10 +724,11 @@ interface LuaBurnerPrototype {
700
724
  readonly color: ColorTable
701
725
  }
702
726
  /**
727
+ * **Note**
703
728
  *
729
+ * The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
704
730
  *
705
731
  * {@link https://lua-api.factorio.com/latest/LuaBurnerPrototype.html#LuaBurnerPrototype.fuel_categories View documentation}
706
- * @remarks The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
707
732
  */
708
733
  readonly fuel_categories: Record<string, boolean>
709
734
  /**
@@ -854,11 +879,14 @@ interface LuaCommandProcessor {
854
879
  /**
855
880
  * Add a custom console command.
856
881
  *
882
+ * **Note**
883
+ *
884
+ * Trying to add a command with the `name` of a game command or the name of a custom command that is already in use will result in an error.
885
+ *
857
886
  * {@link https://lua-api.factorio.com/latest/LuaCommandProcessor.html#LuaCommandProcessor.add_command View documentation}
858
887
  * @param name The desired name of the command (case sensitive).
859
888
  * @param help The localised help message. It will be shown to players using the `/help` command.
860
889
  * @param _function The function that will be called when this command is invoked.
861
- * @remarks Trying to add a command with the `name` of a game command or the name of a custom command that is already in use will result in an error.
862
890
  * @example This will register a custom event called `print_tick` that prints the current tick to either the player issuing the command or to everyone on the server, depending on the command parameter. It shows the usage of the table that gets passed to any function handling a custom command. This specific example makes use of the `tick` and the optional `player_index` and `parameter` fields. The user is supposed to either call it without any parameter (`"/print_tick"`) or with the `"me"` parameter (`"/print_tick me"`).
863
891
  *
864
892
  * ```
@@ -920,8 +948,11 @@ interface LuaConstantCombinatorControlBehavior extends LuaControlBehavior {
920
948
  /**
921
949
  * This constant combinator's parameters, or `nil` if the {@link LuaEntityPrototype#item_slot_count item_slot_count} of the combinator's prototype is `0`.
922
950
  *
951
+ * **Note**
952
+ *
953
+ * Writing `nil` clears the combinator's parameters.
954
+ *
923
955
  * {@link https://lua-api.factorio.com/latest/LuaConstantCombinatorControlBehavior.html#LuaConstantCombinatorControlBehavior.parameters View documentation}
924
- * @remarks Writing `nil` clears the combinator's parameters.
925
956
  */
926
957
  parameters: ConstantCombinatorParameters[] | undefined
927
958
  /**
@@ -1047,9 +1078,12 @@ interface LuaControl {
1047
1078
  /**
1048
1079
  * Get an inventory belonging to this entity. This can be either the "main" inventory or some auxiliary one, like the module slots or logistic trash slots.
1049
1080
  *
1081
+ * **Note**
1082
+ *
1083
+ * A given {@link defines.inventory} is only meaningful for the corresponding LuaObject type. EG: get_inventory(defines.inventory.character_main) is only meaningful if 'this' is a player character. You may get a value back but if the type of 'this' isn't the type referred to by the {@link defines.inventory} it's almost guaranteed to not be the inventory asked for.
1084
+ *
1050
1085
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.get_inventory View documentation}
1051
1086
  * @returns The inventory or `nil` if none with the given index was found.
1052
- * @remarks A given {@link defines.inventory} is only meaningful for the corresponding LuaObject type. EG: get_inventory(defines.inventory.character_main) is only meaningful if 'this' is a player character. You may get a value back but if the type of 'this' isn't the type referred to by the {@link defines.inventory} it's almost guaranteed to not be the inventory asked for.
1053
1087
  */
1054
1088
  get_inventory(inventory: defines.inventory): LuaInventory | undefined
1055
1089
  /**
@@ -1128,14 +1162,17 @@ interface LuaControl {
1128
1162
  * **Raised events:**
1129
1163
  * - {@link OnPlayerChangedPositionEvent on_player_changed_position}? _instantly_ Raised if the teleported entity is a player character.
1130
1164
  *
1165
+ * **Notes**
1166
+ * - Some entities may not be teleported. For instance, transport belts won't allow teleportation and this method will always return `false` when used on any such entity.
1167
+ * - You can also pass 1 or 2 numbers as the parameters and they will be used as relative teleport coordinates `'teleport(0, 1)'` to move the entity 1 tile positive y. `'teleport(4)'` to move the entity 4 tiles to the positive x.
1131
1168
  *
1132
1169
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.teleport View documentation}
1133
1170
  * @param position Where to teleport to.
1134
1171
  * @param surface Surface to teleport to. If not given, will teleport to the entity's current surface. Only players, cars, and spidertrons can be teleported cross-surface.
1135
1172
  * @returns `true` if the entity was successfully teleported.
1136
- * @remarks Some entities may not be teleported. For instance, transport belts won't allow teleportation and this method will always return `false` when used on any such entity.<br>You can also pass 1 or 2 numbers as the parameters and they will be used as relative teleport coordinates `'teleport(0, 1)'` to move the entity 1 tile positive y. `'teleport(4)'` to move the entity 4 tiles to the positive x.
1137
1173
  */
1138
1174
  teleport(position: MapPosition, surface?: SurfaceIdentification): boolean
1175
+ teleport(x: number, y?: number): boolean
1139
1176
  /**
1140
1177
  * Select an entity, as if by hovering the mouse above it.
1141
1178
  *
@@ -1275,12 +1312,14 @@ interface LuaControl {
1275
1312
  * **Raised events:**
1276
1313
  * - {@link OnEntityLogisticSlotChangedEvent on_entity_logistic_slot_changed}? _instantly_ Raised if setting of logistic slot was successful.
1277
1314
  *
1315
+ * **Note**
1316
+ *
1317
+ * This will silently fail if personal logistics are not researched yet.
1278
1318
  *
1279
1319
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.set_personal_logistic_slot View documentation}
1280
1320
  * @param slot_index The slot to set.
1281
1321
  * @param value The logistic request parameters.
1282
1322
  * @returns Whether the slot was set successfully. `false` if personal logistics are not researched yet.
1283
- * @remarks This will silently fail if personal logistics are not researched yet.
1284
1323
  */
1285
1324
  set_personal_logistic_slot(slot_index: uint, value: LogisticParameters): boolean
1286
1325
  /**
@@ -1316,20 +1355,24 @@ interface LuaControl {
1316
1355
  * **Raised events:**
1317
1356
  * - {@link OnEntityLogisticSlotChangedEvent on_entity_logistic_slot_changed}? _instantly_ Raised if clearing of logistic slot was successful.
1318
1357
  *
1358
+ * **Note**
1359
+ *
1360
+ * This will silently fail if personal logistics are not researched yet.
1319
1361
  *
1320
1362
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.clear_personal_logistic_slot View documentation}
1321
1363
  * @param slot_index The slot to clear.
1322
- * @remarks This will silently fail if personal logistics are not researched yet.
1323
1364
  */
1324
1365
  clear_personal_logistic_slot(slot_index: uint): void
1325
1366
  /**
1326
1367
  * **Raised events:**
1327
1368
  * - {@link OnEntityLogisticSlotChangedEvent on_entity_logistic_slot_changed}? _instantly_ Raised if clearing of logistic slot was successful.
1328
1369
  *
1370
+ * **Note**
1371
+ *
1372
+ * This will silently fail if the vehicle does not use logistics.
1329
1373
  *
1330
1374
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.clear_vehicle_logistic_slot View documentation}
1331
1375
  * @param slot_index The slot to clear.
1332
- * @remarks This will silently fail if the vehicle does not use logistics.
1333
1376
  */
1334
1377
  clear_vehicle_logistic_slot(slot_index: uint): void
1335
1378
  /**
@@ -1396,9 +1439,11 @@ interface LuaControl {
1396
1439
  * **Raised events:**
1397
1440
  * - {@link OnGuiOpenedEvent on_gui_opened}? _instantly_ Raised when writing a valid GUI target to this attribute.
1398
1441
  *
1442
+ * **Note**
1443
+ *
1444
+ * Write supports any of the types. Read will return the `entity`, `equipment`, `equipment-grid`, `player`, `element` or `nil`.
1399
1445
  *
1400
1446
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.opened View documentation}
1401
- * @remarks Write supports any of the types. Read will return the `entity`, `equipment`, `equipment-grid`, `player`, `element` or `nil`.
1402
1447
  */
1403
1448
  set opened(
1404
1449
  value:
@@ -1453,8 +1498,11 @@ interface LuaControl {
1453
1498
  /**
1454
1499
  * Current mining state.
1455
1500
  *
1501
+ * **Note**
1502
+ *
1503
+ * When the player isn't mining tiles the player will mine what ever entity is currently selected. See {@link LuaControl#selected LuaControl::selected} and {@link LuaControl#update_selected_entity LuaControl::update_selected_entity}.
1504
+ *
1456
1505
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.mining_state View documentation}
1457
- * @remarks When the player isn't mining tiles the player will mine what ever entity is currently selected. See {@link LuaControl#selected LuaControl::selected} and {@link LuaControl#update_selected_entity LuaControl::update_selected_entity}.
1458
1506
  */
1459
1507
  get mining_state(): {
1460
1508
  /**
@@ -1546,8 +1594,11 @@ interface LuaControl {
1546
1594
  /**
1547
1595
  * The ghost prototype in the player's cursor.
1548
1596
  *
1597
+ * **Notes**
1598
+ * - When read, it will be a {@link LuaItemPrototype}.
1599
+ * - Items in the cursor stack will take priority over the cursor ghost.
1600
+ *
1549
1601
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.cursor_ghost View documentation}
1550
- * @remarks When read, it will be a {@link LuaItemPrototype}.<br>Items in the cursor stack will take priority over the cursor ghost.
1551
1602
  */
1552
1603
  get cursor_ghost(): LuaItemPrototype
1553
1604
  set cursor_ghost(value: ItemPrototypeIdentification)
@@ -1570,8 +1621,11 @@ interface LuaControl {
1570
1621
  /**
1571
1622
  * The current combat robots following the character
1572
1623
  *
1624
+ * **Note**
1625
+ *
1626
+ * When called on a {@link LuaPlayer}, it must be associated with a character(see {@link LuaPlayer#character LuaPlayer::character}).
1627
+ *
1573
1628
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.following_robots View documentation}
1574
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character(see {@link LuaPlayer#character LuaPlayer::character}).
1575
1629
  */
1576
1630
  readonly following_robots: LuaEntity[]
1577
1631
  /**
@@ -1581,101 +1635,117 @@ interface LuaControl {
1581
1635
  */
1582
1636
  cheat_mode: boolean
1583
1637
  /**
1638
+ * **Note**
1584
1639
  *
1640
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1585
1641
  *
1586
1642
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_crafting_speed_modifier View documentation}
1587
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1588
1643
  */
1589
1644
  character_crafting_speed_modifier: double
1590
1645
  /**
1646
+ * **Note**
1591
1647
  *
1648
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1592
1649
  *
1593
1650
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_mining_speed_modifier View documentation}
1594
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1595
1651
  */
1596
1652
  character_mining_speed_modifier: double
1597
1653
  /**
1654
+ * **Note**
1598
1655
  *
1656
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1599
1657
  *
1600
1658
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_additional_mining_categories View documentation}
1601
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1602
1659
  */
1603
1660
  character_additional_mining_categories: string[]
1604
1661
  /**
1605
1662
  * Modifies the running speed of this character by the given value as a percentage. Setting the running modifier to `0.5` makes the character run 50% faster. The minimum value of `-1` reduces the movement speed by 100%, resulting in a speed of `0`.
1606
1663
  *
1664
+ * **Note**
1665
+ *
1666
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1667
+ *
1607
1668
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_running_speed_modifier View documentation}
1608
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1609
1669
  */
1610
1670
  character_running_speed_modifier: double
1611
1671
  /**
1672
+ * **Note**
1612
1673
  *
1674
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1613
1675
  *
1614
1676
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_build_distance_bonus View documentation}
1615
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1616
1677
  */
1617
1678
  character_build_distance_bonus: uint
1618
1679
  /**
1680
+ * **Note**
1619
1681
  *
1682
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1620
1683
  *
1621
1684
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_item_drop_distance_bonus View documentation}
1622
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1623
1685
  */
1624
1686
  character_item_drop_distance_bonus: uint
1625
1687
  /**
1688
+ * **Note**
1626
1689
  *
1690
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1627
1691
  *
1628
1692
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_reach_distance_bonus View documentation}
1629
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1630
1693
  */
1631
1694
  character_reach_distance_bonus: uint
1632
1695
  /**
1696
+ * **Note**
1633
1697
  *
1698
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1634
1699
  *
1635
1700
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_resource_reach_distance_bonus View documentation}
1636
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1637
1701
  */
1638
1702
  character_resource_reach_distance_bonus: uint
1639
1703
  /**
1704
+ * **Note**
1640
1705
  *
1706
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1641
1707
  *
1642
1708
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_item_pickup_distance_bonus View documentation}
1643
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1644
1709
  */
1645
1710
  character_item_pickup_distance_bonus: uint
1646
1711
  /**
1712
+ * **Note**
1647
1713
  *
1714
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1648
1715
  *
1649
1716
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_loot_pickup_distance_bonus View documentation}
1650
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1651
1717
  */
1652
1718
  character_loot_pickup_distance_bonus: uint
1653
1719
  /**
1720
+ * **Note**
1654
1721
  *
1722
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1655
1723
  *
1656
1724
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_inventory_slots_bonus View documentation}
1657
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1658
1725
  */
1659
1726
  character_inventory_slots_bonus: uint
1660
1727
  /**
1728
+ * **Note**
1661
1729
  *
1730
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1662
1731
  *
1663
1732
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_trash_slot_count_bonus View documentation}
1664
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1665
1733
  */
1666
1734
  character_trash_slot_count_bonus: uint
1667
1735
  /**
1736
+ * **Note**
1668
1737
  *
1738
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1669
1739
  *
1670
1740
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_maximum_following_robot_count_bonus View documentation}
1671
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1672
1741
  */
1673
1742
  character_maximum_following_robot_count_bonus: uint
1674
1743
  /**
1744
+ * **Note**
1675
1745
  *
1746
+ * When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1676
1747
  *
1677
1748
  * {@link https://lua-api.factorio.com/latest/LuaControl.html#LuaControl.character_health_bonus View documentation}
1678
- * @remarks When called on a {@link LuaPlayer}, it must be associated with a character (see {@link LuaPlayer#character LuaPlayer::character}).
1679
1749
  */
1680
1750
  character_health_bonus: float
1681
1751
  /**
@@ -1755,9 +1825,12 @@ interface LuaControl {
1755
1825
  /**
1756
1826
  * The control behavior for an entity. Inserters have logistic network and circuit network behavior logic, lamps have circuit logic and so on. This is an abstract base class that concrete control behaviors inherit.
1757
1827
  *
1828
+ * **Note**
1829
+ *
1830
+ * An control reference becomes invalid once the control behavior is removed or the entity (see {@link LuaEntity}) it resides in is destroyed.
1831
+ *
1758
1832
  * {@link https://lua-api.factorio.com/latest/LuaControlBehavior.html View documentation}
1759
1833
  * @noSelf
1760
- * @remarks An control reference becomes invalid once the control behavior is removed or the entity (see {@link LuaEntity}) it resides in is destroyed.
1761
1834
  */
1762
1835
  interface LuaControlBehavior {
1763
1836
  /**
@@ -2065,8 +2138,11 @@ interface LuaDeciderCombinatorControlBehavior extends LuaCombinatorControlBehavi
2065
2138
  /**
2066
2139
  * This decider combinator's parameters.
2067
2140
  *
2141
+ * **Note**
2142
+ *
2143
+ * Writing `nil` clears the combinator's parameters.
2144
+ *
2068
2145
  * {@link https://lua-api.factorio.com/latest/LuaDeciderCombinatorControlBehavior.html#LuaDeciderCombinatorControlBehavior.parameters View documentation}
2069
- * @remarks Writing `nil` clears the combinator's parameters.
2070
2146
  */
2071
2147
  parameters: DeciderCombinatorParameters
2072
2148
  /**
@@ -2229,10 +2305,12 @@ interface LuaEntity extends LuaControl {
2229
2305
  * **Raised events:**
2230
2306
  * - {@link ScriptRaisedDestroyEvent script_raised_destroy}? _instantly_ Raised if the `raise_destroy` flag was set and the entity was successfully destroyed.
2231
2307
  *
2308
+ * **Note**
2309
+ *
2310
+ * Not all entities can be destroyed - things such as rails under trains cannot be destroyed until the train is moved or destroyed.
2232
2311
  *
2233
2312
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.destroy View documentation}
2234
2313
  * @returns Returns `false` if the entity was valid and destruction failed, `true` in all other cases.
2235
- * @remarks Not all entities can be destroyed - things such as rails under trains cannot be destroyed until the train is moved or destroyed.
2236
2314
  */
2237
2315
  destroy(params?: {
2238
2316
  /**
@@ -2292,10 +2370,13 @@ interface LuaEntity extends LuaControl {
2292
2370
  /**
2293
2371
  * Test whether this entity's prototype has a certain flag set.
2294
2372
  *
2373
+ * **Note**
2374
+ *
2375
+ * `entity.has_flag(f)` is a shortcut for `entity.prototype.has_flag(f)`.
2376
+ *
2295
2377
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.has_flag View documentation}
2296
2378
  * @param flag The flag to test. See {@link EntityPrototypeFlags} for a list of flags.
2297
2379
  * @returns `true` if this entity has the given flag set.
2298
- * @remarks `entity.has_flag(f)` is a shortcut for `entity.prototype.has_flag(f)`.
2299
2380
  */
2300
2381
  has_flag(flag: keyof EntityPrototypeFlags): boolean
2301
2382
  /**
@@ -2331,10 +2412,13 @@ interface LuaEntity extends LuaControl {
2331
2412
  *
2332
2413
  * _Can only be used if this is Market_
2333
2414
  *
2415
+ * **Note**
2416
+ *
2417
+ * The other offers are moved down to fill the gap created by removing the offer, which decrements the overall size of the offer array.
2418
+ *
2334
2419
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.remove_market_item View documentation}
2335
2420
  * @param offer Index of offer to remove.
2336
2421
  * @returns `true` if the offer was successfully removed; `false` when the given index was not valid.
2337
- * @remarks The other offers are moved down to fill the gap created by removing the offer, which decrements the overall size of the offer array.
2338
2422
  */
2339
2423
  remove_market_item(offer: uint): boolean
2340
2424
  /**
@@ -2454,28 +2538,37 @@ interface LuaEntity extends LuaControl {
2454
2538
  /**
2455
2539
  * Get a logistic requester slot.
2456
2540
  *
2541
+ * **Note**
2542
+ *
2543
+ * Useable only on entities that have requester slots.
2544
+ *
2457
2545
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_request_slot View documentation}
2458
2546
  * @param slot The slot index.
2459
2547
  * @returns Contents of the specified slot; `nil` if the given slot contains no request.
2460
- * @remarks Useable only on entities that have requester slots.
2461
2548
  */
2462
2549
  get_request_slot(slot: uint): SimpleItemStack | undefined
2463
2550
  /**
2464
2551
  * Set a logistic requester slot.
2465
2552
  *
2553
+ * **Note**
2554
+ *
2555
+ * Useable only on entities that have requester slots.
2556
+ *
2466
2557
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.set_request_slot View documentation}
2467
2558
  * @param request What to request.
2468
2559
  * @param slot The slot index.
2469
2560
  * @returns Whether the slot was set.
2470
- * @remarks Useable only on entities that have requester slots.
2471
2561
  */
2472
2562
  set_request_slot(request: ItemStackIdentification, slot: uint): boolean
2473
2563
  /**
2474
2564
  * Clear a logistic requester slot.
2475
2565
  *
2566
+ * **Note**
2567
+ *
2568
+ * Useable only on entities that have requester slots.
2569
+ *
2476
2570
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.clear_request_slot View documentation}
2477
2571
  * @param slot The slot index.
2478
- * @remarks Useable only on entities that have requester slots.
2479
2572
  */
2480
2573
  clear_request_slot(slot: uint): void
2481
2574
  /**
@@ -2625,11 +2718,14 @@ interface LuaEntity extends LuaControl {
2625
2718
  *
2626
2719
  * _Can only be used if this is Rail_
2627
2720
  *
2721
+ * **Note**
2722
+ *
2723
+ * A rail segment is a continuous section of rail with no branches, signals, nor train stops.
2724
+ *
2628
2725
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_rail_segment_entity View documentation}
2629
2726
  * @param direction The direction of travel relative to this rail.
2630
2727
  * @param in_else_out If true, gets the entity at the entrance of the rail segment, otherwise gets the entity at the exit of the rail segment.
2631
2728
  * @returns `nil` if the rail segment doesn't start/end with a signal nor a train stop.
2632
- * @remarks A rail segment is a continuous section of rail with no branches, signals, nor train stops.
2633
2729
  */
2634
2730
  get_rail_segment_entity(direction: defines.rail_direction, in_else_out: boolean): LuaEntity | undefined
2635
2731
  /**
@@ -2637,10 +2733,13 @@ interface LuaEntity extends LuaControl {
2637
2733
  *
2638
2734
  * _Can only be used if this is Rail_
2639
2735
  *
2736
+ * **Note**
2737
+ *
2738
+ * A rail segment is a continuous section of rail with no branches, signals, nor train stops.
2739
+ *
2640
2740
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_rail_segment_end View documentation}
2641
2741
  * @returns The rail entity.
2642
2742
  * @returns A rail direction pointing out of the rail segment from the end rail.
2643
- * @remarks A rail segment is a continuous section of rail with no branches, signals, nor train stops.
2644
2743
  */
2645
2744
  get_rail_segment_end(direction: defines.rail_direction): LuaMultiReturn<[LuaEntity, defines.rail_direction]>
2646
2745
  /**
@@ -2648,8 +2747,11 @@ interface LuaEntity extends LuaControl {
2648
2747
  *
2649
2748
  * _Can only be used if this is Rail_
2650
2749
  *
2750
+ * **Note**
2751
+ *
2752
+ * A rail segment is a continuous section of rail with no branches, signals, nor train stops.
2753
+ *
2651
2754
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_rail_segment_length View documentation}
2652
- * @remarks A rail segment is a continuous section of rail with no branches, signals, nor train stops.
2653
2755
  */
2654
2756
  get_rail_segment_length(): double
2655
2757
  /**
@@ -2657,26 +2759,35 @@ interface LuaEntity extends LuaControl {
2657
2759
  *
2658
2760
  * _Can only be used if this is Rail_
2659
2761
  *
2762
+ * **Note**
2763
+ *
2764
+ * A rail segment is a continuous section of rail with no branches, signals, nor train stops.
2765
+ *
2660
2766
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_rail_segment_overlaps View documentation}
2661
- * @remarks A rail segment is a continuous section of rail with no branches, signals, nor train stops.
2662
2767
  */
2663
2768
  get_rail_segment_overlaps(): LuaEntity[]
2664
2769
  /**
2665
2770
  * Get the filter for a slot in an inserter, loader, or logistic storage container.
2666
2771
  *
2772
+ * **Note**
2773
+ *
2774
+ * The entity must allow filters.
2775
+ *
2667
2776
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_filter View documentation}
2668
2777
  * @param slot_index Index of the slot to get the filter for.
2669
2778
  * @returns Prototype name of the item being filtered. `nil` if the given slot has no filter.
2670
- * @remarks The entity must allow filters.
2671
2779
  */
2672
2780
  get_filter(slot_index: uint): string | undefined
2673
2781
  /**
2674
2782
  * Set the filter for a slot in an inserter, loader, or logistic storage container.
2675
2783
  *
2784
+ * **Note**
2785
+ *
2786
+ * The entity must allow filters.
2787
+ *
2676
2788
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.set_filter View documentation}
2677
2789
  * @param slot_index Index of the slot to set the filter for.
2678
2790
  * @param item Prototype name of the item to filter.
2679
- * @remarks The entity must allow filters.
2680
2791
  */
2681
2792
  set_filter(slot_index: uint, item: string): void
2682
2793
  /**
@@ -2792,9 +2903,12 @@ interface LuaEntity extends LuaControl {
2792
2903
  /**
2793
2904
  * Gets all the `LuaLogisticPoint`s that this entity owns. Optionally returns only the point specified by the index parameter.
2794
2905
  *
2906
+ * **Note**
2907
+ *
2908
+ * When `index` is not given, this will be a single `LuaLogisticPoint` for most entities. For some (such as the player character), it can be zero or more.
2909
+ *
2795
2910
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_logistic_point View documentation}
2796
2911
  * @param index If provided, only returns the `LuaLogisticPoint` specified by this index.
2797
- * @remarks When `index` is not given, this will be a single `LuaLogisticPoint` for most entities. For some (such as the player character), it can be zero or more.
2798
2912
  */
2799
2913
  get_logistic_point(index?: defines.logistic_member_index): LuaLogisticPoint | LuaLogisticPoint[] | undefined
2800
2914
  /**
@@ -2894,9 +3008,12 @@ interface LuaEntity extends LuaControl {
2894
3008
  *
2895
3009
  * _Can only be used if this is Vehicle_
2896
3010
  *
3011
+ * **Note**
3012
+ *
3013
+ * This differs over {@link LuaEntity#set_passenger LuaEntity::set_passenger} in that the passenger can't drive the vehicle.
3014
+ *
2897
3015
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.set_driver View documentation}
2898
3016
  * @param driver The new driver or `nil` to eject the current driver if any.
2899
- * @remarks This differs over {@link LuaEntity#set_passenger LuaEntity::set_passenger} in that the passenger can't drive the vehicle.
2900
3017
  */
2901
3018
  set_driver(driver: LuaEntity | PlayerIdentification | undefined): void
2902
3019
  /**
@@ -2904,9 +3021,12 @@ interface LuaEntity extends LuaControl {
2904
3021
  *
2905
3022
  * _Can only be used if this is Vehicle_
2906
3023
  *
3024
+ * **Note**
3025
+ *
3026
+ * This differs over {@link LuaEntity#get_driver LuaEntity::get_driver} in that the passenger can't drive the car.
3027
+ *
2907
3028
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_passenger View documentation}
2908
3029
  * @returns `nil` if the vehicle contains no passenger. To check if there's a driver see {@link LuaEntity#get_driver LuaEntity::get_driver}.
2909
- * @remarks This differs over {@link LuaEntity#get_driver LuaEntity::get_driver} in that the passenger can't drive the car.
2910
3030
  */
2911
3031
  get_passenger(): LuaEntity | LuaPlayer | undefined
2912
3032
  /**
@@ -2917,8 +3037,11 @@ interface LuaEntity extends LuaControl {
2917
3037
  *
2918
3038
  * _Can only be used if this is Vehicle_
2919
3039
  *
3040
+ * **Note**
3041
+ *
3042
+ * This differs over {@link LuaEntity#get_driver LuaEntity::get_driver} in that the passenger can't drive the car.
3043
+ *
2920
3044
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.set_passenger View documentation}
2921
- * @remarks This differs over {@link LuaEntity#get_driver LuaEntity::get_driver} in that the passenger can't drive the car.
2922
3045
  */
2923
3046
  set_passenger(passenger: LuaEntity | PlayerIdentification): void
2924
3047
  /**
@@ -2971,25 +3094,34 @@ interface LuaEntity extends LuaControl {
2971
3094
  /**
2972
3095
  * Get the amount of all or some fluid in this entity.
2973
3096
  *
3097
+ * **Note**
3098
+ *
3099
+ * If information about fluid temperatures is required, {@link LuaEntity#fluidbox LuaEntity::fluidbox} should be used instead.
3100
+ *
2974
3101
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_fluid_count View documentation}
2975
3102
  * @param fluid Prototype name of the fluid to count. If not specified, count all fluids.
2976
- * @remarks If information about fluid temperatures is required, {@link LuaEntity#fluidbox LuaEntity::fluidbox} should be used instead.
2977
3103
  */
2978
3104
  get_fluid_count(fluid?: string): double
2979
3105
  /**
2980
3106
  * Get amounts of all fluids in this entity.
2981
3107
  *
3108
+ * **Note**
3109
+ *
3110
+ * If information about fluid temperatures is required, {@link LuaEntity#fluidbox LuaEntity::fluidbox} should be used instead.
3111
+ *
2982
3112
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_fluid_contents View documentation}
2983
3113
  * @returns The amounts, indexed by fluid names.
2984
- * @remarks If information about fluid temperatures is required, {@link LuaEntity#fluidbox LuaEntity::fluidbox} should be used instead.
2985
3114
  */
2986
3115
  get_fluid_contents(): Record<string, double>
2987
3116
  /**
2988
3117
  * Remove fluid from this entity.
2989
3118
  *
3119
+ * **Note**
3120
+ *
3121
+ * If temperature is given only fluid matching that exact temperature is removed. If minimum and maximum is given fluid within that range is removed.
3122
+ *
2990
3123
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.remove_fluid View documentation}
2991
3124
  * @returns Amount of fluid actually removed.
2992
- * @remarks If temperature is given only fluid matching that exact temperature is removed. If minimum and maximum is given fluid within that range is removed.
2993
3125
  */
2994
3126
  remove_fluid(params: {
2995
3127
  /**
@@ -3080,8 +3212,11 @@ interface LuaEntity extends LuaControl {
3080
3212
  /**
3081
3213
  * Toggle this entity's equipment movement bonus. Does nothing if the entity does not have an equipment grid.
3082
3214
  *
3215
+ * **Note**
3216
+ *
3217
+ * This property can also be read and written on the equipment grid of this entity.
3218
+ *
3083
3219
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.toggle_equipment_movement_bonus View documentation}
3084
- * @remarks This property can also be read and written on the equipment grid of this entity.
3085
3220
  */
3086
3221
  toggle_equipment_movement_bonus(): void
3087
3222
  /**
@@ -3134,10 +3269,12 @@ interface LuaEntity extends LuaControl {
3134
3269
  * **Raised events:**
3135
3270
  * - {@link ScriptRaisedDestroyEvent script_raised_destroy}? _instantly_ Raised if the `raise_destroyed` flag was set and the entity was successfully mined.
3136
3271
  *
3272
+ * **Notes**
3273
+ * - 'Standard' operation is to keep calling `LuaEntity.mine` with an inventory until all items are transferred and the items dealt with.
3274
+ * - The result of mining the entity (the item(s) it produces when mined) will be dropped on the ground if they don't fit into the provided inventory.
3137
3275
  *
3138
3276
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.mine View documentation}
3139
3277
  * @returns Whether mining succeeded.
3140
- * @remarks 'Standard' operation is to keep calling `LuaEntity.mine` with an inventory until all items are transferred and the items dealt with.<br>The result of mining the entity (the item(s) it produces when mined) will be dropped on the ground if they don't fit into the provided inventory.
3141
3278
  */
3142
3279
  mine(params?: {
3143
3280
  /**
@@ -3220,9 +3357,12 @@ interface LuaEntity extends LuaControl {
3220
3357
  *
3221
3358
  * _Can only be used if this is LinkedBelt_
3222
3359
  *
3360
+ * **Note**
3361
+ *
3362
+ * Can also be used on entity ghost if it contains linked-belt
3363
+ *
3223
3364
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.connect_linked_belts View documentation}
3224
3365
  * @param neighbour Another linked belt or entity ghost containing linked belt to connect or nil to disconnect
3225
- * @remarks Can also be used on entity ghost if it contains linked-belt
3226
3366
  */
3227
3367
  connect_linked_belts(neighbour: LuaEntity | undefined): void
3228
3368
  /**
@@ -3230,8 +3370,11 @@ interface LuaEntity extends LuaControl {
3230
3370
  *
3231
3371
  * _Can only be used if this is LinkedBelt_
3232
3372
  *
3373
+ * **Note**
3374
+ *
3375
+ * Can also be used on entity ghost if it contains linked-belt
3376
+ *
3233
3377
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.disconnect_linked_belts View documentation}
3234
- * @remarks Can also be used on entity ghost if it contains linked-belt
3235
3378
  */
3236
3379
  disconnect_linked_belts(): void
3237
3380
  /**
@@ -3294,29 +3437,40 @@ interface LuaEntity extends LuaControl {
3294
3437
  /**
3295
3438
  * Deactivating an entity will stop all its operations (car will stop moving, inserters will stop working, fish will stop moving etc).
3296
3439
  *
3440
+ * **Notes**
3441
+ * - Entities that are not active naturally can't be set to be active (setting it to be active will do nothing)
3442
+ * - Ghosts, simple smoke, and corpses can't be modified at this time.
3443
+ * - It is even possible to set the character to not be active, so he can't move and perform most of the tasks.
3444
+ *
3297
3445
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.active View documentation}
3298
- * @remarks Entities that are not active naturally can't be set to be active (setting it to be active will do nothing)<br>Ghosts, simple smoke, and corpses can't be modified at this time.<br>It is even possible to set the character to not be active, so he can't move and perform most of the tasks.
3299
3446
  */
3300
3447
  active: boolean
3301
3448
  /**
3302
3449
  * If set to `false`, this entity can't be damaged and won't be attacked automatically. It can however still be mined.
3303
3450
  *
3451
+ * **Note**
3452
+ *
3453
+ * Entities that are indestructible naturally (they have no health, like smoke, resource etc) can't be set to be destructible.
3454
+ *
3304
3455
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.destructible View documentation}
3305
- * @remarks Entities that are indestructible naturally (they have no health, like smoke, resource etc) can't be set to be destructible.
3306
3456
  */
3307
3457
  destructible: boolean
3308
3458
  /**
3309
- *
3459
+ * **Notes**
3460
+ * - Not minable entities can still be destroyed.
3461
+ * - Entities that are not minable naturally (like smoke, character, enemy units etc) can't be set to minable.
3310
3462
  *
3311
3463
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.minable View documentation}
3312
- * @remarks Not minable entities can still be destroyed.<br>Entities that are not minable naturally (like smoke, character, enemy units etc) can't be set to minable.
3313
3464
  */
3314
3465
  minable: boolean
3315
3466
  /**
3316
3467
  * When entity is not to be rotatable (inserter, transport belt etc), it can't be rotated by player using the R key.
3317
3468
  *
3469
+ * **Note**
3470
+ *
3471
+ * Entities that are not rotatable naturally (like chest or furnace) can't be set to be rotatable.
3472
+ *
3318
3473
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.rotatable View documentation}
3319
- * @remarks Entities that are not rotatable naturally (like chest or furnace) can't be set to be rotatable.
3320
3474
  */
3321
3475
  rotatable: boolean
3322
3476
  /**
@@ -3328,8 +3482,11 @@ interface LuaEntity extends LuaControl {
3328
3482
  /**
3329
3483
  * The current health of the entity, or `nil` if it doesn't have health. Health is automatically clamped to be between `0` and max health (inclusive). Entities with a health of `0` can not be attacked.
3330
3484
  *
3485
+ * **Note**
3486
+ *
3487
+ * To get the maximum possible health of this entity, see {@link LuaEntityPrototype#max_health LuaEntityPrototype::max_health} on its prototype.
3488
+ *
3331
3489
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.health View documentation}
3332
- * @remarks To get the maximum possible health of this entity, see {@link LuaEntityPrototype#max_health LuaEntityPrototype::max_health} on its prototype.
3333
3490
  */
3334
3491
  health: float | undefined
3335
3492
  /**
@@ -3359,8 +3516,11 @@ interface LuaEntity extends LuaControl {
3359
3516
  /**
3360
3517
  * The relative orientation of the vehicle turret, artillery turret, artillery wagon or `nil` if this entity isn't a vehicle with a vehicle turret or artillery turret/wagon.
3361
3518
  *
3519
+ * **Note**
3520
+ *
3521
+ * Writing does nothing if the vehicle doesn't have a turret.
3522
+ *
3362
3523
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.relative_turret_orientation View documentation}
3363
- * @remarks Writing does nothing if the vehicle doesn't have a turret.
3364
3524
  */
3365
3525
  relative_turret_orientation: RealOrientation | undefined
3366
3526
  /**
@@ -3384,8 +3544,11 @@ interface LuaEntity extends LuaControl {
3384
3544
  *
3385
3545
  * _Can only be used if this is ResourceEntity_
3386
3546
  *
3547
+ * **Note**
3548
+ *
3549
+ * If this is not an infinite resource reading will give `nil` and writing will give an error.
3550
+ *
3387
3551
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.initial_amount View documentation}
3388
- * @remarks If this is not an infinite resource reading will give `nil` and writing will give an error.
3389
3552
  */
3390
3553
  initial_amount: uint | undefined
3391
3554
  /**
@@ -3468,8 +3631,11 @@ interface LuaEntity extends LuaControl {
3468
3631
  /**
3469
3632
  * Position where the entity puts its stuff.
3470
3633
  *
3634
+ * **Note**
3635
+ *
3636
+ * Meaningful only for entities that put stuff somewhere, such as mining drills or inserters. Mining drills can't have their drop position changed; inserters must have `allow_custom_vectors` set to true on their prototype to allow changing the drop position.
3637
+ *
3471
3638
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.drop_position View documentation}
3472
- * @remarks Meaningful only for entities that put stuff somewhere, such as mining drills or inserters. Mining drills can't have their drop position changed; inserters must have `allow_custom_vectors` set to true on their prototype to allow changing the drop position.
3473
3639
  */
3474
3640
  get drop_position(): MapPositionTable
3475
3641
  set drop_position(value: MapPosition)
@@ -3478,16 +3644,22 @@ interface LuaEntity extends LuaControl {
3478
3644
  *
3479
3645
  * _Can only be used if this is Inserter_
3480
3646
  *
3647
+ * **Note**
3648
+ *
3649
+ * Inserters must have `allow_custom_vectors` set to true on their prototype to allow changing the pickup position.
3650
+ *
3481
3651
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.pickup_position View documentation}
3482
- * @remarks Inserters must have `allow_custom_vectors` set to true on their prototype to allow changing the pickup position.
3483
3652
  */
3484
3653
  get pickup_position(): MapPositionTable
3485
3654
  set pickup_position(value: MapPosition)
3486
3655
  /**
3487
3656
  * The entity this entity is putting its items to, or `nil` if there is no such entity. If there are multiple possible entities at the drop-off point, writing to this attribute allows a mod to choose which one to drop off items to. The entity needs to collide with the tile box under the drop-off position.
3488
3657
  *
3658
+ * **Note**
3659
+ *
3660
+ * Meaningful only for entities that put items somewhere, such as mining drills or inserters. Returns `nil` for any other entity.
3661
+ *
3489
3662
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.drop_target View documentation}
3490
- * @remarks Meaningful only for entities that put items somewhere, such as mining drills or inserters. Returns `nil` for any other entity.
3491
3663
  */
3492
3664
  drop_target: LuaEntity | undefined
3493
3665
  /**
@@ -3583,15 +3755,21 @@ interface LuaEntity extends LuaControl {
3583
3755
  /**
3584
3756
  * The backer name assigned to this entity, or `nil` if this entity doesn't support backer names. Entities that support backer names are labs, locomotives, radars, roboports, and train stops.
3585
3757
  *
3758
+ * **Note**
3759
+ *
3760
+ * While train stops get the name of a backer when placed down, players can rename them if they want to. In this case, `backer_name` returns the player-given name of the entity.
3761
+ *
3586
3762
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.backer_name View documentation}
3587
- * @remarks While train stops get the name of a backer when placed down, players can rename them if they want to. In this case, `backer_name` returns the player-given name of the entity.
3588
3763
  */
3589
3764
  backer_name: string | undefined
3590
3765
  /**
3591
3766
  * The label of this entity if it has one or `nil`. Changing the value will trigger on_entity_renamed event
3592
3767
  *
3768
+ * **Note**
3769
+ *
3770
+ * only usable on entities that have labels (currently only spider-vehicles).
3771
+ *
3593
3772
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.entity_label View documentation}
3594
- * @remarks only usable on entities that have labels (currently only spider-vehicles).
3595
3773
  */
3596
3774
  entity_label: string | undefined
3597
3775
  /**
@@ -3606,8 +3784,11 @@ interface LuaEntity extends LuaControl {
3606
3784
  /**
3607
3785
  * The character, rolling stock, train stop, car, spider-vehicle, flying text, corpse or simple-entity-with-owner color. Returns `nil` if this entity doesn't use custom colors.
3608
3786
  *
3787
+ * **Note**
3788
+ *
3789
+ * Car color is overridden by the color of the current driver/passenger, if there is one.
3790
+ *
3609
3791
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.color View documentation}
3610
- * @remarks Car color is overridden by the color of the current driver/passenger, if there is one.
3611
3792
  */
3612
3793
  get color(): ColorTable | undefined
3613
3794
  set color(value: Color | undefined)
@@ -3670,8 +3851,11 @@ interface LuaEntity extends LuaControl {
3670
3851
  /**
3671
3852
  * The productivity bonus of this entity.
3672
3853
  *
3854
+ * **Note**
3855
+ *
3856
+ * This includes force based bonuses as well as beacon/module bonuses.
3857
+ *
3673
3858
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.productivity_bonus View documentation}
3674
- * @remarks This includes force based bonuses as well as beacon/module bonuses.
3675
3859
  */
3676
3860
  readonly productivity_bonus: double
3677
3861
  /**
@@ -3683,8 +3867,11 @@ interface LuaEntity extends LuaControl {
3683
3867
  /**
3684
3868
  * The speed bonus of this entity.
3685
3869
  *
3870
+ * **Note**
3871
+ *
3872
+ * This includes force based bonuses as well as beacon/module bonuses.
3873
+ *
3686
3874
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.speed_bonus View documentation}
3687
- * @remarks This includes force based bonuses as well as beacon/module bonuses.
3688
3875
  */
3689
3876
  readonly speed_bonus: double
3690
3877
  /**
@@ -3781,8 +3968,11 @@ interface LuaEntity extends LuaControl {
3781
3968
  /**
3782
3969
  * The buffer size for the electric energy source or nil if the entity doesn't have an electric energy source.
3783
3970
  *
3971
+ * **Note**
3972
+ *
3973
+ * Write access is limited to the ElectricEnergyInterface type
3974
+ *
3784
3975
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.electric_buffer_size View documentation}
3785
- * @remarks Write access is limited to the ElectricEnergyInterface type
3786
3976
  */
3787
3977
  electric_buffer_size: double | undefined
3788
3978
  /**
@@ -4025,8 +4215,11 @@ interface LuaEntity extends LuaControl {
4025
4215
  /**
4026
4216
  * Sets the stack size limit on this inserter. If the stack size is > than the force stack size limit the value is ignored.
4027
4217
  *
4218
+ * **Note**
4219
+ *
4220
+ * Set to 0 to reset.
4221
+ *
4028
4222
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.inserter_stack_size_override View documentation}
4029
- * @remarks Set to 0 to reset.
4030
4223
  */
4031
4224
  inserter_stack_size_override: uint
4032
4225
  /**
@@ -4082,8 +4275,11 @@ interface LuaEntity extends LuaControl {
4082
4275
  *
4083
4276
  * _Can only be used if this is CharacterCorpse_
4084
4277
  *
4278
+ * **Note**
4279
+ *
4280
+ * The index is not guaranteed to be valid so it should always be checked first if a player with that index actually exists.
4281
+ *
4085
4282
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.character_corpse_player_index View documentation}
4086
- * @remarks The index is not guaranteed to be valid so it should always be checked first if a player with that index actually exists.
4087
4283
  */
4088
4284
  character_corpse_player_index: uint
4089
4285
  /**
@@ -4111,8 +4307,11 @@ interface LuaEntity extends LuaControl {
4111
4307
  *
4112
4308
  * _Can only be used if this is Character_
4113
4309
  *
4310
+ * **Note**
4311
+ *
4312
+ * A character associated with a player is not directly controlled by any player.
4313
+ *
4114
4314
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.associated_player View documentation}
4115
- * @remarks A character associated with a player is not directly controlled by any player.
4116
4315
  */
4117
4316
  get associated_player(): LuaPlayer | LuaPlayer | undefined
4118
4317
  set associated_player(value: LuaPlayer | PlayerIdentification | undefined)
@@ -4270,8 +4469,11 @@ interface LuaEntity extends LuaControl {
4270
4469
  /**
4271
4470
  * The forces that this `simple-entity-with-owner`, `simple-entity-with-force`, or `flying-text` is visible to. `nil` or an empty array means it is rendered for every force.
4272
4471
  *
4472
+ * **Note**
4473
+ *
4474
+ * Reading will always give an array of {@link LuaForce}
4475
+ *
4273
4476
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.render_to_forces View documentation}
4274
- * @remarks Reading will always give an array of {@link LuaForce}
4275
4477
  */
4276
4478
  get render_to_forces(): LuaForce[] | undefined
4277
4479
  set render_to_forces(value: ForceIdentification[] | undefined)
@@ -4330,22 +4532,31 @@ interface LuaEntity extends LuaControl {
4330
4532
  /**
4331
4533
  * Whether this requester chest is set to also request from buffer chests.
4332
4534
  *
4535
+ * **Note**
4536
+ *
4537
+ * Useable only on entities that have requester slots.
4538
+ *
4333
4539
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.request_from_buffers View documentation}
4334
- * @remarks Useable only on entities that have requester slots.
4335
4540
  */
4336
4541
  request_from_buffers: boolean
4337
4542
  /**
4338
4543
  * Whether this corpse will ever fade away.
4339
4544
  *
4545
+ * **Note**
4546
+ *
4547
+ * Useable only on corpses.
4548
+ *
4340
4549
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.corpse_expires View documentation}
4341
- * @remarks Useable only on corpses.
4342
4550
  */
4343
4551
  corpse_expires: boolean
4344
4552
  /**
4345
4553
  * If true, corpse won't be destroyed when entities are placed over it. If false, whether corpse will be removed or not depends on value of CorpsePrototype::remove_on_entity_placement.
4346
4554
  *
4555
+ * **Note**
4556
+ *
4557
+ * Useable only on corpses.
4558
+ *
4347
4559
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.corpse_immune_to_entity_placement View documentation}
4348
- * @remarks Useable only on corpses.
4349
4560
  */
4350
4561
  corpse_immune_to_entity_placement: boolean
4351
4562
  /**
@@ -4400,8 +4611,11 @@ interface LuaEntity extends LuaControl {
4400
4611
  *
4401
4612
  * _Can only be used if this is TrainStop_
4402
4613
  *
4614
+ * **Notes**
4615
+ * - Train may be included multiple times when braking distance covers this train stop multiple times
4616
+ * - Value may be read even when train stop has no control behavior
4617
+ *
4403
4618
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.trains_count View documentation}
4404
- * @remarks Train may be included multiple times when braking distance covers this train stop multiple times<br>Value may be read even when train stop has no control behavior
4405
4619
  */
4406
4620
  readonly trains_count: uint | undefined
4407
4621
  /**
@@ -4409,8 +4623,11 @@ interface LuaEntity extends LuaControl {
4409
4623
  *
4410
4624
  * _Can only be used if this is TrainStop_
4411
4625
  *
4626
+ * **Note**
4627
+ *
4628
+ * When a train stop has a control behavior with wire connected and set_trains_limit enabled, this value will be overwritten by it
4629
+ *
4412
4630
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.trains_limit View documentation}
4413
- * @remarks When a train stop has a control behavior with wire connected and set_trains_limit enabled, this value will be overwritten by it
4414
4631
  */
4415
4632
  trains_limit: uint
4416
4633
  /**
@@ -4470,8 +4687,11 @@ interface LuaEntity extends LuaControl {
4470
4687
  *
4471
4688
  * _Can only be used if this is LinkedBelt_
4472
4689
  *
4690
+ * **Notes**
4691
+ * - Can only be changed when linked belt is disconnected (has no neighbour set)
4692
+ * - Can also be used on entity ghost if it contains linked-belt
4693
+ *
4473
4694
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.linked_belt_type View documentation}
4474
- * @remarks Can only be changed when linked belt is disconnected (has no neighbour set)<br>Can also be used on entity ghost if it contains linked-belt
4475
4695
  */
4476
4696
  linked_belt_type: "input" | "output"
4477
4697
  /**
@@ -4479,8 +4699,11 @@ interface LuaEntity extends LuaControl {
4479
4699
  *
4480
4700
  * _Can only be used if this is LinkedBelt_
4481
4701
  *
4702
+ * **Notes**
4703
+ * - Can also be used on entity ghost if it contains linked-belt
4704
+ * - May return entity ghost which contains linked belt to which connection is made
4705
+ *
4482
4706
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.linked_belt_neighbour View documentation}
4483
- * @remarks Can also be used on entity ghost if it contains linked-belt<br>May return entity ghost which contains linked belt to which connection is made
4484
4707
  */
4485
4708
  readonly linked_belt_neighbour: LuaEntity | undefined
4486
4709
  /**
@@ -4547,10 +4770,12 @@ interface BaseEntity extends LuaControl {
4547
4770
  * **Raised events:**
4548
4771
  * - {@link ScriptRaisedDestroyEvent script_raised_destroy}? _instantly_ Raised if the `raise_destroy` flag was set and the entity was successfully destroyed.
4549
4772
  *
4773
+ * **Note**
4774
+ *
4775
+ * Not all entities can be destroyed - things such as rails under trains cannot be destroyed until the train is moved or destroyed.
4550
4776
  *
4551
4777
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.destroy View documentation}
4552
4778
  * @returns Returns `false` if the entity was valid and destruction failed, `true` in all other cases.
4553
- * @remarks Not all entities can be destroyed - things such as rails under trains cannot be destroyed until the train is moved or destroyed.
4554
4779
  */
4555
4780
  destroy(params?: {
4556
4781
  /**
@@ -4586,10 +4811,13 @@ interface BaseEntity extends LuaControl {
4586
4811
  /**
4587
4812
  * Test whether this entity's prototype has a certain flag set.
4588
4813
  *
4814
+ * **Note**
4815
+ *
4816
+ * `entity.has_flag(f)` is a shortcut for `entity.prototype.has_flag(f)`.
4817
+ *
4589
4818
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.has_flag View documentation}
4590
4819
  * @param flag The flag to test. See {@link EntityPrototypeFlags} for a list of flags.
4591
4820
  * @returns `true` if this entity has the given flag set.
4592
- * @remarks `entity.has_flag(f)` is a shortcut for `entity.prototype.has_flag(f)`.
4593
4821
  */
4594
4822
  has_flag(flag: keyof EntityPrototypeFlags): boolean
4595
4823
  /**
@@ -4693,28 +4921,37 @@ interface BaseEntity extends LuaControl {
4693
4921
  /**
4694
4922
  * Get a logistic requester slot.
4695
4923
  *
4924
+ * **Note**
4925
+ *
4926
+ * Useable only on entities that have requester slots.
4927
+ *
4696
4928
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_request_slot View documentation}
4697
4929
  * @param slot The slot index.
4698
4930
  * @returns Contents of the specified slot; `nil` if the given slot contains no request.
4699
- * @remarks Useable only on entities that have requester slots.
4700
4931
  */
4701
4932
  get_request_slot(slot: uint): SimpleItemStack | undefined
4702
4933
  /**
4703
4934
  * Set a logistic requester slot.
4704
4935
  *
4936
+ * **Note**
4937
+ *
4938
+ * Useable only on entities that have requester slots.
4939
+ *
4705
4940
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.set_request_slot View documentation}
4706
4941
  * @param request What to request.
4707
4942
  * @param slot The slot index.
4708
4943
  * @returns Whether the slot was set.
4709
- * @remarks Useable only on entities that have requester slots.
4710
4944
  */
4711
4945
  set_request_slot(request: ItemStackIdentification, slot: uint): boolean
4712
4946
  /**
4713
4947
  * Clear a logistic requester slot.
4714
4948
  *
4949
+ * **Note**
4950
+ *
4951
+ * Useable only on entities that have requester slots.
4952
+ *
4715
4953
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.clear_request_slot View documentation}
4716
4954
  * @param slot The slot index.
4717
- * @remarks Useable only on entities that have requester slots.
4718
4955
  */
4719
4956
  clear_request_slot(slot: uint): void
4720
4957
  /**
@@ -4766,19 +5003,25 @@ interface BaseEntity extends LuaControl {
4766
5003
  /**
4767
5004
  * Get the filter for a slot in an inserter, loader, or logistic storage container.
4768
5005
  *
5006
+ * **Note**
5007
+ *
5008
+ * The entity must allow filters.
5009
+ *
4769
5010
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_filter View documentation}
4770
5011
  * @param slot_index Index of the slot to get the filter for.
4771
5012
  * @returns Prototype name of the item being filtered. `nil` if the given slot has no filter.
4772
- * @remarks The entity must allow filters.
4773
5013
  */
4774
5014
  get_filter(slot_index: uint): string | undefined
4775
5015
  /**
4776
5016
  * Set the filter for a slot in an inserter, loader, or logistic storage container.
4777
5017
  *
5018
+ * **Note**
5019
+ *
5020
+ * The entity must allow filters.
5021
+ *
4778
5022
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.set_filter View documentation}
4779
5023
  * @param slot_index Index of the slot to set the filter for.
4780
5024
  * @param item Prototype name of the item to filter.
4781
- * @remarks The entity must allow filters.
4782
5025
  */
4783
5026
  set_filter(slot_index: uint, item: string): void
4784
5027
  /**
@@ -4841,9 +5084,12 @@ interface BaseEntity extends LuaControl {
4841
5084
  /**
4842
5085
  * Gets all the `LuaLogisticPoint`s that this entity owns. Optionally returns only the point specified by the index parameter.
4843
5086
  *
5087
+ * **Note**
5088
+ *
5089
+ * When `index` is not given, this will be a single `LuaLogisticPoint` for most entities. For some (such as the player character), it can be zero or more.
5090
+ *
4844
5091
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_logistic_point View documentation}
4845
5092
  * @param index If provided, only returns the `LuaLogisticPoint` specified by this index.
4846
- * @remarks When `index` is not given, this will be a single `LuaLogisticPoint` for most entities. For some (such as the player character), it can be zero or more.
4847
5093
  */
4848
5094
  get_logistic_point(index?: defines.logistic_member_index): LuaLogisticPoint | LuaLogisticPoint[] | undefined
4849
5095
  /**
@@ -4933,25 +5179,34 @@ interface BaseEntity extends LuaControl {
4933
5179
  /**
4934
5180
  * Get the amount of all or some fluid in this entity.
4935
5181
  *
5182
+ * **Note**
5183
+ *
5184
+ * If information about fluid temperatures is required, {@link LuaEntity#fluidbox LuaEntity::fluidbox} should be used instead.
5185
+ *
4936
5186
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_fluid_count View documentation}
4937
5187
  * @param fluid Prototype name of the fluid to count. If not specified, count all fluids.
4938
- * @remarks If information about fluid temperatures is required, {@link LuaEntity#fluidbox LuaEntity::fluidbox} should be used instead.
4939
5188
  */
4940
5189
  get_fluid_count(fluid?: string): double
4941
5190
  /**
4942
5191
  * Get amounts of all fluids in this entity.
4943
5192
  *
5193
+ * **Note**
5194
+ *
5195
+ * If information about fluid temperatures is required, {@link LuaEntity#fluidbox LuaEntity::fluidbox} should be used instead.
5196
+ *
4944
5197
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_fluid_contents View documentation}
4945
5198
  * @returns The amounts, indexed by fluid names.
4946
- * @remarks If information about fluid temperatures is required, {@link LuaEntity#fluidbox LuaEntity::fluidbox} should be used instead.
4947
5199
  */
4948
5200
  get_fluid_contents(): Record<string, double>
4949
5201
  /**
4950
5202
  * Remove fluid from this entity.
4951
5203
  *
5204
+ * **Note**
5205
+ *
5206
+ * If temperature is given only fluid matching that exact temperature is removed. If minimum and maximum is given fluid within that range is removed.
5207
+ *
4952
5208
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.remove_fluid View documentation}
4953
5209
  * @returns Amount of fluid actually removed.
4954
- * @remarks If temperature is given only fluid matching that exact temperature is removed. If minimum and maximum is given fluid within that range is removed.
4955
5210
  */
4956
5211
  remove_fluid(params: {
4957
5212
  /**
@@ -5002,8 +5257,11 @@ interface BaseEntity extends LuaControl {
5002
5257
  /**
5003
5258
  * Toggle this entity's equipment movement bonus. Does nothing if the entity does not have an equipment grid.
5004
5259
  *
5260
+ * **Note**
5261
+ *
5262
+ * This property can also be read and written on the equipment grid of this entity.
5263
+ *
5005
5264
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.toggle_equipment_movement_bonus View documentation}
5006
- * @remarks This property can also be read and written on the equipment grid of this entity.
5007
5265
  */
5008
5266
  toggle_equipment_movement_bonus(): void
5009
5267
  /**
@@ -5045,10 +5303,12 @@ interface BaseEntity extends LuaControl {
5045
5303
  * **Raised events:**
5046
5304
  * - {@link ScriptRaisedDestroyEvent script_raised_destroy}? _instantly_ Raised if the `raise_destroyed` flag was set and the entity was successfully mined.
5047
5305
  *
5306
+ * **Notes**
5307
+ * - 'Standard' operation is to keep calling `LuaEntity.mine` with an inventory until all items are transferred and the items dealt with.
5308
+ * - The result of mining the entity (the item(s) it produces when mined) will be dropped on the ground if they don't fit into the provided inventory.
5048
5309
  *
5049
5310
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.mine View documentation}
5050
5311
  * @returns Whether mining succeeded.
5051
- * @remarks 'Standard' operation is to keep calling `LuaEntity.mine` with an inventory until all items are transferred and the items dealt with.<br>The result of mining the entity (the item(s) it produces when mined) will be dropped on the ground if they don't fit into the provided inventory.
5052
5312
  */
5053
5313
  mine(params?: {
5054
5314
  /**
@@ -5137,29 +5397,40 @@ interface BaseEntity extends LuaControl {
5137
5397
  /**
5138
5398
  * Deactivating an entity will stop all its operations (car will stop moving, inserters will stop working, fish will stop moving etc).
5139
5399
  *
5400
+ * **Notes**
5401
+ * - Entities that are not active naturally can't be set to be active (setting it to be active will do nothing)
5402
+ * - Ghosts, simple smoke, and corpses can't be modified at this time.
5403
+ * - It is even possible to set the character to not be active, so he can't move and perform most of the tasks.
5404
+ *
5140
5405
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.active View documentation}
5141
- * @remarks Entities that are not active naturally can't be set to be active (setting it to be active will do nothing)<br>Ghosts, simple smoke, and corpses can't be modified at this time.<br>It is even possible to set the character to not be active, so he can't move and perform most of the tasks.
5142
5406
  */
5143
5407
  active: boolean
5144
5408
  /**
5145
5409
  * If set to `false`, this entity can't be damaged and won't be attacked automatically. It can however still be mined.
5146
5410
  *
5411
+ * **Note**
5412
+ *
5413
+ * Entities that are indestructible naturally (they have no health, like smoke, resource etc) can't be set to be destructible.
5414
+ *
5147
5415
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.destructible View documentation}
5148
- * @remarks Entities that are indestructible naturally (they have no health, like smoke, resource etc) can't be set to be destructible.
5149
5416
  */
5150
5417
  destructible: boolean
5151
5418
  /**
5152
- *
5419
+ * **Notes**
5420
+ * - Not minable entities can still be destroyed.
5421
+ * - Entities that are not minable naturally (like smoke, character, enemy units etc) can't be set to minable.
5153
5422
  *
5154
5423
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.minable View documentation}
5155
- * @remarks Not minable entities can still be destroyed.<br>Entities that are not minable naturally (like smoke, character, enemy units etc) can't be set to minable.
5156
5424
  */
5157
5425
  minable: boolean
5158
5426
  /**
5159
5427
  * When entity is not to be rotatable (inserter, transport belt etc), it can't be rotated by player using the R key.
5160
5428
  *
5429
+ * **Note**
5430
+ *
5431
+ * Entities that are not rotatable naturally (like chest or furnace) can't be set to be rotatable.
5432
+ *
5161
5433
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.rotatable View documentation}
5162
- * @remarks Entities that are not rotatable naturally (like chest or furnace) can't be set to be rotatable.
5163
5434
  */
5164
5435
  rotatable: boolean
5165
5436
  /**
@@ -5171,8 +5442,11 @@ interface BaseEntity extends LuaControl {
5171
5442
  /**
5172
5443
  * The current health of the entity, or `nil` if it doesn't have health. Health is automatically clamped to be between `0` and max health (inclusive). Entities with a health of `0` can not be attacked.
5173
5444
  *
5445
+ * **Note**
5446
+ *
5447
+ * To get the maximum possible health of this entity, see {@link LuaEntityPrototype#max_health LuaEntityPrototype::max_health} on its prototype.
5448
+ *
5174
5449
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.health View documentation}
5175
- * @remarks To get the maximum possible health of this entity, see {@link LuaEntityPrototype#max_health LuaEntityPrototype::max_health} on its prototype.
5176
5450
  */
5177
5451
  health: float | undefined
5178
5452
  /**
@@ -5202,8 +5476,11 @@ interface BaseEntity extends LuaControl {
5202
5476
  /**
5203
5477
  * The relative orientation of the vehicle turret, artillery turret, artillery wagon or `nil` if this entity isn't a vehicle with a vehicle turret or artillery turret/wagon.
5204
5478
  *
5479
+ * **Note**
5480
+ *
5481
+ * Writing does nothing if the vehicle doesn't have a turret.
5482
+ *
5205
5483
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.relative_turret_orientation View documentation}
5206
- * @remarks Writing does nothing if the vehicle doesn't have a turret.
5207
5484
  */
5208
5485
  relative_turret_orientation: RealOrientation | undefined
5209
5486
  /**
@@ -5227,16 +5504,22 @@ interface BaseEntity extends LuaControl {
5227
5504
  /**
5228
5505
  * Position where the entity puts its stuff.
5229
5506
  *
5507
+ * **Note**
5508
+ *
5509
+ * Meaningful only for entities that put stuff somewhere, such as mining drills or inserters. Mining drills can't have their drop position changed; inserters must have `allow_custom_vectors` set to true on their prototype to allow changing the drop position.
5510
+ *
5230
5511
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.drop_position View documentation}
5231
- * @remarks Meaningful only for entities that put stuff somewhere, such as mining drills or inserters. Mining drills can't have their drop position changed; inserters must have `allow_custom_vectors` set to true on their prototype to allow changing the drop position.
5232
5512
  */
5233
5513
  get drop_position(): MapPositionTable
5234
5514
  set drop_position(value: MapPosition)
5235
5515
  /**
5236
5516
  * The entity this entity is putting its items to, or `nil` if there is no such entity. If there are multiple possible entities at the drop-off point, writing to this attribute allows a mod to choose which one to drop off items to. The entity needs to collide with the tile box under the drop-off position.
5237
5517
  *
5518
+ * **Note**
5519
+ *
5520
+ * Meaningful only for entities that put items somewhere, such as mining drills or inserters. Returns `nil` for any other entity.
5521
+ *
5238
5522
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.drop_target View documentation}
5239
- * @remarks Meaningful only for entities that put items somewhere, such as mining drills or inserters. Returns `nil` for any other entity.
5240
5523
  */
5241
5524
  drop_target: LuaEntity | undefined
5242
5525
  /**
@@ -5284,15 +5567,21 @@ interface BaseEntity extends LuaControl {
5284
5567
  /**
5285
5568
  * The backer name assigned to this entity, or `nil` if this entity doesn't support backer names. Entities that support backer names are labs, locomotives, radars, roboports, and train stops.
5286
5569
  *
5570
+ * **Note**
5571
+ *
5572
+ * While train stops get the name of a backer when placed down, players can rename them if they want to. In this case, `backer_name` returns the player-given name of the entity.
5573
+ *
5287
5574
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.backer_name View documentation}
5288
- * @remarks While train stops get the name of a backer when placed down, players can rename them if they want to. In this case, `backer_name` returns the player-given name of the entity.
5289
5575
  */
5290
5576
  backer_name: string | undefined
5291
5577
  /**
5292
5578
  * The label of this entity if it has one or `nil`. Changing the value will trigger on_entity_renamed event
5293
5579
  *
5580
+ * **Note**
5581
+ *
5582
+ * only usable on entities that have labels (currently only spider-vehicles).
5583
+ *
5294
5584
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.entity_label View documentation}
5295
- * @remarks only usable on entities that have labels (currently only spider-vehicles).
5296
5585
  */
5297
5586
  entity_label: string | undefined
5298
5587
  /**
@@ -5307,16 +5596,22 @@ interface BaseEntity extends LuaControl {
5307
5596
  /**
5308
5597
  * The character, rolling stock, train stop, car, spider-vehicle, flying text, corpse or simple-entity-with-owner color. Returns `nil` if this entity doesn't use custom colors.
5309
5598
  *
5599
+ * **Note**
5600
+ *
5601
+ * Car color is overridden by the color of the current driver/passenger, if there is one.
5602
+ *
5310
5603
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.color View documentation}
5311
- * @remarks Car color is overridden by the color of the current driver/passenger, if there is one.
5312
5604
  */
5313
5605
  get color(): ColorTable | undefined
5314
5606
  set color(value: Color | undefined)
5315
5607
  /**
5316
5608
  * The productivity bonus of this entity.
5317
5609
  *
5610
+ * **Note**
5611
+ *
5612
+ * This includes force based bonuses as well as beacon/module bonuses.
5613
+ *
5318
5614
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.productivity_bonus View documentation}
5319
- * @remarks This includes force based bonuses as well as beacon/module bonuses.
5320
5615
  */
5321
5616
  readonly productivity_bonus: double
5322
5617
  /**
@@ -5328,8 +5623,11 @@ interface BaseEntity extends LuaControl {
5328
5623
  /**
5329
5624
  * The speed bonus of this entity.
5330
5625
  *
5626
+ * **Note**
5627
+ *
5628
+ * This includes force based bonuses as well as beacon/module bonuses.
5629
+ *
5331
5630
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.speed_bonus View documentation}
5332
- * @remarks This includes force based bonuses as well as beacon/module bonuses.
5333
5631
  */
5334
5632
  readonly speed_bonus: double
5335
5633
  /**
@@ -5359,8 +5657,11 @@ interface BaseEntity extends LuaControl {
5359
5657
  /**
5360
5658
  * The buffer size for the electric energy source or nil if the entity doesn't have an electric energy source.
5361
5659
  *
5660
+ * **Note**
5661
+ *
5662
+ * Write access is limited to the ElectricEnergyInterface type
5663
+ *
5362
5664
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.electric_buffer_size View documentation}
5363
- * @remarks Write access is limited to the ElectricEnergyInterface type
5364
5665
  */
5365
5666
  electric_buffer_size: double | undefined
5366
5667
  /**
@@ -5543,8 +5844,11 @@ interface BaseEntity extends LuaControl {
5543
5844
  /**
5544
5845
  * Sets the stack size limit on this inserter. If the stack size is > than the force stack size limit the value is ignored.
5545
5846
  *
5847
+ * **Note**
5848
+ *
5849
+ * Set to 0 to reset.
5850
+ *
5546
5851
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.inserter_stack_size_override View documentation}
5547
- * @remarks Set to 0 to reset.
5548
5852
  */
5549
5853
  inserter_stack_size_override: uint
5550
5854
  /**
@@ -5589,8 +5893,11 @@ interface BaseEntity extends LuaControl {
5589
5893
  /**
5590
5894
  * The forces that this `simple-entity-with-owner`, `simple-entity-with-force`, or `flying-text` is visible to. `nil` or an empty array means it is rendered for every force.
5591
5895
  *
5896
+ * **Note**
5897
+ *
5898
+ * Reading will always give an array of {@link LuaForce}
5899
+ *
5592
5900
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.render_to_forces View documentation}
5593
- * @remarks Reading will always give an array of {@link LuaForce}
5594
5901
  */
5595
5902
  get render_to_forces(): LuaForce[] | undefined
5596
5903
  set render_to_forces(value: ForceIdentification[] | undefined)
@@ -5609,22 +5916,31 @@ interface BaseEntity extends LuaControl {
5609
5916
  /**
5610
5917
  * Whether this requester chest is set to also request from buffer chests.
5611
5918
  *
5919
+ * **Note**
5920
+ *
5921
+ * Useable only on entities that have requester slots.
5922
+ *
5612
5923
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.request_from_buffers View documentation}
5613
- * @remarks Useable only on entities that have requester slots.
5614
5924
  */
5615
5925
  request_from_buffers: boolean
5616
5926
  /**
5617
5927
  * Whether this corpse will ever fade away.
5618
5928
  *
5929
+ * **Note**
5930
+ *
5931
+ * Useable only on corpses.
5932
+ *
5619
5933
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.corpse_expires View documentation}
5620
- * @remarks Useable only on corpses.
5621
5934
  */
5622
5935
  corpse_expires: boolean
5623
5936
  /**
5624
5937
  * If true, corpse won't be destroyed when entities are placed over it. If false, whether corpse will be removed or not depends on value of CorpsePrototype::remove_on_entity_placement.
5625
5938
  *
5939
+ * **Note**
5940
+ *
5941
+ * Useable only on corpses.
5942
+ *
5626
5943
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.corpse_immune_to_entity_placement View documentation}
5627
- * @remarks Useable only on corpses.
5628
5944
  */
5629
5945
  corpse_immune_to_entity_placement: boolean
5630
5946
  /**
@@ -5842,10 +6158,13 @@ interface MarketEntity extends BaseEntity {
5842
6158
  *
5843
6159
  * _Can only be used if this is Market_
5844
6160
  *
6161
+ * **Note**
6162
+ *
6163
+ * The other offers are moved down to fill the gap created by removing the offer, which decrements the overall size of the offer array.
6164
+ *
5845
6165
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.remove_market_item View documentation}
5846
6166
  * @param offer Index of offer to remove.
5847
6167
  * @returns `true` if the offer was successfully removed; `false` when the given index was not valid.
5848
- * @remarks The other offers are moved down to fill the gap created by removing the offer, which decrements the overall size of the offer array.
5849
6168
  */
5850
6169
  remove_market_item(offer: uint): boolean
5851
6170
  /**
@@ -6051,11 +6370,14 @@ interface RailEntity extends BaseEntity {
6051
6370
  *
6052
6371
  * _Can only be used if this is Rail_
6053
6372
  *
6373
+ * **Note**
6374
+ *
6375
+ * A rail segment is a continuous section of rail with no branches, signals, nor train stops.
6376
+ *
6054
6377
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_rail_segment_entity View documentation}
6055
6378
  * @param direction The direction of travel relative to this rail.
6056
6379
  * @param in_else_out If true, gets the entity at the entrance of the rail segment, otherwise gets the entity at the exit of the rail segment.
6057
6380
  * @returns `nil` if the rail segment doesn't start/end with a signal nor a train stop.
6058
- * @remarks A rail segment is a continuous section of rail with no branches, signals, nor train stops.
6059
6381
  */
6060
6382
  get_rail_segment_entity(direction: defines.rail_direction, in_else_out: boolean): LuaEntity | undefined
6061
6383
  /**
@@ -6063,10 +6385,13 @@ interface RailEntity extends BaseEntity {
6063
6385
  *
6064
6386
  * _Can only be used if this is Rail_
6065
6387
  *
6388
+ * **Note**
6389
+ *
6390
+ * A rail segment is a continuous section of rail with no branches, signals, nor train stops.
6391
+ *
6066
6392
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_rail_segment_end View documentation}
6067
6393
  * @returns The rail entity.
6068
6394
  * @returns A rail direction pointing out of the rail segment from the end rail.
6069
- * @remarks A rail segment is a continuous section of rail with no branches, signals, nor train stops.
6070
6395
  */
6071
6396
  get_rail_segment_end(direction: defines.rail_direction): LuaMultiReturn<[LuaEntity, defines.rail_direction]>
6072
6397
  /**
@@ -6074,8 +6399,11 @@ interface RailEntity extends BaseEntity {
6074
6399
  *
6075
6400
  * _Can only be used if this is Rail_
6076
6401
  *
6402
+ * **Note**
6403
+ *
6404
+ * A rail segment is a continuous section of rail with no branches, signals, nor train stops.
6405
+ *
6077
6406
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_rail_segment_length View documentation}
6078
- * @remarks A rail segment is a continuous section of rail with no branches, signals, nor train stops.
6079
6407
  */
6080
6408
  get_rail_segment_length(): double
6081
6409
  /**
@@ -6083,8 +6411,11 @@ interface RailEntity extends BaseEntity {
6083
6411
  *
6084
6412
  * _Can only be used if this is Rail_
6085
6413
  *
6414
+ * **Note**
6415
+ *
6416
+ * A rail segment is a continuous section of rail with no branches, signals, nor train stops.
6417
+ *
6086
6418
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_rail_segment_overlaps View documentation}
6087
- * @remarks A rail segment is a continuous section of rail with no branches, signals, nor train stops.
6088
6419
  */
6089
6420
  get_rail_segment_overlaps(): LuaEntity[]
6090
6421
  /**
@@ -6308,9 +6639,12 @@ interface VehicleEntity extends BaseEntity {
6308
6639
  *
6309
6640
  * _Can only be used if this is Vehicle_
6310
6641
  *
6642
+ * **Note**
6643
+ *
6644
+ * This differs over {@link LuaEntity#set_passenger LuaEntity::set_passenger} in that the passenger can't drive the vehicle.
6645
+ *
6311
6646
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.set_driver View documentation}
6312
6647
  * @param driver The new driver or `nil` to eject the current driver if any.
6313
- * @remarks This differs over {@link LuaEntity#set_passenger LuaEntity::set_passenger} in that the passenger can't drive the vehicle.
6314
6648
  */
6315
6649
  set_driver(driver: LuaEntity | PlayerIdentification | undefined): void
6316
6650
  /**
@@ -6318,9 +6652,12 @@ interface VehicleEntity extends BaseEntity {
6318
6652
  *
6319
6653
  * _Can only be used if this is Vehicle_
6320
6654
  *
6655
+ * **Note**
6656
+ *
6657
+ * This differs over {@link LuaEntity#get_driver LuaEntity::get_driver} in that the passenger can't drive the car.
6658
+ *
6321
6659
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.get_passenger View documentation}
6322
6660
  * @returns `nil` if the vehicle contains no passenger. To check if there's a driver see {@link LuaEntity#get_driver LuaEntity::get_driver}.
6323
- * @remarks This differs over {@link LuaEntity#get_driver LuaEntity::get_driver} in that the passenger can't drive the car.
6324
6661
  */
6325
6662
  get_passenger(): LuaEntity | LuaPlayer | undefined
6326
6663
  /**
@@ -6331,8 +6668,11 @@ interface VehicleEntity extends BaseEntity {
6331
6668
  *
6332
6669
  * _Can only be used if this is Vehicle_
6333
6670
  *
6671
+ * **Note**
6672
+ *
6673
+ * This differs over {@link LuaEntity#get_driver LuaEntity::get_driver} in that the passenger can't drive the car.
6674
+ *
6334
6675
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.set_passenger View documentation}
6335
- * @remarks This differs over {@link LuaEntity#get_driver LuaEntity::get_driver} in that the passenger can't drive the car.
6336
6676
  */
6337
6677
  set_passenger(passenger: LuaEntity | PlayerIdentification): void
6338
6678
  /**
@@ -6386,8 +6726,11 @@ interface TrainStopEntity extends BaseEntity {
6386
6726
  *
6387
6727
  * _Can only be used if this is TrainStop_
6388
6728
  *
6729
+ * **Notes**
6730
+ * - Train may be included multiple times when braking distance covers this train stop multiple times
6731
+ * - Value may be read even when train stop has no control behavior
6732
+ *
6389
6733
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.trains_count View documentation}
6390
- * @remarks Train may be included multiple times when braking distance covers this train stop multiple times<br>Value may be read even when train stop has no control behavior
6391
6734
  */
6392
6735
  readonly trains_count: uint | undefined
6393
6736
  /**
@@ -6395,8 +6738,11 @@ interface TrainStopEntity extends BaseEntity {
6395
6738
  *
6396
6739
  * _Can only be used if this is TrainStop_
6397
6740
  *
6741
+ * **Note**
6742
+ *
6743
+ * When a train stop has a control behavior with wire connected and set_trains_limit enabled, this value will be overwritten by it
6744
+ *
6398
6745
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.trains_limit View documentation}
6399
- * @remarks When a train stop has a control behavior with wire connected and set_trains_limit enabled, this value will be overwritten by it
6400
6746
  */
6401
6747
  trains_limit: uint
6402
6748
  }
@@ -6467,8 +6813,11 @@ interface ResourceEntity extends BaseEntity {
6467
6813
  *
6468
6814
  * _Can only be used if this is ResourceEntity_
6469
6815
  *
6816
+ * **Note**
6817
+ *
6818
+ * If this is not an infinite resource reading will give `nil` and writing will give an error.
6819
+ *
6470
6820
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.initial_amount View documentation}
6471
- * @remarks If this is not an infinite resource reading will give `nil` and writing will give an error.
6472
6821
  */
6473
6822
  initial_amount: uint | undefined
6474
6823
  }
@@ -6556,9 +6905,12 @@ interface LinkedBeltEntity extends BaseEntity {
6556
6905
  *
6557
6906
  * _Can only be used if this is LinkedBelt_
6558
6907
  *
6908
+ * **Note**
6909
+ *
6910
+ * Can also be used on entity ghost if it contains linked-belt
6911
+ *
6559
6912
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.connect_linked_belts View documentation}
6560
6913
  * @param neighbour Another linked belt or entity ghost containing linked belt to connect or nil to disconnect
6561
- * @remarks Can also be used on entity ghost if it contains linked-belt
6562
6914
  */
6563
6915
  connect_linked_belts(neighbour: LuaEntity | undefined): void
6564
6916
  /**
@@ -6566,8 +6918,11 @@ interface LinkedBeltEntity extends BaseEntity {
6566
6918
  *
6567
6919
  * _Can only be used if this is LinkedBelt_
6568
6920
  *
6921
+ * **Note**
6922
+ *
6923
+ * Can also be used on entity ghost if it contains linked-belt
6924
+ *
6569
6925
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.disconnect_linked_belts View documentation}
6570
- * @remarks Can also be used on entity ghost if it contains linked-belt
6571
6926
  */
6572
6927
  disconnect_linked_belts(): void
6573
6928
  /**
@@ -6575,8 +6930,11 @@ interface LinkedBeltEntity extends BaseEntity {
6575
6930
  *
6576
6931
  * _Can only be used if this is LinkedBelt_
6577
6932
  *
6933
+ * **Notes**
6934
+ * - Can only be changed when linked belt is disconnected (has no neighbour set)
6935
+ * - Can also be used on entity ghost if it contains linked-belt
6936
+ *
6578
6937
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.linked_belt_type View documentation}
6579
- * @remarks Can only be changed when linked belt is disconnected (has no neighbour set)<br>Can also be used on entity ghost if it contains linked-belt
6580
6938
  */
6581
6939
  linked_belt_type: "input" | "output"
6582
6940
  /**
@@ -6584,8 +6942,11 @@ interface LinkedBeltEntity extends BaseEntity {
6584
6942
  *
6585
6943
  * _Can only be used if this is LinkedBelt_
6586
6944
  *
6945
+ * **Notes**
6946
+ * - Can also be used on entity ghost if it contains linked-belt
6947
+ * - May return entity ghost which contains linked belt to which connection is made
6948
+ *
6587
6949
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.linked_belt_neighbour View documentation}
6588
- * @remarks Can also be used on entity ghost if it contains linked-belt<br>May return entity ghost which contains linked belt to which connection is made
6589
6950
  */
6590
6951
  readonly linked_belt_neighbour: LuaEntity | undefined
6591
6952
  }
@@ -6694,8 +7055,11 @@ interface InserterEntity extends BaseEntity {
6694
7055
  *
6695
7056
  * _Can only be used if this is Inserter_
6696
7057
  *
7058
+ * **Note**
7059
+ *
7060
+ * Inserters must have `allow_custom_vectors` set to true on their prototype to allow changing the pickup position.
7061
+ *
6697
7062
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.pickup_position View documentation}
6698
- * @remarks Inserters must have `allow_custom_vectors` set to true on their prototype to allow changing the pickup position.
6699
7063
  */
6700
7064
  get pickup_position(): MapPositionTable
6701
7065
  set pickup_position(value: MapPosition)
@@ -6759,8 +7123,11 @@ interface CharacterEntity extends BaseEntity {
6759
7123
  *
6760
7124
  * _Can only be used if this is Character_
6761
7125
  *
7126
+ * **Note**
7127
+ *
7128
+ * A character associated with a player is not directly controlled by any player.
7129
+ *
6762
7130
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.associated_player View documentation}
6763
- * @remarks A character associated with a player is not directly controlled by any player.
6764
7131
  */
6765
7132
  get associated_player(): LuaPlayer | LuaPlayer | undefined
6766
7133
  set associated_player(value: LuaPlayer | PlayerIdentification | undefined)
@@ -6922,8 +7289,11 @@ interface CharacterCorpseEntity extends BaseEntity {
6922
7289
  *
6923
7290
  * _Can only be used if this is CharacterCorpse_
6924
7291
  *
7292
+ * **Note**
7293
+ *
7294
+ * The index is not guaranteed to be valid so it should always be checked first if a player with that index actually exists.
7295
+ *
6925
7296
  * {@link https://lua-api.factorio.com/latest/LuaEntity.html#LuaEntity.character_corpse_player_index View documentation}
6926
- * @remarks The index is not guaranteed to be valid so it should always be checked first if a player with that index actually exists.
6927
7297
  */
6928
7298
  character_corpse_player_index: uint
6929
7299
  /**
@@ -7132,8 +7502,11 @@ interface LuaEntityPrototype {
7132
7502
  /**
7133
7503
  * Name of the category of this resource or `nil` when not a resource.
7134
7504
  *
7505
+ * **Note**
7506
+ *
7507
+ * During data stage this property is named "category".
7508
+ *
7135
7509
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.resource_category View documentation}
7136
- * @remarks During data stage this property is named "category".
7137
7510
  */
7138
7511
  readonly resource_category: string | undefined
7139
7512
  /**
@@ -7510,15 +7883,21 @@ interface LuaEntityPrototype {
7510
7883
  /**
7511
7884
  * The crafting categories this entity supports. Only meaningful when this is a crafting-machine or player entity type.
7512
7885
  *
7886
+ * **Note**
7887
+ *
7888
+ * The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
7889
+ *
7513
7890
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.crafting_categories View documentation}
7514
- * @remarks The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
7515
7891
  */
7516
7892
  readonly crafting_categories: Record<string, boolean>
7517
7893
  /**
7518
7894
  * The resource categories this character or mining drill supports, or `nil` if not a character or mining dill.
7519
7895
  *
7896
+ * **Note**
7897
+ *
7898
+ * The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
7899
+ *
7520
7900
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.resource_categories View documentation}
7521
- * @remarks The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
7522
7901
  */
7523
7902
  readonly resource_categories: Record<string, boolean> | undefined
7524
7903
  /**
@@ -7620,8 +7999,11 @@ interface LuaEntityPrototype {
7620
7999
  /**
7621
8000
  * The default speed of this flying robot, rolling stock or unit, `nil` if not one of these.
7622
8001
  *
8002
+ * **Note**
8003
+ *
8004
+ * For rolling stocks, this is their `max_speed`.
8005
+ *
7623
8006
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.speed View documentation}
7624
- * @remarks For rolling stocks, this is their `max_speed`.
7625
8007
  */
7626
8008
  readonly speed: double | undefined
7627
8009
  /**
@@ -7765,8 +8147,11 @@ interface LuaEntityPrototype {
7765
8147
  /**
7766
8148
  * The fluid capacity of this entity or 0 if this entity doesn't support fluids.
7767
8149
  *
8150
+ * **Note**
8151
+ *
8152
+ * Crafting machines will report 0 due to their fluid capacity being what ever a given recipe needs.
8153
+ *
7768
8154
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.fluid_capacity View documentation}
7769
- * @remarks Crafting machines will report 0 due to their fluid capacity being what ever a given recipe needs.
7770
8155
  */
7771
8156
  readonly fluid_capacity: double
7772
8157
  /**
@@ -7988,8 +8373,11 @@ interface LuaEntityPrototype {
7988
8373
  /**
7989
8374
  * If this prototype will attempt to create a ghost of itself on death.
7990
8375
  *
8376
+ * **Note**
8377
+ *
8378
+ * If this is false then a ghost will never be made, if it's true a ghost may be made.
8379
+ *
7991
8380
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.create_ghost_on_death View documentation}
7992
- * @remarks If this is false then a ghost will never be made, if it's true a ghost may be made.
7993
8381
  */
7994
8382
  readonly create_ghost_on_death: boolean
7995
8383
  /**
@@ -8334,8 +8722,11 @@ interface LuaEntityPrototype {
8334
8722
  /**
8335
8723
  * The logistic parameters for this roboport. or `nil`.
8336
8724
  *
8725
+ * **Note**
8726
+ *
8727
+ * Both the `charging_station_shift` and `stationing_offset` vectors are tables with `x` and `y` keys instead of an array.
8728
+ *
8337
8729
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.logistic_parameters View documentation}
8338
- * @remarks Both the `charging_station_shift` and `stationing_offset` vectors are tables with `x` and `y` keys instead of an array.
8339
8730
  */
8340
8731
  readonly logistic_parameters:
8341
8732
  | {
@@ -8579,8 +8970,11 @@ interface BaseEntityPrototype {
8579
8970
  /**
8580
8971
  * Name of the category of this resource or `nil` when not a resource.
8581
8972
  *
8973
+ * **Note**
8974
+ *
8975
+ * During data stage this property is named "category".
8976
+ *
8582
8977
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.resource_category View documentation}
8583
- * @remarks During data stage this property is named "category".
8584
8978
  */
8585
8979
  readonly resource_category: string | undefined
8586
8980
  /**
@@ -8957,15 +9351,21 @@ interface BaseEntityPrototype {
8957
9351
  /**
8958
9352
  * The crafting categories this entity supports. Only meaningful when this is a crafting-machine or player entity type.
8959
9353
  *
9354
+ * **Note**
9355
+ *
9356
+ * The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
9357
+ *
8960
9358
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.crafting_categories View documentation}
8961
- * @remarks The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
8962
9359
  */
8963
9360
  readonly crafting_categories: Record<string, boolean>
8964
9361
  /**
8965
9362
  * The resource categories this character or mining drill supports, or `nil` if not a character or mining dill.
8966
9363
  *
9364
+ * **Note**
9365
+ *
9366
+ * The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
9367
+ *
8967
9368
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.resource_categories View documentation}
8968
- * @remarks The value in the dictionary is meaningless and exists just to allow the dictionary type for easy lookup.
8969
9369
  */
8970
9370
  readonly resource_categories: Record<string, boolean> | undefined
8971
9371
  /**
@@ -9067,8 +9467,11 @@ interface BaseEntityPrototype {
9067
9467
  /**
9068
9468
  * The default speed of this flying robot, rolling stock or unit, `nil` if not one of these.
9069
9469
  *
9470
+ * **Note**
9471
+ *
9472
+ * For rolling stocks, this is their `max_speed`.
9473
+ *
9070
9474
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.speed View documentation}
9071
- * @remarks For rolling stocks, this is their `max_speed`.
9072
9475
  */
9073
9476
  readonly speed: double | undefined
9074
9477
  /**
@@ -9212,8 +9615,11 @@ interface BaseEntityPrototype {
9212
9615
  /**
9213
9616
  * The fluid capacity of this entity or 0 if this entity doesn't support fluids.
9214
9617
  *
9618
+ * **Note**
9619
+ *
9620
+ * Crafting machines will report 0 due to their fluid capacity being what ever a given recipe needs.
9621
+ *
9215
9622
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.fluid_capacity View documentation}
9216
- * @remarks Crafting machines will report 0 due to their fluid capacity being what ever a given recipe needs.
9217
9623
  */
9218
9624
  readonly fluid_capacity: double
9219
9625
  /**
@@ -9435,8 +9841,11 @@ interface BaseEntityPrototype {
9435
9841
  /**
9436
9842
  * If this prototype will attempt to create a ghost of itself on death.
9437
9843
  *
9844
+ * **Note**
9845
+ *
9846
+ * If this is false then a ghost will never be made, if it's true a ghost may be made.
9847
+ *
9438
9848
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.create_ghost_on_death View documentation}
9439
- * @remarks If this is false then a ghost will never be made, if it's true a ghost may be made.
9440
9849
  */
9441
9850
  readonly create_ghost_on_death: boolean
9442
9851
  /**
@@ -9703,8 +10112,11 @@ interface BaseEntityPrototype {
9703
10112
  /**
9704
10113
  * The logistic parameters for this roboport. or `nil`.
9705
10114
  *
10115
+ * **Note**
10116
+ *
10117
+ * Both the `charging_station_shift` and `stationing_offset` vectors are tables with `x` and `y` keys instead of an array.
10118
+ *
9706
10119
  * {@link https://lua-api.factorio.com/latest/LuaEntityPrototype.html#LuaEntityPrototype.logistic_parameters View documentation}
9707
- * @remarks Both the `charging_station_shift` and `stationing_offset` vectors are tables with `x` and `y` keys instead of an array.
9708
10120
  */
9709
10121
  readonly logistic_parameters:
9710
10122
  | {
@@ -10021,8 +10433,11 @@ interface LuaEquipment {
10021
10433
  /**
10022
10434
  * Current shield value of the equipment.
10023
10435
  *
10436
+ * **Note**
10437
+ *
10438
+ * Can't be set higher than {@link LuaEquipment#max_shield LuaEquipment::max_shield}.
10439
+ *
10024
10440
  * {@link https://lua-api.factorio.com/latest/LuaEquipment.html#LuaEquipment.shield View documentation}
10025
- * @remarks Can't be set higher than {@link LuaEquipment#max_shield LuaEquipment::max_shield}.
10026
10441
  */
10027
10442
  shield: double
10028
10443
  /**
@@ -10416,8 +10831,11 @@ interface LuaEquipmentPrototype {
10416
10831
  /**
10417
10832
  * The logistic parameters for this roboport equipment.
10418
10833
  *
10834
+ * **Note**
10835
+ *
10836
+ * Both the `charging_station_shift` and `stationing_offset` vectors are tables with `x` and `y` keys instead of an array.
10837
+ *
10419
10838
  * {@link https://lua-api.factorio.com/latest/LuaEquipmentPrototype.html#LuaEquipmentPrototype.logistic_parameters View documentation}
10420
- * @remarks Both the `charging_station_shift` and `stationing_offset` vectors are tables with `x` and `y` keys instead of an array.
10421
10839
  */
10422
10840
  readonly logistic_parameters: {
10423
10841
  readonly spawn_and_station_height: float
@@ -10665,18 +11083,24 @@ interface LuaFluidBox extends Array<Fluid | undefined> {
10665
11083
  /**
10666
11084
  * Set a fluid box filter.
10667
11085
  *
11086
+ * **Note**
11087
+ *
11088
+ * Some entities cannot have their fluidbox filter set, notably fluid wagons and crafting machines.
11089
+ *
10668
11090
  * {@link https://lua-api.factorio.com/latest/LuaFluidBox.html#LuaFluidBox.set_filter View documentation}
10669
11091
  * @param index The index of the filter to set.
10670
11092
  * @param filter The filter to set. Setting `nil` clears the filter.
10671
11093
  * @returns Whether the filter was set successfully.
10672
- * @remarks Some entities cannot have their fluidbox filter set, notably fluid wagons and crafting machines.
10673
11094
  */
10674
11095
  set_filter(index: uint, filter?: FluidBoxFilterSpec): boolean
10675
11096
  /**
10676
11097
  * Flow through the fluidbox in the last tick. It is the larger of in-flow and out-flow.
10677
11098
  *
11099
+ * **Note**
11100
+ *
11101
+ * Fluid wagons do not track it and will return 0.
11102
+ *
10678
11103
  * {@link https://lua-api.factorio.com/latest/LuaFluidBox.html#LuaFluidBox.get_flow View documentation}
10679
- * @remarks Fluid wagons do not track it and will return 0.
10680
11104
  */
10681
11105
  get_flow(index: uint): double
10682
11106
  /**
@@ -10992,10 +11416,13 @@ interface LuaForce {
10992
11416
  /**
10993
11417
  * Count entities of given type.
10994
11418
  *
11419
+ * **Note**
11420
+ *
11421
+ * This function has O(1) time complexity as entity counts are kept and maintained in the game engine.
11422
+ *
10995
11423
  * {@link https://lua-api.factorio.com/latest/LuaForce.html#LuaForce.get_entity_count View documentation}
10996
11424
  * @param name Prototype name of the entity.
10997
11425
  * @returns Number of entities of given prototype belonging to this force.
10998
- * @remarks This function has O(1) time complexity as entity counts are kept and maintained in the game engine.
10999
11426
  */
11000
11427
  get_entity_count(name: string): uint
11001
11428
  /**
@@ -11262,8 +11689,11 @@ interface LuaForce {
11262
11689
  /**
11263
11690
  * Print text to the chat console of all players on this force.
11264
11691
  *
11692
+ * **Note**
11693
+ *
11694
+ * Messages that are identical to a message sent in the last 60 ticks are not printed again.
11695
+ *
11265
11696
  * {@link https://lua-api.factorio.com/latest/LuaForce.html#LuaForce.print View documentation}
11266
- * @remarks Messages that are identical to a message sent in the last 60 ticks are not printed again.
11267
11697
  */
11268
11698
  print(message: LocalisedString, color?: Color): void
11269
11699
  /**
@@ -11279,11 +11709,13 @@ interface LuaForce {
11279
11709
  * **Raised events:**
11280
11710
  * - {@link OnChartTagAddedEvent on_chart_tag_added}? _instantly_ Raised if the chart tag was successfully added.
11281
11711
  *
11712
+ * **Note**
11713
+ *
11714
+ * The chunk must be charted for a tag to be valid at that location.
11282
11715
  *
11283
11716
  * {@link https://lua-api.factorio.com/latest/LuaForce.html#LuaForce.add_chart_tag View documentation}
11284
11717
  * @param surface Which surface to add the tag to.
11285
11718
  * @param tag The tag to add.
11286
- * @remarks The chunk must be charted for a tag to be valid at that location.
11287
11719
  */
11288
11720
  add_chart_tag(surface: SurfaceIdentification, tag: ChartTagSpec): LuaCustomChartTag | undefined
11289
11721
  /**
@@ -11516,8 +11948,11 @@ interface LuaForce {
11516
11948
  /**
11517
11949
  * Enables some higher-level AI behaviour for this force. When set to `true`, biters belonging to this force will automatically expand into new territories, build new spawners, and form unit groups. By default, this value is `true` for the enemy force and `false` for all others.
11518
11950
  *
11951
+ * **Notes**
11952
+ * - Setting this to `false` does not turn off biters' AI. They will still move around and attack players who come close.
11953
+ * - It is necessary for a force to be AI controllable in order to be able to create unit groups or build bases from scripts.
11954
+ *
11519
11955
  * {@link https://lua-api.factorio.com/latest/LuaForce.html#LuaForce.ai_controllable View documentation}
11520
- * @remarks Setting this to `false` does not turn off biters' AI. They will still move around and attack players who come close.<br>It is necessary for a force to be AI controllable in order to be able to create unit groups or build bases from scripts.
11521
11956
  */
11522
11957
  ai_controllable: boolean
11523
11958
  /**
@@ -11631,8 +12066,11 @@ interface LuaForce {
11631
12066
  *
11632
12067
  * This is primarily useful when you want to do some action against all online players of this force.
11633
12068
  *
12069
+ * **Note**
12070
+ *
12071
+ * This does *not* index using player index. See {@link LuaPlayer#index LuaPlayer::index} on each player instance for the player index.
12072
+ *
11634
12073
  * {@link https://lua-api.factorio.com/latest/LuaForce.html#LuaForce.connected_players View documentation}
11635
- * @remarks This does *not* index using player index. See {@link LuaPlayer#index LuaPlayer::index} on each player instance for the player index.
11636
12074
  */
11637
12075
  readonly connected_players: LuaPlayer[]
11638
12076
  mining_drill_productivity_bonus: double
@@ -11675,8 +12113,11 @@ interface LuaForce {
11675
12113
  *
11676
12114
  * 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. Writing to this when the research queue is disabled will simply set the last research in the table as the current research.
11677
12115
  *
12116
+ * **Note**
12117
+ *
12118
+ * 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.
12119
+ *
11678
12120
  * {@link https://lua-api.factorio.com/latest/LuaForce.html#LuaForce.research_queue View documentation}
11679
- * @remarks 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.
11680
12121
  */
11681
12122
  get research_queue(): LuaTechnology[] | undefined
11682
12123
  set research_queue(value: TechnologyIdentification[] | undefined)
@@ -11764,8 +12205,11 @@ interface LuaGameScript {
11764
12205
  /**
11765
12206
  * Show an in-game message dialog.
11766
12207
  *
12208
+ * **Note**
12209
+ *
12210
+ * Can only be used when the map contains exactly one player.
12211
+ *
11767
12212
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.show_message_dialog View documentation}
11768
- * @remarks Can only be used when the map contains exactly one player.
11769
12213
  */
11770
12214
  show_message_dialog(params: {
11771
12215
  /**
@@ -11798,44 +12242,63 @@ interface LuaGameScript {
11798
12242
  /**
11799
12243
  * Forces a reload of the scenario script from the original scenario location.
11800
12244
  *
12245
+ * **Note**
12246
+ *
12247
+ * This disables the replay if replay is enabled.
12248
+ *
11801
12249
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.reload_script View documentation}
11802
- * @remarks This disables the replay if replay is enabled.
11803
12250
  */
11804
12251
  reload_script(): void
11805
12252
  /**
11806
12253
  * Forces a reload of all mods.
11807
12254
  *
12255
+ * **Notes**
12256
+ * - This will act like saving and loading from the mod(s) perspective.
12257
+ * - This will do nothing if run in multiplayer.
12258
+ * - This disables the replay if replay is enabled.
12259
+ *
11808
12260
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.reload_mods View documentation}
11809
- * @remarks This will act like saving and loading from the mod(s) perspective.<br>This will do nothing if run in multiplayer.<br>This disables the replay if replay is enabled.
11810
12261
  */
11811
12262
  reload_mods(): void
11812
12263
  /**
11813
12264
  * Saves the current configuration of Atlas to a file. This will result in huge file containing all of the game graphics moved to as small space as possible.
11814
12265
  *
12266
+ * **Note**
12267
+ *
12268
+ * Exists mainly for debugging reasons.
12269
+ *
11815
12270
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.save_atlas View documentation}
11816
- * @remarks Exists mainly for debugging reasons.
11817
12271
  */
11818
12272
  save_atlas(): void
11819
12273
  /**
11820
12274
  * Run internal consistency checks. Allegedly prints any errors it finds.
11821
12275
  *
12276
+ * **Note**
12277
+ *
12278
+ * Exists mainly for debugging reasons.
12279
+ *
11822
12280
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.check_consistency View documentation}
11823
- * @remarks Exists mainly for debugging reasons.
11824
12281
  */
11825
12282
  check_consistency(): void
11826
12283
  /**
11827
12284
  * Regenerate autoplacement of some entities on all surfaces. This can be used to autoplace newly-added entities.
11828
12285
  *
12286
+ * **Note**
12287
+ *
12288
+ * All specified entity prototypes must be autoplacable.
12289
+ *
11829
12290
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.regenerate_entity View documentation}
11830
12291
  * @param entities Prototype names of entity or entities to autoplace.
11831
- * @remarks All specified entity prototypes must be autoplacable.
11832
12292
  */
11833
12293
  regenerate_entity(entities: string | readonly string[]): void
11834
12294
  /**
11835
12295
  * Take a screenshot of the game and save it to the `script-output` folder, located in the game's {@linkplain https://wiki.factorio.com/User_data_directory user data directory}. The name of the image file can be specified via the `path` parameter.
11836
12296
  *
12297
+ * **Note**
12298
+ *
12299
+ * If Factorio is running headless, this function will do nothing.
12300
+ *
11837
12301
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.take_screenshot View documentation}
11838
- * @remarks If Factorio is running headless, this function will do nothing.
11839
12302
  */
11840
12303
  take_screenshot(params: {
11841
12304
  /**
@@ -11995,11 +12458,13 @@ interface LuaGameScript {
11995
12458
  * **Raised events:**
11996
12459
  * - {@link OnForceCreatedEvent on_force_created} _instantly_
11997
12460
  *
12461
+ * **Notes**
12462
+ * - The game currently supports a maximum of 64 forces, including the three built-in forces. This means that a maximum of 61 new forces may be created.
12463
+ * - Force names must be unique.
11998
12464
  *
11999
12465
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.create_force View documentation}
12000
12466
  * @param force Name of the new force
12001
12467
  * @returns The force that was just created
12002
- * @remarks The game currently supports a maximum of 64 forces, including the three built-in forces. This means that a maximum of 61 new forces may be created.<br>Force names must be unique.
12003
12468
  */
12004
12469
  create_force(force: string): LuaForce
12005
12470
  /**
@@ -12009,11 +12474,13 @@ interface LuaGameScript {
12009
12474
  * - {@link OnForcesMergingEvent on_forces_merging} _future_tick_
12010
12475
  * - {@link OnForcesMergedEvent on_forces_merged} _future_tick_
12011
12476
  *
12477
+ * **Notes**
12478
+ * - The three built-in forces -- player, enemy and neutral -- can't be destroyed. I.e. they can't be used as the source argument to this function.
12479
+ * - The source force is not removed until the end of the current tick, or if called during the {@link OnForcesMergingEvent on_forces_merging} or {@link OnForcesMergedEvent on_forces_merged} event, the end of the next tick.
12012
12480
  *
12013
12481
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.merge_forces View documentation}
12014
12482
  * @param source The force to remove.
12015
12483
  * @param destination The force to reassign all entities to.
12016
- * @remarks The three built-in forces -- player, enemy and neutral -- can't be destroyed. I.e. they can't be used as the source argument to this function.<br>The source force is not removed until the end of the current tick, or if called during the {@link OnForcesMergingEvent on_forces_merging} or {@link OnForcesMergedEvent on_forces_merged} event, the end of the next tick.
12017
12484
  */
12018
12485
  merge_forces(source: ForceIdentification, destination: ForceIdentification): void
12019
12486
  /**
@@ -12022,12 +12489,14 @@ interface LuaGameScript {
12022
12489
  * **Raised events:**
12023
12490
  * - {@link OnSurfaceCreatedEvent on_surface_created} _instantly_
12024
12491
  *
12492
+ * **Notes**
12493
+ * - The game currently supports a maximum of 4,294,967,295 surfaces, including the default surface.
12494
+ * - Surface names must be unique.
12025
12495
  *
12026
12496
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.create_surface View documentation}
12027
12497
  * @param name Name of the new surface.
12028
12498
  * @param settings Map generation settings.
12029
12499
  * @returns The surface that was just created.
12030
- * @remarks The game currently supports a maximum of 4,294,967,295 surfaces, including the default surface.<br>Surface names must be unique.
12031
12500
  */
12032
12501
  create_surface(name: string, settings?: MapGenSettings): LuaSurface
12033
12502
  /**
@@ -12040,9 +12509,12 @@ interface LuaGameScript {
12040
12509
  /**
12041
12510
  * Instruct the game to perform an auto-save.
12042
12511
  *
12512
+ * **Note**
12513
+ *
12514
+ * Only the server will save in multiplayer. In single player a standard auto-save is triggered.
12515
+ *
12043
12516
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.auto_save View documentation}
12044
12517
  * @param name The autosave name if any. Saves will be named _autosave-*name* when provided.
12045
- * @remarks Only the server will save in multiplayer. In single player a standard auto-save is triggered.
12046
12518
  */
12047
12519
  auto_save(name?: string): void
12048
12520
  /**
@@ -12078,22 +12550,31 @@ interface LuaGameScript {
12078
12550
  /**
12079
12551
  * Print text to the chat console all players.
12080
12552
  *
12553
+ * **Note**
12554
+ *
12555
+ * Messages that are identical to a message sent in the last 60 ticks are not printed again.
12556
+ *
12081
12557
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.print View documentation}
12082
- * @remarks Messages that are identical to a message sent in the last 60 ticks are not printed again.
12083
12558
  */
12084
12559
  print(message: LocalisedString, color?: Color): void
12085
12560
  /**
12086
12561
  * Creates a deterministic standalone random generator with the given seed or if a seed is not provided the initial map seed is used.
12087
12562
  *
12563
+ * **Note**
12564
+ *
12565
+ * *Make sure* you actually want to use this over math.random(...) as this provides entirely different functionality over math.random(...).
12566
+ *
12088
12567
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.create_random_generator View documentation}
12089
- * @remarks *Make sure* you actually want to use this over math.random(...) as this provides entirely different functionality over math.random(...).
12090
12568
  */
12091
12569
  create_random_generator(seed?: uint): LuaRandomGenerator
12092
12570
  /**
12093
12571
  * Goes over all items, entities, tiles, recipes, technologies among other things and logs if the locale is incorrect.
12094
12572
  *
12573
+ * **Note**
12574
+ *
12575
+ * Also prints true/false if called from the console.
12576
+ *
12095
12577
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.check_prototype_translations View documentation}
12096
- * @remarks Also prints true/false if called from the console.
12097
12578
  */
12098
12579
  check_prototype_translations(): void
12099
12580
  /**
@@ -12221,9 +12702,12 @@ interface LuaGameScript {
12221
12702
  /**
12222
12703
  * Gets the number of entities that are active (updated each tick).
12223
12704
  *
12705
+ * **Note**
12706
+ *
12707
+ * This is very expensive to determine.
12708
+ *
12224
12709
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.get_active_entities_count View documentation}
12225
12710
  * @param surface If give, only the entities active on this surface are counted.
12226
- * @remarks This is very expensive to determine.
12227
12711
  */
12228
12712
  get_active_entities_count(surface?: SurfaceIdentification): uint
12229
12713
  /**
@@ -12251,25 +12735,34 @@ interface LuaGameScript {
12251
12735
  /**
12252
12736
  * Gets the given player or returns `nil` if no player is found.
12253
12737
  *
12738
+ * **Note**
12739
+ *
12740
+ * This is a shortcut for game.players[...]
12741
+ *
12254
12742
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.get_player View documentation}
12255
12743
  * @param player The player index or name.
12256
- * @remarks This is a shortcut for game.players[...]
12257
12744
  */
12258
12745
  get_player(index: PlayerIndex | string): LuaPlayer | undefined
12259
12746
  /**
12260
12747
  * Gets the given surface or returns `nil` if no surface is found.
12261
12748
  *
12749
+ * **Note**
12750
+ *
12751
+ * This is a shortcut for game.surfaces[...]
12752
+ *
12262
12753
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.get_surface View documentation}
12263
12754
  * @param surface The surface index or name.
12264
- * @remarks This is a shortcut for game.surfaces[...]
12265
12755
  */
12266
12756
  get_surface(index: SurfaceIndex | string): LuaSurface | undefined
12267
12757
  /**
12268
12758
  * Creates a {@link LuaProfiler}, which is used for measuring script performance.
12269
12759
  *
12760
+ * **Note**
12761
+ *
12762
+ * LuaProfiler cannot be serialized.
12763
+ *
12270
12764
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.create_profiler View documentation}
12271
12765
  * @param stopped Create the timer stopped
12272
- * @remarks LuaProfiler cannot be serialized.
12273
12766
  */
12274
12767
  create_profiler(stopped?: boolean): LuaProfiler
12275
12768
  /**
@@ -12409,18 +12902,24 @@ interface LuaGameScript {
12409
12902
  /**
12410
12903
  * Creates an inventory that is not owned by any game object. It can be resized later with {@link LuaInventory#resize LuaInventory::resize}.
12411
12904
  *
12905
+ * **Note**
12906
+ *
12907
+ * Make sure to destroy it when you are done with it using {@link LuaInventory#destroy LuaInventory::destroy}.
12908
+ *
12412
12909
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.create_inventory View documentation}
12413
12910
  * @param size The number of slots the inventory initially has.
12414
- * @remarks Make sure to destroy it when you are done with it using {@link LuaInventory#destroy LuaInventory::destroy}.
12415
12911
  */
12416
12912
  create_inventory(size: uint16): LuaInventory
12417
12913
  /**
12418
12914
  * Gets the inventories created through {@link LuaGameScript#create_inventory LuaGameScript::create_inventory}
12419
12915
  *
12916
+ * **Note**
12917
+ *
12918
+ * Inventories created through console commands will be owned by `"core"`.
12919
+ *
12420
12920
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.get_script_inventories View documentation}
12421
12921
  * @param mod The mod who's inventories to get. If not provided all inventories are returned.
12422
12922
  * @returns A mapping of mod name to array of inventories owned by that mod.
12423
- * @remarks Inventories created through console commands will be owned by `"core"`.
12424
12923
  */
12425
12924
  get_script_inventories(mod?: string): Record<string, LuaInventory[]>
12426
12925
  /**
@@ -12462,8 +12961,11 @@ interface LuaGameScript {
12462
12961
  /**
12463
12962
  * The currently active set of map settings. Even though this property is marked as read-only, the members of the dictionary that is returned can be modified mid-game.
12464
12963
  *
12964
+ * **Note**
12965
+ *
12966
+ * This does not contain difficulty settings, use {@link LuaGameScript#difficulty_settings LuaGameScript::difficulty_settings} instead.
12967
+ *
12465
12968
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.map_settings View documentation}
12466
- * @remarks This does not contain difficulty settings, use {@link LuaGameScript#difficulty_settings LuaGameScript::difficulty_settings} instead.
12467
12969
  */
12468
12970
  readonly map_settings: MapSettings
12469
12971
  /**
@@ -12666,8 +13168,11 @@ interface LuaGameScript {
12666
13168
  /**
12667
13169
  * A dictionary containing every MapGenPreset indexed by `name`.
12668
13170
  *
13171
+ * **Note**
13172
+ *
13173
+ * A MapGenPreset is an exact copy of the prototype table provided from the data stage.
13174
+ *
12669
13175
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.map_gen_presets View documentation}
12670
- * @remarks A MapGenPreset is an exact copy of the prototype table provided from the data stage.
12671
13176
  */
12672
13177
  readonly map_gen_presets: LuaCustomTable<string, MapGenPreset>
12673
13178
  /**
@@ -12685,8 +13190,11 @@ interface LuaGameScript {
12685
13190
  /**
12686
13191
  * The number of ticks since this game was 'created'. A game is 'created' either by using "new game" or "new game from scenario".
12687
13192
  *
13193
+ * **Notes**
13194
+ * - This differs over {@link LuaGameScript#tick LuaGameScript::tick} in that making a game from a scenario always starts with ticks_played value at 0 even if the scenario has its own level data where the {@link LuaGameScript#tick LuaGameScript::tick} is > 0.
13195
+ * - This value has no relation with {@link LuaGameScript#tick LuaGameScript::tick} and can be completely different values.
13196
+ *
12688
13197
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.ticks_played View documentation}
12689
- * @remarks This differs over {@link LuaGameScript#tick LuaGameScript::tick} in that making a game from a scenario always starts with ticks_played value at 0 even if the scenario has its own level data where the {@link LuaGameScript#tick LuaGameScript::tick} is > 0.<br>This value has no relation with {@link LuaGameScript#tick LuaGameScript::tick} and can be completely different values.
12690
13198
  */
12691
13199
  readonly ticks_played: uint
12692
13200
  /**
@@ -12716,8 +13224,11 @@ interface LuaGameScript {
12716
13224
  /**
12717
13225
  * Speed to update the map at. 1.0 is normal speed -- 60 UPS.
12718
13226
  *
13227
+ * **Note**
13228
+ *
13229
+ * Minimum value is 0.01.
13230
+ *
12719
13231
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.speed View documentation}
12720
- * @remarks Minimum value is 0.01.
12721
13232
  */
12722
13233
  speed: float
12723
13234
  /**
@@ -12744,8 +13255,11 @@ interface LuaGameScript {
12744
13255
  *
12745
13256
  * This is primarily useful when you want to do some action against all online players.
12746
13257
  *
13258
+ * **Note**
13259
+ *
13260
+ * This does *not* index using player index. See {@link LuaPlayer#index LuaPlayer::index} on each player instance for the player index.
13261
+ *
12747
13262
  * {@link https://lua-api.factorio.com/latest/LuaGameScript.html#LuaGameScript.connected_players View documentation}
12748
- * @remarks This does *not* index using player index. See {@link LuaPlayer#index LuaPlayer::index} on each player instance for the player index.
12749
13263
  */
12750
13264
  readonly connected_players: LuaPlayer[]
12751
13265
  readonly permissions: LuaPermissionGroups
@@ -12816,8 +13330,11 @@ interface LuaGenericOnOffControlBehavior extends LuaControlBehavior {
12816
13330
  /**
12817
13331
  * The circuit condition.
12818
13332
  *
13333
+ * **Note**
13334
+ *
13335
+ * `condition` may be `nil` in order to clear the circuit condition.
13336
+ *
12819
13337
  * {@link https://lua-api.factorio.com/latest/LuaGenericOnOffControlBehavior.html#LuaGenericOnOffControlBehavior.circuit_condition View documentation}
12820
- * @remarks `condition` may be `nil` in order to clear the circuit condition.
12821
13338
  * @example Tell an entity to be active (e.g. a lamp to be lit) when it receives a circuit signal of more than 4 chain signals.
12822
13339
  *
12823
13340
  * ```
@@ -12830,8 +13347,11 @@ interface LuaGenericOnOffControlBehavior extends LuaControlBehavior {
12830
13347
  /**
12831
13348
  * The logistic condition.
12832
13349
  *
13350
+ * **Note**
13351
+ *
13352
+ * `condition` may be `nil` in order to clear the logistic condition.
13353
+ *
12833
13354
  * {@link https://lua-api.factorio.com/latest/LuaGenericOnOffControlBehavior.html#LuaGenericOnOffControlBehavior.logistic_condition View documentation}
12834
- * @remarks `condition` may be `nil` in order to clear the logistic condition.
12835
13355
  * @example Tell an entity to be active (e.g. a lamp to be lit) when the logistics network it's connected to has more than four chain signals.
12836
13356
  *
12837
13357
  * ```
@@ -12885,15 +13405,21 @@ interface LuaGroup {
12885
13405
  /**
12886
13406
  * Subgroups of this group.
12887
13407
  *
13408
+ * **Note**
13409
+ *
13410
+ * Can only be used on groups, not on subgroups.
13411
+ *
12888
13412
  * {@link https://lua-api.factorio.com/latest/LuaGroup.html#LuaGroup.subgroups View documentation}
12889
- * @remarks Can only be used on groups, not on subgroups.
12890
13413
  */
12891
13414
  readonly subgroups: LuaGroup[]
12892
13415
  /**
12893
13416
  * The additional order value used in recipe ordering.
12894
13417
  *
13418
+ * **Note**
13419
+ *
13420
+ * Can only be used on groups, not on subgroups.
13421
+ *
12895
13422
  * {@link https://lua-api.factorio.com/latest/LuaGroup.html#LuaGroup.order_in_recipe View documentation}
12896
- * @remarks Can only be used on groups, not on subgroups.
12897
13423
  */
12898
13424
  readonly order_in_recipe: string
12899
13425
  /**
@@ -12919,9 +13445,12 @@ interface LuaGroup {
12919
13445
  /**
12920
13446
  * The root of the GUI. This type houses the root elements, `top`, `left`, `center`, `goal`, and `screen`, to which other elements can be added to be displayed on screen.
12921
13447
  *
13448
+ * **Note**
13449
+ *
13450
+ * Every player can have a different GUI state.
13451
+ *
12922
13452
  * {@link https://lua-api.factorio.com/latest/LuaGui.html View documentation}
12923
13453
  * @noSelf
12924
- * @remarks Every player can have a different GUI state.
12925
13454
  */
12926
13455
  interface LuaGui {
12927
13456
  /**
@@ -13573,8 +14102,11 @@ interface BaseGuiElement {
13573
14102
  /**
13574
14103
  * Remove this element, along with its children. Any {@link LuaGuiElement} objects referring to the destroyed elements become invalid after this operation.
13575
14104
  *
14105
+ * **Note**
14106
+ *
14107
+ * The top-level GUI elements - {@link LuaGui#top LuaGui::top}, {@link LuaGui#left LuaGui::left}, {@link LuaGui#center LuaGui::center} and {@link LuaGui#screen LuaGui::screen} - can't be destroyed.
14108
+ *
13576
14109
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.destroy View documentation}
13577
- * @remarks The top-level GUI elements - {@link LuaGui#top LuaGui::top}, {@link LuaGui#left LuaGui::left}, {@link LuaGui#center LuaGui::center} and {@link LuaGui#screen LuaGui::screen} - can't be destroyed.
13578
14110
  * @example
13579
14111
  *
13580
14112
  * ```
@@ -13585,15 +14117,21 @@ interface BaseGuiElement {
13585
14117
  /**
13586
14118
  * The mod that owns this Gui element or `nil` if it's owned by the scenario script.
13587
14119
  *
14120
+ * **Note**
14121
+ *
14122
+ * This has a not-super-expensive, but non-free cost to get.
14123
+ *
13588
14124
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.get_mod View documentation}
13589
- * @remarks This has a not-super-expensive, but non-free cost to get.
13590
14125
  */
13591
14126
  get_mod(): string | undefined
13592
14127
  /**
13593
14128
  * Gets the index that this element has in its parent element.
13594
14129
  *
14130
+ * **Note**
14131
+ *
14132
+ * This iterates through the children of the parent of this element, meaning this has a non-free cost to get, but is faster than doing the equivalent in Lua.
14133
+ *
13595
14134
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.get_index_in_parent View documentation}
13596
- * @remarks This iterates through the children of the parent of this element, meaning this has a non-free cost to get, but is faster than doing the equivalent in Lua.
13597
14135
  */
13598
14136
  get_index_in_parent(): uint
13599
14137
  /**
@@ -13613,8 +14151,11 @@ interface BaseGuiElement {
13613
14151
  /**
13614
14152
  * Moves this GUI element to the "front" so it will draw over other elements.
13615
14153
  *
14154
+ * **Note**
14155
+ *
14156
+ * Only works for elements in {@link LuaGui#screen LuaGui::screen}
14157
+ *
13616
14158
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.bring_to_front View documentation}
13617
- * @remarks Only works for elements in {@link LuaGui#screen LuaGui::screen}
13618
14159
  */
13619
14160
  bring_to_front(): void
13620
14161
  /**
@@ -13649,8 +14190,11 @@ interface BaseGuiElement {
13649
14190
  /**
13650
14191
  * The text displayed on this element. For frames, this is the "heading". For other elements, like buttons or labels, this is the content.
13651
14192
  *
14193
+ * **Note**
14194
+ *
14195
+ * Whilst this attribute may be used on all elements without producing an error, it doesn't make sense for tables and flows as they won't display it.
14196
+ *
13652
14197
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.caption View documentation}
13653
- * @remarks Whilst this attribute may be used on all elements without producing an error, it doesn't make sense for tables and flows as they won't display it.
13654
14198
  */
13655
14199
  caption: LocalisedString
13656
14200
  /**
@@ -13756,8 +14300,11 @@ interface ChooseElemButtonGuiElementMembers extends BaseGuiElement {
13756
14300
  *
13757
14301
  * _Can only be used if this is choose-elem-button_
13758
14302
  *
14303
+ * **Note**
14304
+ *
14305
+ * The `"signal"` type operates with {@link SignalID}, while all other types use strings.
14306
+ *
13759
14307
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.elem_value View documentation}
13760
- * @remarks The `"signal"` type operates with {@link SignalID}, while all other types use strings.
13761
14308
  */
13762
14309
  elem_value: (this["elem_type"] extends "signal" ? SignalID : string) | undefined
13763
14310
  /**
@@ -13765,8 +14312,11 @@ interface ChooseElemButtonGuiElementMembers extends BaseGuiElement {
13765
14312
  *
13766
14313
  * _Can only be used if this is choose-elem-button_
13767
14314
  *
14315
+ * **Note**
14316
+ *
14317
+ * Writing to this field does not change or clear the currently selected element.
14318
+ *
13768
14319
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.elem_filters View documentation}
13769
- * @remarks Writing to this field does not change or clear the currently selected element.
13770
14320
  * @example This will configure a choose-elem-button of type `"entity"` to only show items of type `"furnace"`.
13771
14321
  *
13772
14322
  * ```
@@ -13870,8 +14420,11 @@ interface EmptyWidgetGuiElementMembers extends BaseGuiElement {
13870
14420
  *
13871
14421
  * _Can only be used if this is flow, frame, label, table or empty-widget_
13872
14422
  *
14423
+ * **Note**
14424
+ *
14425
+ * Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
14426
+ *
13873
14427
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.drag_target View documentation}
13874
- * @remarks Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
13875
14428
  * @example This creates a frame that contains a dragging handle which can move the frame.
13876
14429
  *
13877
14430
  * ```
@@ -14122,9 +14675,12 @@ interface TabbedPaneGuiElementMembers extends BaseGuiElement {
14122
14675
  *
14123
14676
  * _Can only be used if this is tabbed-pane_
14124
14677
  *
14678
+ * **Notes**
14679
+ * - Removing a tab does not destroy the tab or the tab contents. It just removes them from the view.
14680
+ * - When removing tabs, {@link LuaGuiElement#selected_tab_index LuaGuiElement::selected_tab_index} needs to be manually updated.
14681
+ *
14125
14682
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.remove_tab View documentation}
14126
14683
  * @param tab The tab to remove. If not given, it removes all tabs.
14127
- * @remarks Removing a tab does not destroy the tab or the tab contents. It just removes them from the view.<br>When removing tabs, {@link LuaGuiElement#selected_tab_index LuaGuiElement::selected_tab_index} needs to be manually updated.
14128
14684
  */
14129
14685
  remove_tab(tab: LuaGuiElement): void
14130
14686
  /**
@@ -14352,8 +14908,11 @@ interface FlowGuiElementMembers extends BaseGuiElement {
14352
14908
  *
14353
14909
  * _Can only be used if this is flow, frame, label, table or empty-widget_
14354
14910
  *
14911
+ * **Note**
14912
+ *
14913
+ * Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
14914
+ *
14355
14915
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.drag_target View documentation}
14356
- * @remarks Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
14357
14916
  * @example This creates a frame that contains a dragging handle which can move the frame.
14358
14917
  *
14359
14918
  * ```
@@ -14410,8 +14969,11 @@ interface FrameGuiElementMembers extends BaseGuiElement {
14410
14969
  *
14411
14970
  * _Can only be used if this is flow, frame, label, table or empty-widget_
14412
14971
  *
14972
+ * **Note**
14973
+ *
14974
+ * Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
14975
+ *
14413
14976
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.drag_target View documentation}
14414
- * @remarks Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
14415
14977
  * @example This creates a frame that contains a dragging handle which can move the frame.
14416
14978
  *
14417
14979
  * ```
@@ -14438,8 +15000,11 @@ interface LabelGuiElementMembers extends BaseGuiElement {
14438
15000
  *
14439
15001
  * _Can only be used if this is flow, frame, label, table or empty-widget_
14440
15002
  *
15003
+ * **Note**
15004
+ *
15005
+ * Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
15006
+ *
14441
15007
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.drag_target View documentation}
14442
- * @remarks Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
14443
15008
  * @example This creates a frame that contains a dragging handle which can move the frame.
14444
15009
  *
14445
15010
  * ```
@@ -14586,8 +15151,11 @@ interface SliderGuiElementMembers extends BaseGuiElement {
14586
15151
  /**
14587
15152
  * Sets this sliders minimum and maximum values.
14588
15153
  *
15154
+ * **Note**
15155
+ *
15156
+ * The minimum can't be >= the maximum.
15157
+ *
14589
15158
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.set_slider_minimum_maximum View documentation}
14590
- * @remarks The minimum can't be >= the maximum.
14591
15159
  */
14592
15160
  set_slider_minimum_maximum(minimum: double, maximum: double): void
14593
15161
  /**
@@ -14611,8 +15179,11 @@ interface SliderGuiElementMembers extends BaseGuiElement {
14611
15179
  /**
14612
15180
  * Sets the minimum distance this slider can move.
14613
15181
  *
15182
+ * **Note**
15183
+ *
15184
+ * The minimum distance can't be > (max - min).
15185
+ *
14614
15186
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.set_slider_value_step View documentation}
14615
- * @remarks The minimum distance can't be > (max - min).
14616
15187
  */
14617
15188
  set_slider_value_step(value: double): void
14618
15189
  /**
@@ -14674,8 +15245,11 @@ interface SwitchGuiElementMembers extends BaseGuiElement {
14674
15245
  *
14675
15246
  * _Can only be used if this is switch_
14676
15247
  *
15248
+ * **Note**
15249
+ *
15250
+ * If {@link LuaGuiElement#allow_none_state LuaGuiElement::allow_none_state} is false this can't be set to `"none"`.
15251
+ *
14677
15252
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.switch_state View documentation}
14678
- * @remarks If {@link LuaGuiElement#allow_none_state LuaGuiElement::allow_none_state} is false this can't be set to `"none"`.
14679
15253
  */
14680
15254
  switch_state: string
14681
15255
  /**
@@ -14683,8 +15257,11 @@ interface SwitchGuiElementMembers extends BaseGuiElement {
14683
15257
  *
14684
15258
  * _Can only be used if this is switch_
14685
15259
  *
15260
+ * **Note**
15261
+ *
15262
+ * This can't be set to false if the current switch_state is 'none'.
15263
+ *
14686
15264
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.allow_none_state View documentation}
14687
- * @remarks This can't be set to false if the current switch_state is 'none'.
14688
15265
  */
14689
15266
  allow_none_state: boolean
14690
15267
  /**
@@ -14794,8 +15371,11 @@ interface TableGuiElementMembers extends BaseGuiElement {
14794
15371
  *
14795
15372
  * _Can only be used if this is flow, frame, label, table or empty-widget_
14796
15373
  *
15374
+ * **Note**
15375
+ *
15376
+ * Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
15377
+ *
14797
15378
  * {@link https://lua-api.factorio.com/latest/LuaGuiElement.html#LuaGuiElement.drag_target View documentation}
14798
- * @remarks Only top-level elements in {@link LuaGui#screen LuaGui::screen} can be `drag_target`s.
14799
15379
  * @example This creates a frame that contains a dragging handle which can move the frame.
14800
15380
  *
14801
15381
  * ```
@@ -15163,23 +15743,32 @@ interface LuaInventory extends ReadonlyArray<LuaItemStack> {
15163
15743
  /**
15164
15744
  * Does this inventory support a bar? Bar is the draggable red thing, found for example on chests, that limits the portion of the inventory that may be manipulated by machines.
15165
15745
  *
15746
+ * **Note**
15747
+ *
15748
+ * "Supporting a bar" doesn't mean that the bar is set to some nontrivial value. Supporting a bar means the inventory supports having this limit at all. The character's inventory is an example of an inventory without a bar; the wooden chest's inventory is an example of one with a bar.
15749
+ *
15166
15750
  * {@link https://lua-api.factorio.com/latest/LuaInventory.html#LuaInventory.supports_bar View documentation}
15167
- * @remarks "Supporting a bar" doesn't mean that the bar is set to some nontrivial value. Supporting a bar means the inventory supports having this limit at all. The character's inventory is an example of an inventory without a bar; the wooden chest's inventory is an example of one with a bar.
15168
15751
  */
15169
15752
  supports_bar(): boolean
15170
15753
  /**
15171
15754
  * Get the current bar. This is the index at which the red area starts.
15172
15755
  *
15756
+ * **Note**
15757
+ *
15758
+ * Only useable if this inventory supports having a bar.
15759
+ *
15173
15760
  * {@link https://lua-api.factorio.com/latest/LuaInventory.html#LuaInventory.get_bar View documentation}
15174
- * @remarks Only useable if this inventory supports having a bar.
15175
15761
  */
15176
15762
  get_bar(): uint
15177
15763
  /**
15178
15764
  * Set the current bar.
15179
15765
  *
15766
+ * **Note**
15767
+ *
15768
+ * Only useable if this inventory supports having a bar.
15769
+ *
15180
15770
  * {@link https://lua-api.factorio.com/latest/LuaInventory.html#LuaInventory.set_bar View documentation}
15181
15771
  * @param bar The new limit. Omitting this parameter will clear the limit.
15182
- * @remarks Only useable if this inventory supports having a bar.
15183
15772
  */
15184
15773
  set_bar(bar?: uint): void
15185
15774
  /**
@@ -15213,11 +15802,14 @@ interface LuaInventory extends ReadonlyArray<LuaItemStack> {
15213
15802
  /**
15214
15803
  * Sets the filter for the given item stack index.
15215
15804
  *
15805
+ * **Note**
15806
+ *
15807
+ * Some inventory slots don't allow some filters (gun ammo can't be filtered for non-ammo).
15808
+ *
15216
15809
  * {@link https://lua-api.factorio.com/latest/LuaInventory.html#LuaInventory.set_filter View documentation}
15217
15810
  * @param index The item stack index
15218
15811
  * @param filter The new filter or nil to erase the filter
15219
15812
  * @returns If the filter was allowed to be set.
15220
- * @remarks Some inventory slots don't allow some filters (gun ammo can't be filtered for non-ammo).
15221
15813
  */
15222
15814
  set_filter(index: uint, filter: string | undefined): boolean
15223
15815
  /**
@@ -15248,9 +15840,13 @@ interface LuaInventory extends ReadonlyArray<LuaItemStack> {
15248
15840
  /**
15249
15841
  * Gets the number of the given item that can be inserted into this inventory.
15250
15842
  *
15843
+ * **Notes**
15844
+ * - This is a "best guess" number; things like assembling machine filtered slots, module slots, items with durability, and items with mixed health will cause the result to be inaccurate.
15845
+ * - The main use for this is in checking how many of a basic item can fit into a basic inventory.
15846
+ * - This accounts for the 'bar' on the inventory.
15847
+ *
15251
15848
  * {@link https://lua-api.factorio.com/latest/LuaInventory.html#LuaInventory.get_insertable_count View documentation}
15252
15849
  * @param item The item to check.
15253
- * @remarks This is a "best guess" number; things like assembling machine filtered slots, module slots, items with durability, and items with mixed health will cause the result to be inaccurate.<br>The main use for this is in checking how many of a basic item can fit into a basic inventory.<br>This accounts for the 'bar' on the inventory.
15254
15850
  */
15255
15851
  get_insertable_count(item: string): void
15256
15852
  /**
@@ -15266,17 +15862,22 @@ interface LuaInventory extends ReadonlyArray<LuaItemStack> {
15266
15862
  * - {@link OnPreScriptInventoryResizedEvent on_pre_script_inventory_resized} _instantly_
15267
15863
  * - {@link OnScriptInventoryResizedEvent on_script_inventory_resized} _instantly_
15268
15864
  *
15865
+ * **Notes**
15866
+ * - Items in slots beyond the new capacity are deleted.
15867
+ * - Only inventories created by {@link LuaGameScript#create_inventory LuaGameScript::create_inventory} can be resized.
15269
15868
  *
15270
15869
  * {@link https://lua-api.factorio.com/latest/LuaInventory.html#LuaInventory.resize View documentation}
15271
15870
  * @param size New size of a inventory
15272
- * @remarks Items in slots beyond the new capacity are deleted.<br>Only inventories created by {@link LuaGameScript#create_inventory LuaGameScript::create_inventory} can be resized.
15273
15871
  */
15274
15872
  resize(size: uint16): void
15275
15873
  /**
15276
15874
  * Destroys this inventory.
15277
15875
  *
15876
+ * **Note**
15877
+ *
15878
+ * Only inventories created by {@link LuaGameScript#create_inventory LuaGameScript::create_inventory} can be destroyed this way.
15879
+ *
15278
15880
  * {@link https://lua-api.factorio.com/latest/LuaInventory.html#LuaInventory.destroy View documentation}
15279
- * @remarks Only inventories created by {@link LuaGameScript#create_inventory LuaGameScript::create_inventory} can be destroyed this way.
15280
15881
  */
15281
15882
  destroy(): void
15282
15883
  /**
@@ -15838,8 +16439,11 @@ interface LuaItemPrototype {
15838
16439
  *
15839
16440
  * _Can only be used if this is SelectionTool_
15840
16441
  *
16442
+ * **Note**
16443
+ *
16444
+ * The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
16445
+ *
15841
16446
  * {@link https://lua-api.factorio.com/latest/LuaItemPrototype.html#LuaItemPrototype.entity_type_filters View documentation}
15842
- * @remarks The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
15843
16447
  */
15844
16448
  readonly entity_type_filters: Record<string, boolean>
15845
16449
  /**
@@ -15847,8 +16451,11 @@ interface LuaItemPrototype {
15847
16451
  *
15848
16452
  * _Can only be used if this is SelectionTool_
15849
16453
  *
16454
+ * **Note**
16455
+ *
16456
+ * The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
16457
+ *
15850
16458
  * {@link https://lua-api.factorio.com/latest/LuaItemPrototype.html#LuaItemPrototype.alt_entity_type_filters View documentation}
15851
- * @remarks The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
15852
16459
  */
15853
16460
  readonly alt_entity_type_filters: Record<string, boolean>
15854
16461
  /**
@@ -15856,8 +16463,11 @@ interface LuaItemPrototype {
15856
16463
  *
15857
16464
  * _Can only be used if this is SelectionTool_
15858
16465
  *
16466
+ * **Note**
16467
+ *
16468
+ * The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
16469
+ *
15859
16470
  * {@link https://lua-api.factorio.com/latest/LuaItemPrototype.html#LuaItemPrototype.reverse_entity_type_filters View documentation}
15860
- * @remarks The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
15861
16471
  */
15862
16472
  readonly reverse_entity_type_filters: Record<string, boolean>
15863
16473
  /**
@@ -16464,8 +17074,11 @@ interface SelectionToolItemPrototype extends BaseItemPrototype {
16464
17074
  *
16465
17075
  * _Can only be used if this is SelectionTool_
16466
17076
  *
17077
+ * **Note**
17078
+ *
17079
+ * The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
17080
+ *
16467
17081
  * {@link https://lua-api.factorio.com/latest/LuaItemPrototype.html#LuaItemPrototype.entity_type_filters View documentation}
16468
- * @remarks The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
16469
17082
  */
16470
17083
  readonly entity_type_filters: Record<string, boolean>
16471
17084
  /**
@@ -16473,8 +17086,11 @@ interface SelectionToolItemPrototype extends BaseItemPrototype {
16473
17086
  *
16474
17087
  * _Can only be used if this is SelectionTool_
16475
17088
  *
17089
+ * **Note**
17090
+ *
17091
+ * The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
17092
+ *
16476
17093
  * {@link https://lua-api.factorio.com/latest/LuaItemPrototype.html#LuaItemPrototype.alt_entity_type_filters View documentation}
16477
- * @remarks The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
16478
17094
  */
16479
17095
  readonly alt_entity_type_filters: Record<string, boolean>
16480
17096
  /**
@@ -16482,8 +17098,11 @@ interface SelectionToolItemPrototype extends BaseItemPrototype {
16482
17098
  *
16483
17099
  * _Can only be used if this is SelectionTool_
16484
17100
  *
17101
+ * **Note**
17102
+ *
17103
+ * The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
17104
+ *
16485
17105
  * {@link https://lua-api.factorio.com/latest/LuaItemPrototype.html#LuaItemPrototype.reverse_entity_type_filters View documentation}
16486
- * @remarks The boolean value is meaningless and is used to allow easy lookup if a type exists in the dictionary.
16487
17106
  */
16488
17107
  readonly reverse_entity_type_filters: Record<string, boolean>
16489
17108
  /**
@@ -16572,9 +17191,12 @@ interface UpgradeItemPrototype extends BaseItemPrototype {
16572
17191
  /**
16573
17192
  * A reference to an item and count owned by some external entity.
16574
17193
  *
17194
+ * **Notes**
17195
+ * - In most instances this is a simple reference as in: it points at a specific slot in an inventory and not the item in the slot.
17196
+ * - In the instance this references an item on a {@link LuaTransportLine} the reference is only guaranteed to stay valid (and refer to the same item) as long as nothing changes the transport line.
17197
+ *
16575
17198
  * {@link https://lua-api.factorio.com/latest/LuaItemStack.html View documentation}
16576
17199
  * @noSelf
16577
- * @remarks In most instances this is a simple reference as in: it points at a specific slot in an inventory and not the item in the slot.<br>In the instance this references an item on a {@link LuaTransportLine} the reference is only guaranteed to stay valid (and refer to the same item) as long as nothing changes the transport line.
16578
17200
  */
16579
17201
  interface LuaItemStack {
16580
17202
  /**
@@ -16712,11 +17334,12 @@ interface LuaItemStack {
16712
17334
  */
16713
17335
  get_inventory(inventory: defines.inventory): LuaInventory | undefined
16714
17336
  /**
17337
+ * **Note**
16715
17338
  *
17339
+ * Built entities can be come invalid between the building of the blueprint and the function returning if by_player or raise_built is used and one of those events invalidates the entity.
16716
17340
  *
16717
17341
  * {@link https://lua-api.factorio.com/latest/LuaItemStack.html#LuaItemStack.build_blueprint View documentation}
16718
17342
  * @returns Array of created ghosts
16719
- * @remarks Built entities can be come invalid between the building of the blueprint and the function returning if by_player or raise_built is used and one of those events invalidates the entity.
16720
17343
  */
16721
17344
  build_blueprint(params: {
16722
17345
  /**
@@ -17055,8 +17678,11 @@ interface LuaItemStack {
17055
17678
  /**
17056
17679
  * Durability of the contained item. Automatically capped at the item's maximum durability.
17057
17680
  *
17681
+ * **Note**
17682
+ *
17683
+ * When used on a non-tool item, the value of this attribute is `nil`.
17684
+ *
17058
17685
  * {@link https://lua-api.factorio.com/latest/LuaItemStack.html#LuaItemStack.durability View documentation}
17059
- * @remarks When used on a non-tool item, the value of this attribute is `nil`.
17060
17686
  */
17061
17687
  durability: double | undefined
17062
17688
  /**
@@ -17430,11 +18056,12 @@ interface BaseItemStack {
17430
18056
  */
17431
18057
  get_inventory(inventory: defines.inventory): LuaInventory | undefined
17432
18058
  /**
18059
+ * **Note**
17433
18060
  *
18061
+ * Built entities can be come invalid between the building of the blueprint and the function returning if by_player or raise_built is used and one of those events invalidates the entity.
17434
18062
  *
17435
18063
  * {@link https://lua-api.factorio.com/latest/LuaItemStack.html#LuaItemStack.build_blueprint View documentation}
17436
18064
  * @returns Array of created ghosts
17437
- * @remarks Built entities can be come invalid between the building of the blueprint and the function returning if by_player or raise_built is used and one of those events invalidates the entity.
17438
18065
  */
17439
18066
  build_blueprint(params: {
17440
18067
  /**
@@ -17613,8 +18240,11 @@ interface BaseItemStack {
17613
18240
  /**
17614
18241
  * Durability of the contained item. Automatically capped at the item's maximum durability.
17615
18242
  *
18243
+ * **Note**
18244
+ *
18245
+ * When used on a non-tool item, the value of this attribute is `nil`.
18246
+ *
17616
18247
  * {@link https://lua-api.factorio.com/latest/LuaItemStack.html#LuaItemStack.durability View documentation}
17617
- * @remarks When used on a non-tool item, the value of this attribute is `nil`.
17618
18248
  */
17619
18249
  durability: double | undefined
17620
18250
  /**
@@ -18674,8 +19304,11 @@ interface LuaLogisticPoint {
18674
19304
  /**
18675
19305
  * The logistic filters for this logistic point or `nil` if this doesn't use logistic filters.
18676
19306
  *
19307
+ * **Note**
19308
+ *
19309
+ * The returned array will always have an entry for each filter and will be indexed in sequence when not nil.
19310
+ *
18677
19311
  * {@link https://lua-api.factorio.com/latest/LuaLogisticPoint.html#LuaLogisticPoint.filters View documentation}
18678
- * @remarks The returned array will always have an entry for each filter and will be indexed in sequence when not nil.
18679
19312
  */
18680
19313
  readonly filters: LogisticFilter[] | undefined
18681
19314
  /**
@@ -18687,8 +19320,11 @@ interface LuaLogisticPoint {
18687
19320
  /**
18688
19321
  * The force of this logistic point.
18689
19322
  *
19323
+ * **Note**
19324
+ *
19325
+ * This will always be the same as the {@link LuaLogisticPoint#owner LuaLogisticPoint::owner} force.
19326
+ *
18690
19327
  * {@link https://lua-api.factorio.com/latest/LuaLogisticPoint.html#LuaLogisticPoint.force View documentation}
18691
- * @remarks This will always be the same as the {@link LuaLogisticPoint#owner LuaLogisticPoint::owner} force.
18692
19328
  */
18693
19329
  readonly force: LuaForce
18694
19330
  /**
@@ -19060,8 +19696,11 @@ interface LuaPermissionGroup {
19060
19696
  /**
19061
19697
  * The name of this group.
19062
19698
  *
19699
+ * **Note**
19700
+ *
19701
+ * Setting the name to `nil` or an empty string sets the name to the default value.
19702
+ *
19063
19703
  * {@link https://lua-api.factorio.com/latest/LuaPermissionGroup.html#LuaPermissionGroup.name View documentation}
19064
- * @remarks Setting the name to `nil` or an empty string sets the name to the default value.
19065
19704
  */
19066
19705
  name: string
19067
19706
  /**
@@ -19149,8 +19788,11 @@ interface LuaPlayer extends LuaControl {
19149
19788
  /**
19150
19789
  * Print text to the chat console.
19151
19790
  *
19791
+ * **Note**
19792
+ *
19793
+ * Messages that are identical to a message sent in the last 60 ticks are not printed again.
19794
+ *
19152
19795
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.print View documentation}
19153
- * @remarks Messages that are identical to a message sent in the last 60 ticks are not printed again.
19154
19796
  */
19155
19797
  print(message: LocalisedString, color?: Color): void
19156
19798
  /**
@@ -19176,8 +19818,11 @@ interface LuaPlayer extends LuaControl {
19176
19818
  /**
19177
19819
  * Set the controller type of the player.
19178
19820
  *
19821
+ * **Notes**
19822
+ * - Setting a player to {@link defines.controllers.editor} auto promotes the player to admin and enables cheat mode.
19823
+ * - Setting a player to {@link defines.controllers.editor} also requires the calling player be an admin.
19824
+ *
19179
19825
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.set_controller View documentation}
19180
- * @remarks Setting a player to {@link defines.controllers.editor} auto promotes the player to admin and enables cheat mode.<br>Setting a player to {@link defines.controllers.editor} also requires the calling player be an admin.
19181
19826
  */
19182
19827
  set_controller(params: {
19183
19828
  /**
@@ -19297,10 +19942,13 @@ interface LuaPlayer extends LuaControl {
19297
19942
  /**
19298
19943
  * Creates and attaches a character entity to this player.
19299
19944
  *
19945
+ * **Note**
19946
+ *
19947
+ * The player must not have a character already connected and must be online (see {@link LuaPlayer#connected LuaPlayer::connected}).
19948
+ *
19300
19949
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.create_character View documentation}
19301
19950
  * @param character The character to create else the default is used.
19302
19951
  * @returns Whether the character was created.
19303
- * @remarks The player must not have a character already connected and must be online (see {@link LuaPlayer#connected LuaPlayer::connected}).
19304
19952
  */
19305
19953
  create_character(character?: string): boolean
19306
19954
  /**
@@ -19448,8 +20096,11 @@ interface LuaPlayer extends LuaControl {
19448
20096
  /**
19449
20097
  * Builds what ever is in the cursor on the surface the player is on.
19450
20098
  *
20099
+ * **Notes**
20100
+ * - Anything built will fire normal player-built events.
20101
+ * - The cursor stack will automatically be reduced as if the player built normally.
20102
+ *
19451
20103
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.build_from_cursor View documentation}
19452
- * @remarks Anything built will fire normal player-built events.<br>The cursor stack will automatically be reduced as if the player built normally.
19453
20104
  */
19454
20105
  build_from_cursor(params: {
19455
20106
  /**
@@ -19506,31 +20157,44 @@ interface LuaPlayer extends LuaControl {
19506
20157
  /**
19507
20158
  * The characters associated with this player.
19508
20159
  *
20160
+ * **Notes**
20161
+ * - The array will always be empty when the player is disconnected (see {@link LuaPlayer#connected LuaPlayer::connected}) regardless of there being associated characters.
20162
+ * - Characters associated with this player will be logged off when this player disconnects but are not controlled by any player.
20163
+ *
19509
20164
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.get_associated_characters View documentation}
19510
- * @remarks The array will always be empty when the player is disconnected (see {@link LuaPlayer#connected LuaPlayer::connected}) regardless of there being associated characters.<br>Characters associated with this player will be logged off when this player disconnects but are not controlled by any player.
19511
20165
  */
19512
20166
  get_associated_characters(): LuaEntity[]
19513
20167
  /**
19514
20168
  * Associates a character with this player.
19515
20169
  *
20170
+ * **Notes**
20171
+ * - The character must not be connected to any controller.
20172
+ * - If this player is currently disconnected (see {@link LuaPlayer#connected LuaPlayer::connected}) the character will be immediately "logged off".
20173
+ * - See {@link LuaPlayer#get_associated_characters LuaPlayer::get_associated_characters} for more information.
20174
+ *
19516
20175
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.associate_character View documentation}
19517
20176
  * @param character The character entity.
19518
- * @remarks The character must not be connected to any controller.<br>If this player is currently disconnected (see {@link LuaPlayer#connected LuaPlayer::connected}) the character will be immediately "logged off".<br>See {@link LuaPlayer#get_associated_characters LuaPlayer::get_associated_characters} for more information.
19519
20177
  */
19520
20178
  associate_character(character: LuaEntity): void
19521
20179
  /**
19522
20180
  * Disassociates a character from this player. This is functionally the same as setting {@link LuaEntity#associated_player LuaEntity::associated_player} to `nil`.
19523
20181
  *
20182
+ * **Note**
20183
+ *
20184
+ * See {@link LuaPlayer#get_associated_characters LuaPlayer::get_associated_characters} for more information.
20185
+ *
19524
20186
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.disassociate_character View documentation}
19525
20187
  * @param character The character entity
19526
- * @remarks See {@link LuaPlayer#get_associated_characters LuaPlayer::get_associated_characters} for more information.
19527
20188
  */
19528
20189
  disassociate_character(character: LuaEntity): void
19529
20190
  /**
19530
20191
  * Spawn flying text that is only visible to this player. Either `position` or `create_at_cursor` are required. When `create_at_cursor` is `true`, all parameters other than `text` are ignored.
19531
20192
  *
20193
+ * **Notes**
20194
+ * - If no custom `speed` is set and the text is longer than 25 characters, its `time_to_live` and `speed` are dynamically adjusted to give players more time to read it.
20195
+ * - Local flying text is not saved, which means it will disappear after a save/load-cycle.
20196
+ *
19532
20197
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.create_local_flying_text View documentation}
19533
- * @remarks If no custom `speed` is set and the text is longer than 25 characters, its `time_to_live` and `speed` are dynamically adjusted to give players more time to read it.<br>Local flying text is not saved, which means it will disappear after a save/load-cycle.
19534
20198
  */
19535
20199
  create_local_flying_text(params: {
19536
20200
  /**
@@ -19649,8 +20313,11 @@ interface LuaPlayer extends LuaControl {
19649
20313
  /**
19650
20314
  * Asks the player if they would like to connect to the given server.
19651
20315
  *
20316
+ * **Note**
20317
+ *
20318
+ * This only does anything when used on a multiplayer peer. Single player and server hosts will ignore the prompt.
20319
+ *
19652
20320
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.connect_to_server View documentation}
19653
- * @remarks This only does anything when used on a multiplayer peer. Single player and server hosts will ignore the prompt.
19654
20321
  */
19655
20322
  connect_to_server(params: {
19656
20323
  /**
@@ -19684,10 +20351,12 @@ interface LuaPlayer extends LuaControl {
19684
20351
  * **Raised events:**
19685
20352
  * - {@link OnStringTranslatedEvent on_string_translated}? _future_tick_ Raised if the request was successfully sent.
19686
20353
  *
20354
+ * **Note**
20355
+ *
20356
+ * Does nothing if this player is not connected. (see {@link LuaPlayer#connected LuaPlayer::connected}).
19687
20357
  *
19688
20358
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.request_translation View documentation}
19689
20359
  * @returns Whether the request was sent or not.
19690
- * @remarks Does nothing if this player is not connected. (see {@link LuaPlayer#connected LuaPlayer::connected}).
19691
20360
  */
19692
20361
  request_translation(localised_string: LocalisedString): boolean
19693
20362
  /**
@@ -19750,15 +20419,21 @@ interface LuaPlayer extends LuaControl {
19750
20419
  /**
19751
20420
  * The character attached to this player, or `nil` if no character.
19752
20421
  *
20422
+ * **Note**
20423
+ *
20424
+ * Will also return `nil` when the player is disconnected (see {@link LuaPlayer#connected LuaPlayer::connected}).
20425
+ *
19753
20426
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.character View documentation}
19754
- * @remarks Will also return `nil` when the player is disconnected (see {@link LuaPlayer#connected LuaPlayer::connected}).
19755
20427
  */
19756
20428
  character: LuaEntity | undefined
19757
20429
  /**
19758
20430
  * When in a cutscene; the character this player would be using once the cutscene is over.
19759
20431
  *
20432
+ * **Note**
20433
+ *
20434
+ * Will also return `nil` when the player is disconnected (see {@link LuaPlayer#connected LuaPlayer::connected}).
20435
+ *
19760
20436
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.cutscene_character View documentation}
19761
- * @remarks Will also return `nil` when the player is disconnected (see {@link LuaPlayer#connected LuaPlayer::connected}).
19762
20437
  */
19763
20438
  readonly cutscene_character: LuaEntity | undefined
19764
20439
  /**
@@ -19778,8 +20453,11 @@ interface LuaPlayer extends LuaControl {
19778
20453
  /**
19779
20454
  * The stashed controller type or `nil` if no controller is stashed.
19780
20455
  *
20456
+ * **Note**
20457
+ *
20458
+ * This is mainly useful when a player is in the map editor.
20459
+ *
19781
20460
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.stashed_controller_type View documentation}
19782
- * @remarks This is mainly useful when a player is in the map editor.
19783
20461
  */
19784
20462
  readonly stashed_controller_type: defines.controllers | undefined
19785
20463
  /**
@@ -19829,8 +20507,11 @@ interface LuaPlayer extends LuaControl {
19829
20507
  /**
19830
20508
  * `true` if the player is an admin.
19831
20509
  *
20510
+ * **Note**
20511
+ *
20512
+ * Trying to change player admin status from the console when you aren't an admin does nothing.
20513
+ *
19832
20514
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.admin View documentation}
19833
- * @remarks Trying to change player admin status from the console when you aren't an admin does nothing.
19834
20515
  */
19835
20516
  admin: boolean
19836
20517
  /**
@@ -19868,29 +20549,41 @@ interface LuaPlayer extends LuaControl {
19868
20549
  /**
19869
20550
  * Gets the current per-player settings for the this player, indexed by prototype name. Returns the same structure as {@link LuaSettings#get_player_settings LuaSettings::get_player_settings}.
19870
20551
  *
20552
+ * **Note**
20553
+ *
20554
+ * This table will become invalid if its associated player does.
20555
+ *
19871
20556
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.mod_settings View documentation}
19872
- * @remarks This table will become invalid if its associated player does.
19873
20557
  */
19874
20558
  readonly mod_settings: LuaCustomTable<string, ModSetting>
19875
20559
  /**
19876
20560
  * The number of ticks until this player will respawn or `nil` if not waiting to respawn.
19877
20561
  *
20562
+ * **Notes**
20563
+ * - Set to `nil` to immediately respawn the player.
20564
+ * - Set to any positive value to trigger the respawn state for this player.
20565
+ *
19878
20566
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.ticks_to_respawn View documentation}
19879
- * @remarks Set to `nil` to immediately respawn the player.<br>Set to any positive value to trigger the respawn state for this player.
19880
20567
  */
19881
20568
  ticks_to_respawn: uint | undefined
19882
20569
  /**
19883
20570
  * The display resolution for this player.
19884
20571
  *
20572
+ * **Note**
20573
+ *
20574
+ * During {@link OnPlayerCreatedEvent on_player_created}, this attribute will always return a resolution of `{width=1920, height=1080}`. To get the actual resolution, listen to the {@link OnPlayerDisplayResolutionChangedEvent on_player_display_resolution_changed} event raised shortly afterwards.
20575
+ *
19885
20576
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.display_resolution View documentation}
19886
- * @remarks During {@link OnPlayerCreatedEvent on_player_created}, this attribute will always return a resolution of `{width=1920, height=1080}`. To get the actual resolution, listen to the {@link OnPlayerDisplayResolutionChangedEvent on_player_display_resolution_changed} event raised shortly afterwards.
19887
20577
  */
19888
20578
  readonly display_resolution: DisplayResolution
19889
20579
  /**
19890
20580
  * The display scale for this player.
19891
20581
  *
20582
+ * **Note**
20583
+ *
20584
+ * During {@link OnPlayerCreatedEvent on_player_created}, this attribute will always return a scale of `1`. To get the actual scale, listen to the {@link OnPlayerDisplayScaleChangedEvent on_player_display_scale_changed} event raised shortly afterwards.
20585
+ *
19892
20586
  * {@link https://lua-api.factorio.com/latest/LuaPlayer.html#LuaPlayer.display_scale View documentation}
19893
- * @remarks During {@link OnPlayerCreatedEvent on_player_created}, this attribute will always return a scale of `1`. To get the actual scale, listen to the {@link OnPlayerDisplayScaleChangedEvent on_player_display_scale_changed} event raised shortly afterwards.
19894
20587
  */
19895
20588
  readonly display_scale: double
19896
20589
  /**
@@ -19970,9 +20663,12 @@ interface LuaPlayer extends LuaControl {
19970
20663
  /**
19971
20664
  * An object used to measure script performance.
19972
20665
  *
20666
+ * **Note**
20667
+ *
20668
+ * Since performance is non-deterministic, these objects don't allow reading the raw time values from Lua. They can be used anywhere a {@link LocalisedString} is used, except for {@link LuaGuiElement#add LuaGuiElement::add}'s LocalisedString arguments, {@link LuaSurface#create_entity LuaSurface::create_entity}'s `text` argument, and {@link LuaEntity#add_market_item LuaEntity::add_market_item}.
20669
+ *
19973
20670
  * {@link https://lua-api.factorio.com/latest/LuaProfiler.html View documentation}
19974
20671
  * @noSelf
19975
- * @remarks Since performance is non-deterministic, these objects don't allow reading the raw time values from Lua. They can be used anywhere a {@link LocalisedString} is used, except for {@link LuaGuiElement#add LuaGuiElement::add}'s LocalisedString arguments, {@link LuaSurface#create_entity LuaSurface::create_entity}'s `text` argument, and {@link LuaEntity#add_market_item LuaEntity::add_market_item}.
19976
20672
  */
19977
20673
  interface LuaProfiler {
19978
20674
  /**
@@ -19996,17 +20692,23 @@ interface LuaProfiler {
19996
20692
  /**
19997
20693
  * Add the duration of another timer to this timer. Useful to reduce start/stop overhead when accumulating time onto many timers at once.
19998
20694
  *
20695
+ * **Note**
20696
+ *
20697
+ * If other is running, the time to now will be added.
20698
+ *
19999
20699
  * {@link https://lua-api.factorio.com/latest/LuaProfiler.html#LuaProfiler.add View documentation}
20000
20700
  * @param other The timer to add to this timer.
20001
- * @remarks If other is running, the time to now will be added.
20002
20701
  */
20003
20702
  add(other: LuaProfiler): void
20004
20703
  /**
20005
20704
  * Divides the current duration by a set value. Useful for calculating the average of many iterations.
20006
20705
  *
20706
+ * **Note**
20707
+ *
20708
+ * Does nothing if this isn't stopped.
20709
+ *
20007
20710
  * {@link https://lua-api.factorio.com/latest/LuaProfiler.html#LuaProfiler.divide View documentation}
20008
20711
  * @param number The number to divide by. Must be > 0.
20009
- * @remarks Does nothing if this isn't stopped.
20010
20712
  */
20011
20713
  divide(number: double): void
20012
20714
  /**
@@ -20199,8 +20901,11 @@ interface LuaRandomGenerator {
20199
20901
  /**
20200
20902
  * Re-seeds the random generator with the given value.
20201
20903
  *
20904
+ * **Note**
20905
+ *
20906
+ * Seeds that are close together will produce similar results. Seeds from 0 to 341 will produce the same results.
20907
+ *
20202
20908
  * {@link https://lua-api.factorio.com/latest/LuaRandomGenerator.html#LuaRandomGenerator.re_seed View documentation}
20203
- * @remarks Seeds that are close together will produce similar results. Seeds from 0 to 341 will produce the same results.
20204
20909
  */
20205
20910
  re_seed(seed: uint): void
20206
20911
  /**
@@ -20574,10 +21279,13 @@ interface LuaRemote {
20574
21279
  /**
20575
21280
  * Add a remote interface.
20576
21281
  *
21282
+ * **Note**
21283
+ *
21284
+ * It is an error if the given interface `name` is already registered.
21285
+ *
20577
21286
  * {@link https://lua-api.factorio.com/latest/LuaRemote.html#LuaRemote.add_interface View documentation}
20578
21287
  * @param name Name of the interface.
20579
21288
  * @param functions List of functions that are members of the new interface.
20580
- * @remarks It is an error if the given interface `name` is already registered.
20581
21289
  */
20582
21290
  add_interface(name: string, functions: Record<string, (...args: any) => void>): void
20583
21291
  /**
@@ -20618,9 +21326,12 @@ interface LuaRemote {
20618
21326
  /**
20619
21327
  * Allows rendering of geometric shapes, text and sprites in the game world. Each render object is identified by an id that is universally unique for the lifetime of a whole game.
20620
21328
  *
21329
+ * **Note**
21330
+ *
21331
+ * If an entity target of an object is destroyed or changes surface, then the object is also destroyed.
21332
+ *
20621
21333
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html View documentation}
20622
21334
  * @noSelf
20623
- * @remarks If an entity target of an object is destroyed or changes surface, then the object is also destroyed.
20624
21335
  */
20625
21336
  interface LuaRendering {
20626
21337
  /**
@@ -20692,9 +21403,12 @@ interface LuaRendering {
20692
21403
  /**
20693
21404
  * Create a text.
20694
21405
  *
21406
+ * **Note**
21407
+ *
21408
+ * Not all fonts support scaling.
21409
+ *
20695
21410
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html#LuaRendering.draw_text View documentation}
20696
21411
  * @returns Id of the render object
20697
- * @remarks Not all fonts support scaling.
20698
21412
  */
20699
21413
  draw_text(params: {
20700
21414
  /**
@@ -21044,9 +21758,12 @@ interface LuaRendering {
21044
21758
  /**
21045
21759
  * Create a light.
21046
21760
  *
21761
+ * **Note**
21762
+ *
21763
+ * The base game uses the utility sprites `light_medium` and `light_small` for lights.
21764
+ *
21047
21765
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html#LuaRendering.draw_light View documentation}
21048
21766
  * @returns Id of the render object
21049
- * @remarks The base game uses the utility sprites `light_medium` and `light_small` for lights.
21050
21767
  */
21051
21768
  draw_light(params: {
21052
21769
  readonly sprite: SpritePath
@@ -21422,9 +22139,12 @@ interface LuaRendering {
21422
22139
  *
21423
22140
  * _Can only be used if this is Text, Circle, Arc, Polygon, Sprite, Light or Animation_
21424
22141
  *
22142
+ * **Note**
22143
+ *
22144
+ * Polygon vertices that are set to an entity will ignore this.
22145
+ *
21425
22146
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html#LuaRendering.get_target View documentation}
21426
22147
  * @returns `nil` if the object does not support target.
21427
- * @remarks Polygon vertices that are set to an entity will ignore this.
21428
22148
  */
21429
22149
  get_target(id: uint64): ScriptRenderTarget | undefined
21430
22150
  /**
@@ -21432,8 +22152,11 @@ interface LuaRendering {
21432
22152
  *
21433
22153
  * _Can only be used if this is Text, Circle, Arc, Polygon, Sprite, Light or Animation_
21434
22154
  *
22155
+ * **Note**
22156
+ *
22157
+ * Polygon vertices that are set to an entity will ignore this.
22158
+ *
21435
22159
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html#LuaRendering.set_target View documentation}
21436
- * @remarks Polygon vertices that are set to an entity will ignore this.
21437
22160
  */
21438
22161
  set_target(id: uint64, target: MapPosition | LuaEntity, target_offset?: Vector): void
21439
22162
  /**
@@ -21441,9 +22164,12 @@ interface LuaRendering {
21441
22164
  *
21442
22165
  * _Can only be used if this is Text, Polygon, Sprite, Light or Animation_
21443
22166
  *
22167
+ * **Note**
22168
+ *
22169
+ * Polygon vertices that are set to an entity will ignore this.
22170
+ *
21444
22171
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html#LuaRendering.get_orientation View documentation}
21445
22172
  * @returns `nil` if the object is not a text, polygon, sprite, light or animation.
21446
- * @remarks Polygon vertices that are set to an entity will ignore this.
21447
22173
  */
21448
22174
  get_orientation(id: uint64): RealOrientation | undefined
21449
22175
  /**
@@ -21451,8 +22177,11 @@ interface LuaRendering {
21451
22177
  *
21452
22178
  * _Can only be used if this is Text, Polygon, Sprite, Light or Animation_
21453
22179
  *
22180
+ * **Note**
22181
+ *
22182
+ * Polygon vertices that are set to an entity will ignore this.
22183
+ *
21454
22184
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html#LuaRendering.set_orientation View documentation}
21455
- * @remarks Polygon vertices that are set to an entity will ignore this.
21456
22185
  */
21457
22186
  set_orientation(id: uint64, orientation: RealOrientation): void
21458
22187
  /**
@@ -21801,9 +22530,12 @@ interface LuaRendering {
21801
22530
  *
21802
22531
  * _Can only be used if this is Polygon, Sprite or Animation_
21803
22532
  *
22533
+ * **Note**
22534
+ *
22535
+ * Polygon vertices that are set to an entity will ignore this.
22536
+ *
21804
22537
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html#LuaRendering.get_orientation_target View documentation}
21805
22538
  * @returns `nil` if no target or if this object is not a polygon, sprite, or animation.
21806
- * @remarks Polygon vertices that are set to an entity will ignore this.
21807
22539
  */
21808
22540
  get_orientation_target(id: uint64): ScriptRenderTarget | undefined
21809
22541
  /**
@@ -21811,8 +22543,11 @@ interface LuaRendering {
21811
22543
  *
21812
22544
  * _Can only be used if this is Polygon, Sprite or Animation_
21813
22545
  *
22546
+ * **Note**
22547
+ *
22548
+ * Polygon vertices that are set to an entity will ignore this.
22549
+ *
21814
22550
  * {@link https://lua-api.factorio.com/latest/LuaRendering.html#LuaRendering.set_orientation_target View documentation}
21815
- * @remarks Polygon vertices that are set to an entity will ignore this.
21816
22551
  */
21817
22552
  set_orientation_target(
21818
22553
  id: uint64,
@@ -22028,8 +22763,11 @@ interface LuaSettings {
22028
22763
  /**
22029
22764
  * Gets the current per-player settings for the given player, indexed by prototype name. Returns the same structure as {@link LuaPlayer#mod_settings LuaPlayer::mod_settings}.
22030
22765
  *
22766
+ * **Note**
22767
+ *
22768
+ * This table will become invalid if its associated player does.
22769
+ *
22031
22770
  * {@link https://lua-api.factorio.com/latest/LuaSettings.html#LuaSettings.get_player_settings View documentation}
22032
- * @remarks This table will become invalid if its associated player does.
22033
22771
  */
22034
22772
  get_player_settings(player: PlayerIdentification): LuaCustomTable<string, ModSetting>
22035
22773
  /**
@@ -23336,8 +24074,11 @@ interface LuaSurface {
23336
24074
  /**
23337
24075
  * Get the pollution for a given position.
23338
24076
  *
24077
+ * **Note**
24078
+ *
24079
+ * Pollution is stored per chunk, so this will return the same value for all positions in one chunk.
24080
+ *
23339
24081
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.get_pollution View documentation}
23340
- * @remarks Pollution is stored per chunk, so this will return the same value for all positions in one chunk.
23341
24082
  * @example
23342
24083
  *
23343
24084
  * ```
@@ -23580,6 +24321,10 @@ interface LuaSurface {
23580
24321
  /**
23581
24322
  * Find a non-colliding position within a given radius.
23582
24323
  *
24324
+ * **Note**
24325
+ *
24326
+ * Special care needs to be taken when using a radius of `0`. The game will not stop searching until it finds a suitable position, so it is important to make sure such a position exists. One particular case where it would not be able to find a solution is running it before any chunks have been generated.
24327
+ *
23583
24328
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.find_non_colliding_position View documentation}
23584
24329
  * @param name Prototype name of the entity to find a position for. (The bounding box for the collision checking is taken from this prototype.)
23585
24330
  * @param center Center of the search area.
@@ -23587,7 +24332,6 @@ interface LuaSurface {
23587
24332
  * @param precision The step length from the given position as it searches, in tiles. Minimum value is `0.01`.
23588
24333
  * @param force_to_tile_center Will only check tile centers. This can be useful when your intent is to place a building at the resulting position, as they must generally be placed at tile centers. Default false.
23589
24334
  * @returns The non-colliding position. May be `nil` if no suitable position was found.
23590
- * @remarks Special care needs to be taken when using a radius of `0`. The game will not stop searching until it finds a suitable position, so it is important to make sure such a position exists. One particular case where it would not be able to find a solution is running it before any chunks have been generated.
23591
24335
  */
23592
24336
  find_non_colliding_position(
23593
24337
  name: string,
@@ -23633,11 +24377,14 @@ interface LuaSurface {
23633
24377
  /**
23634
24378
  * Find enemy units (entities with type "unit") of a given force within an area.
23635
24379
  *
24380
+ * **Note**
24381
+ *
24382
+ * This is more efficient than {@link LuaSurface#find_entities LuaSurface::find_entities}.
24383
+ *
23636
24384
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.find_enemy_units View documentation}
23637
24385
  * @param center Center of the search area
23638
24386
  * @param radius Radius of the circular search area
23639
24387
  * @param force Force to find enemies of. If not given, uses the player force.
23640
- * @remarks This is more efficient than {@link LuaSurface#find_entities LuaSurface::find_entities}.
23641
24388
  * @example Find all units who would be interested to attack the player, within 100-tile area.
23642
24389
  *
23643
24390
  * ```
@@ -23648,8 +24395,11 @@ interface LuaSurface {
23648
24395
  /**
23649
24396
  * Find units (entities with type "unit") of a given force and force condition within a given area.
23650
24397
  *
24398
+ * **Note**
24399
+ *
24400
+ * This is more efficient than {@link LuaSurface#find_entities LuaSurface::find_entities}.
24401
+ *
23651
24402
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.find_units View documentation}
23652
- * @remarks This is more efficient than {@link LuaSurface#find_entities LuaSurface::find_entities}.
23653
24403
  * @example Find friendly units to "player" force
23654
24404
  *
23655
24405
  * ```
@@ -23835,18 +24585,24 @@ interface LuaSurface {
23835
24585
  /**
23836
24586
  * Send a group to build a new base.
23837
24587
  *
24588
+ * **Note**
24589
+ *
24590
+ * The specified force must be AI-controlled; i.e. `force.ai_controllable` must be `true`.
24591
+ *
23838
24592
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.build_enemy_base View documentation}
23839
24593
  * @param position Location of the new base.
23840
24594
  * @param unit_count Number of biters to send for the base-building task.
23841
24595
  * @param force Force the new base will belong to. Defaults to enemy.
23842
- * @remarks The specified force must be AI-controlled; i.e. `force.ai_controllable` must be `true`.
23843
24596
  */
23844
24597
  build_enemy_base(position: MapPosition, unit_count: uint, force?: ForceIdentification): void
23845
24598
  /**
23846
24599
  * Get the tile at a given position.
23847
24600
  *
24601
+ * **Note**
24602
+ *
24603
+ * The input position params can also be a single tile position.
24604
+ *
23848
24605
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.get_tile View documentation}
23849
- * @remarks The input position params can also be a single tile position.
23850
24606
  */
23851
24607
  get_tile(x: int, y: int): LuaTile
23852
24608
  /**
@@ -23857,13 +24613,15 @@ interface LuaSurface {
23857
24613
  * **Raised events:**
23858
24614
  * - {@link ScriptRaisedSetTilesEvent script_raised_set_tiles}? _instantly_ Raised if the `raise_event` flag was set.
23859
24615
  *
24616
+ * **Note**
24617
+ *
24618
+ * It is recommended to call this method once for all the tiles you want to change rather than calling it individually for every tile. As the tile correction is used after every step, calling it one by one could cause the tile correction logic to redo some of the changes. Also, many small API calls are generally more performance intensive than one big one.
23860
24619
  *
23861
24620
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.set_tiles View documentation}
23862
24621
  * @param correct_tiles If `false`, the correction logic is not applied to the changed tiles. Defaults to `true`.
23863
24622
  * @param remove_colliding_entities `true`, `false`, or `abort_on_collision`. Defaults to `true`.
23864
24623
  * @param remove_colliding_decoratives `true` or `false`. Defaults to `true`.
23865
24624
  * @param raise_event `true` or `false`. Defaults to `false`.
23866
- * @remarks It is recommended to call this method once for all the tiles you want to change rather than calling it individually for every tile. As the tile correction is used after every step, calling it one by one could cause the tile correction logic to redo some of the changes. Also, many small API calls are generally more performance intensive than one big one.
23867
24625
  */
23868
24626
  set_tiles(
23869
24627
  tiles: readonly Tile[],
@@ -24073,11 +24831,14 @@ interface LuaSurface {
24073
24831
  /**
24074
24832
  * Gets all tiles of the given types that are connected horizontally or vertically to the given tile position including the given tile position.
24075
24833
  *
24834
+ * **Note**
24835
+ *
24836
+ * This won't find tiles in non-generated chunks.
24837
+ *
24076
24838
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.get_connected_tiles View documentation}
24077
24839
  * @param position The tile position to start at.
24078
24840
  * @param tiles The tiles to search for.
24079
24841
  * @returns The resulting set of tiles.
24080
- * @remarks This won't find tiles in non-generated chunks.
24081
24842
  */
24082
24843
  get_connected_tiles(position: TilePosition, tiles: readonly string[]): TilePositionTable[]
24083
24844
  /**
@@ -24093,26 +24854,35 @@ interface LuaSurface {
24093
24854
  /**
24094
24855
  * Regenerate autoplacement of some entities on this surface. This can be used to autoplace newly-added entities.
24095
24856
  *
24857
+ * **Note**
24858
+ *
24859
+ * All specified entity prototypes must be autoplacable. If nothing is given all entities are generated on all chunks.
24860
+ *
24096
24861
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.regenerate_entity View documentation}
24097
24862
  * @param entities Prototype names of entity or entities to autoplace. When `nil` all entities with an autoplace are used.
24098
24863
  * @param chunks The chunk positions to regenerate the entities on. If not given all chunks are regenerated. Note chunks with status < entities are ignored.
24099
- * @remarks All specified entity prototypes must be autoplacable. If nothing is given all entities are generated on all chunks.
24100
24864
  */
24101
24865
  regenerate_entity(entities?: string | readonly string[], chunks?: readonly ChunkPosition[]): void
24102
24866
  /**
24103
24867
  * Regenerate autoplacement of some decoratives on this surface. This can be used to autoplace newly-added decoratives.
24104
24868
  *
24869
+ * **Note**
24870
+ *
24871
+ * All specified decorative prototypes must be autoplacable. If nothing is given all decoratives are generated on all chunks.
24872
+ *
24105
24873
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.regenerate_decorative View documentation}
24106
24874
  * @param decoratives Prototype names of decorative or decoratives to autoplace. When `nil` all decoratives with an autoplace are used.
24107
24875
  * @param chunks The chunk positions to regenerate the entities on. If not given all chunks are regenerated. Note chunks with status < entities are ignored.
24108
- * @remarks All specified decorative prototypes must be autoplacable. If nothing is given all decoratives are generated on all chunks.
24109
24876
  */
24110
24877
  regenerate_decorative(decoratives?: string | readonly string[], chunks?: readonly ChunkPosition[]): void
24111
24878
  /**
24112
24879
  * Print text to the chat console of all players on this surface.
24113
24880
  *
24881
+ * **Note**
24882
+ *
24883
+ * Messages that are identical to a message sent in the last 60 ticks are not printed again.
24884
+ *
24114
24885
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.print View documentation}
24115
- * @remarks Messages that are identical to a message sent in the last 60 ticks are not printed again.
24116
24886
  */
24117
24887
  print(message: LocalisedString, color?: Color): void
24118
24888
  /**
@@ -24140,8 +24910,11 @@ interface LuaSurface {
24140
24910
  /**
24141
24911
  * Adds the given decoratives to the surface.
24142
24912
  *
24913
+ * **Note**
24914
+ *
24915
+ * This will merge decoratives of the same type that already exist effectively increasing the "amount" field.
24916
+ *
24143
24917
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.create_decoratives View documentation}
24144
- * @remarks This will merge decoratives of the same type that already exist effectively increasing the "amount" field.
24145
24918
  */
24146
24919
  create_decoratives(params: {
24147
24920
  /**
@@ -24235,9 +25008,11 @@ interface LuaSurface {
24235
25008
  * - {@link OnEntityClonedEvent on_entity_cloned} _instantly_ Raised for every entity that was cloned.
24236
25009
  * - {@link OnAreaClonedEvent on_area_cloned} _instantly_ Raised after the individual `on_entity_cloned` events.
24237
25010
  *
25011
+ * **Note**
25012
+ *
25013
+ * Entities are cloned in an order such that they can always be created, eg rails before trains.
24238
25014
  *
24239
25015
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.clone_area View documentation}
24240
- * @remarks Entities are cloned in an order such that they can always be created, eg rails before trains.
24241
25016
  */
24242
25017
  clone_area(params: {
24243
25018
  readonly source_area: BoundingBox
@@ -24276,8 +25051,11 @@ interface LuaSurface {
24276
25051
  /**
24277
25052
  * Clones the given area.
24278
25053
  *
25054
+ * **Notes**
25055
+ * - {@link defines.events.on_entity_cloned} is raised for each entity, and then {@link defines.events.on_area_cloned} is raised.
25056
+ * - Entities are cloned in an order such that they can always be created, eg rails before trains.
25057
+ *
24279
25058
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.clone_brush View documentation}
24280
- * @remarks {@link defines.events.on_entity_cloned} is raised for each entity, and then {@link defines.events.on_area_cloned} is raised.<br>Entities are cloned in an order such that they can always be created, eg rails before trains.
24281
25059
  */
24282
25060
  clone_brush(params: {
24283
25061
  readonly source_offset: TilePosition
@@ -24324,9 +25102,11 @@ interface LuaSurface {
24324
25102
  * **Raised events:**
24325
25103
  * - {@link OnEntityClonedEvent on_entity_cloned} _instantly_ Raised for every entity that was cloned.
24326
25104
  *
25105
+ * **Note**
25106
+ *
25107
+ * Entities are cloned in an order such that they can always be created, eg rails before trains.
24327
25108
  *
24328
25109
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.clone_entities View documentation}
24329
- * @remarks Entities are cloned in an order such that they can always be created, eg rails before trains.
24330
25110
  */
24331
25111
  clone_entities(params: {
24332
25112
  readonly entities: readonly LuaEntity[]
@@ -24559,8 +25339,11 @@ interface LuaSurface {
24559
25339
  /**
24560
25340
  * The name of this surface. Names are unique among surfaces.
24561
25341
  *
25342
+ * **Note**
25343
+ *
25344
+ * the default surface can't be renamed.
25345
+ *
24562
25346
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.name View documentation}
24563
- * @remarks the default surface can't be renamed.
24564
25347
  */
24565
25348
  name: string
24566
25349
  /**
@@ -24663,8 +25446,11 @@ interface LuaSurface {
24663
25446
  /**
24664
25447
  * The multiplier of solar power on this surface. Cannot be less than 0.
24665
25448
  *
25449
+ * **Note**
25450
+ *
25451
+ * Solar equipment is still limited to its maximum power output.
25452
+ *
24666
25453
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.solar_power_multiplier View documentation}
24667
- * @remarks Solar equipment is still limited to its maximum power output.
24668
25454
  */
24669
25455
  solar_power_multiplier: double
24670
25456
  /**
@@ -24692,8 +25478,11 @@ interface LuaSurface {
24692
25478
  /**
24693
25479
  * If clouds are shown on this surface.
24694
25480
  *
25481
+ * **Note**
25482
+ *
25483
+ * If false, clouds are never shown. If true the player must also have clouds enabled in graphics settings for them to be shown.
25484
+ *
24695
25485
  * {@link https://lua-api.factorio.com/latest/LuaSurface.html#LuaSurface.show_clouds View documentation}
24696
- * @remarks If false, clouds are never shown. If true the player must also have clouds enabled in graphics settings for them to be shown.
24697
25486
  */
24698
25487
  show_clouds: boolean
24699
25488
  /**
@@ -24793,8 +25582,11 @@ interface LuaTechnology {
24793
25582
  /**
24794
25583
  * The number of research units required for this technology.
24795
25584
  *
25585
+ * **Note**
25586
+ *
25587
+ * This is multiplied by the current research cost multiplier, unless {@link LuaTechnologyPrototype#ignore_tech_cost_multiplier LuaTechnologyPrototype::ignore_tech_cost_multiplier} is `true`.
25588
+ *
24796
25589
  * {@link https://lua-api.factorio.com/latest/LuaTechnology.html#LuaTechnology.research_unit_count View documentation}
24797
- * @remarks This is multiplied by the current research cost multiplier, unless {@link LuaTechnologyPrototype#ignore_tech_cost_multiplier LuaTechnologyPrototype::ignore_tech_cost_multiplier} is `true`.
24798
25590
  */
24799
25591
  readonly research_unit_count: uint
24800
25592
  /**
@@ -24876,8 +25668,11 @@ interface LuaTechnologyPrototype {
24876
25668
  /**
24877
25669
  * If this technology ignores the technology cost multiplier setting.
24878
25670
  *
25671
+ * **Note**
25672
+ *
25673
+ * {@link LuaTechnologyPrototype#research_unit_count LuaTechnologyPrototype::research_unit_count} will already take this setting into account.
25674
+ *
24879
25675
  * {@link https://lua-api.factorio.com/latest/LuaTechnologyPrototype.html#LuaTechnologyPrototype.ignore_tech_cost_multiplier View documentation}
24880
- * @remarks {@link LuaTechnologyPrototype#research_unit_count LuaTechnologyPrototype::research_unit_count} will already take this setting into account.
24881
25676
  */
24882
25677
  readonly ignore_tech_cost_multiplier: boolean
24883
25678
  /**
@@ -24907,8 +25702,11 @@ interface LuaTechnologyPrototype {
24907
25702
  /**
24908
25703
  * The number of research units required for this technology.
24909
25704
  *
25705
+ * **Note**
25706
+ *
25707
+ * This is multiplied by the current research cost multiplier, unless {@link LuaTechnologyPrototype#ignore_tech_cost_multiplier LuaTechnologyPrototype::ignore_tech_cost_multiplier} is `true`.
25708
+ *
24910
25709
  * {@link https://lua-api.factorio.com/latest/LuaTechnologyPrototype.html#LuaTechnologyPrototype.research_unit_count View documentation}
24911
- * @remarks This is multiplied by the current research cost multiplier, unless {@link LuaTechnologyPrototype#ignore_tech_cost_multiplier LuaTechnologyPrototype::ignore_tech_cost_multiplier} is `true`.
24912
25710
  */
24913
25711
  readonly research_unit_count: uint
24914
25712
  /**
@@ -25276,8 +26074,11 @@ interface LuaTrain {
25276
26074
  /**
25277
26075
  * Current speed.
25278
26076
  *
26077
+ * **Note**
26078
+ *
26079
+ * Changing the speed of the train is potentially an unsafe operation because train uses the speed for its internal calculations of break distances, etc.
26080
+ *
25279
26081
  * {@link https://lua-api.factorio.com/latest/LuaTrain.html#LuaTrain.speed View documentation}
25280
- * @remarks Changing the speed of the train is potentially an unsafe operation because train uses the speed for its internal calculations of break distances, etc.
25281
26082
  */
25282
26083
  speed: double
25283
26084
  /**
@@ -25325,8 +26126,11 @@ interface LuaTrain {
25325
26126
  /**
25326
26127
  * The trains current schedule or `nil` if empty. Set to `nil` to clear.
25327
26128
  *
26129
+ * **Note**
26130
+ *
26131
+ * The schedule can't be changed by modifying the returned table. Instead, changes must be made by assigning a new table to this attribute.
26132
+ *
25328
26133
  * {@link https://lua-api.factorio.com/latest/LuaTrain.html#LuaTrain.schedule View documentation}
25329
- * @remarks The schedule can't be changed by modifying the returned table. Instead, changes must be made by assigning a new table to this attribute.
25330
26134
  */
25331
26135
  schedule: TrainSchedule | undefined
25332
26136
  /**
@@ -25394,8 +26198,11 @@ interface LuaTrain {
25394
26198
  /**
25395
26199
  * The player passengers on the train
25396
26200
  *
26201
+ * **Note**
26202
+ *
26203
+ * This does *not* index using player index. See {@link LuaPlayer#index LuaPlayer::index} on each player instance for the player index.
26204
+ *
25397
26205
  * {@link https://lua-api.factorio.com/latest/LuaTrain.html#LuaTrain.passengers View documentation}
25398
- * @remarks This does *not* index using player index. See {@link LuaPlayer#index LuaPlayer::index} on each player instance for the player index.
25399
26206
  */
25400
26207
  readonly passengers: LuaPlayer[]
25401
26208
  /**
@@ -25625,8 +26432,11 @@ interface LuaTransportLine extends ReadonlyArray<LuaItemStack> {
25625
26432
  /**
25626
26433
  * Returns whether the associated internal transport line of this line is the same as the others associated internal transport line.
25627
26434
  *
26435
+ * **Note**
26436
+ *
26437
+ * This can return true even when the {@link LuaTransportLine#owner LuaTransportLine::owner}s are different (so `this == other` is false), because the internal transport lines can span multiple tiles.
26438
+ *
25628
26439
  * {@link https://lua-api.factorio.com/latest/LuaTransportLine.html#LuaTransportLine.line_equals View documentation}
25629
- * @remarks This can return true even when the {@link LuaTransportLine#owner LuaTransportLine::owner}s are different (so `this == other` is false), because the internal transport lines can span multiple tiles.
25630
26440
  */
25631
26441
  line_equals(other: LuaTransportLine): boolean
25632
26442
  /**
@@ -25732,8 +26542,11 @@ interface LuaUnitGroup {
25732
26542
  /**
25733
26543
  * Make a unit a member of this group. Has the same effect as giving a `group_command` with this group to the unit.
25734
26544
  *
26545
+ * **Note**
26546
+ *
26547
+ * The member must have the same force as the unit group.
26548
+ *
25735
26549
  * {@link https://lua-api.factorio.com/latest/LuaUnitGroup.html#LuaUnitGroup.add_member View documentation}
25736
- * @remarks The member must have the same force as the unit group.
25737
26550
  */
25738
26551
  add_member(unit: LuaEntity): void
25739
26552
  /**