<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.factorio.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Lovely+santa</id>
	<title>Official Factorio Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.factorio.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Lovely+santa"/>
	<link rel="alternate" type="text/html" href="https://wiki.factorio.com/Special:Contributions/Lovely_santa"/>
	<updated>2026-04-23T10:59:55Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Tutorial:Mod_settings&amp;diff=200030</id>
		<title>Tutorial:Mod settings</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Tutorial:Mod_settings&amp;diff=200030"/>
		<updated>2024-10-09T18:50:51Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: Corrected error in example for string setting localisations&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
This tutorial aims to explain how to create and use mod settings. Basic knowledge of modding is assumed, so you should have at least understood [[Tutorial:Modding tutorial/Gangsir|Gangsir&#039;s modding tutorial]].&lt;br /&gt;
&lt;br /&gt;
== Overview ==&lt;br /&gt;
Each mod can specify settings that users can change. The values of these settings can be accessed from inside the data stage or the control stage depending on their [[#The_setting_type_property|setting_type]] and allow to conditionally create or modify prototypes and to add configuration options to control scripts. They allow modders to easily create a graphical interface for their configuration options, instead of using on text files that have to be edited manually by users.&lt;br /&gt;
&lt;br /&gt;
== Location ==&lt;br /&gt;
&lt;br /&gt;
Mod settings are defined in the [https://lua-api.factorio.com/latest/Data-Lifecycle.html settings stage]. This stage is loaded before the data stage. There are three files in which settings can be defined:&lt;br /&gt;
* settings.lua&lt;br /&gt;
* settings-updates.lua&lt;br /&gt;
* settings-final-fixes.lua&lt;br /&gt;
&lt;br /&gt;
First the settings.lua file is called for each mod, in the order of their dependencies and then in the [[:Wikipedia:natural sort order|natural sort order]]. After settings.lua has been called for all mods, the settings-updates.lua file is called for each mod &amp;lt;sup&amp;gt;(in the same order)&amp;lt;/sup&amp;gt; and finally the settings-final-fixes.lua file is called for each mod &amp;lt;sup&amp;gt;(in the same order)&amp;lt;/sup&amp;gt;. These 3 different phases of the settings stage allow to change settings of other mods without needing to rely on dependencies to load last. The settings are all defined in the same stage and their user defined values are not available, therefore mods cannot conditionally create settings depending on the values of other mod settings. Since the settings stage gets loaded first, there is also no prototype data or [http://lua-api.factorio.com/latest/LuaRemote.html remote interface] available.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;mod-settings.dat&amp;quot; file stored in the [[Application_directory#User_Data_directory|mods folder]] for the game contains the local players settings between game sessions similar to the player-data.json file.&lt;br /&gt;
&lt;br /&gt;
== Creation ==&lt;br /&gt;
&lt;br /&gt;
Mod settings are defined and modified by using the data table during the settings stage. This works [[Tutorial:Modding_tutorial/Gangsir#Prototype_creation|the same way as other prototypes]]. An example would be:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
data:extend({&lt;br /&gt;
    {&lt;br /&gt;
        type = &amp;quot;bool-setting&amp;quot;,&lt;br /&gt;
        name = &amp;quot;my-mod-test-setting&amp;quot;,&lt;br /&gt;
        setting_type = &amp;quot;runtime-global&amp;quot;,&lt;br /&gt;
        default_value = true&lt;br /&gt;
    }&lt;br /&gt;
})&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, the setting has multiple properties. Each setting supports the following standard prototype properties:&lt;br /&gt;
* name - [[Types/string|string]] - Mandatory.&lt;br /&gt;
* type - [[Types/string|string]] - Mandatory.&lt;br /&gt;
* localised_name - [[Types/LocalisedString|LocalisedString]] - Optional.&lt;br /&gt;
* localised_description - [[Types/LocalisedString|LocalisedString]] - Optional.&lt;br /&gt;
* [[Types/Order|order]] - [[Types/string|string]] - Optional.&lt;br /&gt;
&lt;br /&gt;
In addition to the standard properties, mod settings also contain:&lt;br /&gt;
&lt;br /&gt;
* hidden - [[Types/bool|bool]] - Optional.&lt;br /&gt;
* setting_type - [[Types/string|string]] - Mandatory.&lt;br /&gt;
&lt;br /&gt;
=== The name property ===&lt;br /&gt;
&lt;br /&gt;
The name of the settings prototype should be unique to avoid mod conflicts since the mod settings are global across all mods. Because of that it is recommened to prefix mod settings with your mod name, &amp;quot;my-mod&amp;quot; in this example.&lt;br /&gt;
&lt;br /&gt;
=== The type property ===&lt;br /&gt;
&lt;br /&gt;
There are four types of mod settings:&lt;br /&gt;
&lt;br /&gt;
* bool-setting - a true/false checkbox&lt;br /&gt;
* int-setting - a signed 64 bit integer textfield (or selection dropdown)&lt;br /&gt;
* double-setting - a double precision floating point textfield (or selection dropdown)&lt;br /&gt;
* string-setting - a string textfield (or selection dropdown)&lt;br /&gt;
* color-setting - a color picker (sliders), with whole number textfields. Includes alpha.&lt;br /&gt;
&lt;br /&gt;
Depending on the type, the prototype also allows or requires additional properties, these are listed below.&lt;br /&gt;
&lt;br /&gt;
==== bool-setting ====&lt;br /&gt;
* default_value - [[Types/bool|bool]] - Mandatory.&lt;br /&gt;
** Defines the default value of the setting, in this case whether the checkbox is checked or not.&lt;br /&gt;
* forced_value - [[Types/bool|bool]] - Optional.&lt;br /&gt;
** Only loaded if &amp;lt;code&amp;gt;hidden = true&amp;lt;/code&amp;gt;. This forces the setting to be of this value. This can be useful for mod compatiblity.&amp;lt;sup&amp;gt;[https://forums.factorio.com/viewtopic.php?p=531322#p531322]&lt;br /&gt;
&amp;lt;/sup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== int-setting ====&lt;br /&gt;
* default_value - [[Types/int64|int64]] - Mandatory.&lt;br /&gt;
** Defines the default value of the setting.&lt;br /&gt;
* minimum_value - [[Types/int64|int64]] - Optional.&lt;br /&gt;
** Defines the lowest possible number.&lt;br /&gt;
* maximum_value - [[Types/int64|int64]] - Optional.&lt;br /&gt;
** Defines the highest possible number.&lt;br /&gt;
* allowed_values - [[Types/table|array]] of [[Types/int64|int64]] - Optional.&lt;br /&gt;
** Makes it possible to force the player to choose between the defined numbers, creates a dropdown instead of a texfield.&lt;br /&gt;
** If only one allowed value is given, the settings is forced to be of that value.&lt;br /&gt;
&lt;br /&gt;
==== double-setting ====&lt;br /&gt;
* default_value - [[Types/double|double]] - Mandatory.&lt;br /&gt;
** Defines the default value of the setting.&lt;br /&gt;
* minimum_value - [[Types/double|double]] - Optional.&lt;br /&gt;
** Defines the lowest possible number.&lt;br /&gt;
* maximum_value - [[Types/double|double]] - Optional.&lt;br /&gt;
** Defines the highest possible number.&lt;br /&gt;
* allowed_values - [[Types/table|array]] of [[Types/double|double]] - Optional.&lt;br /&gt;
** Makes it possible to force the player to choose between the defined numbers, creates a dropdown instead of a textfield.&lt;br /&gt;
** If only one allowed value is given, the settings is forced to be of that value.&lt;br /&gt;
&lt;br /&gt;
==== string-setting ====&lt;br /&gt;
* default_value - [[Types/string|string]] - Mandatory.&lt;br /&gt;
** Defines the default value of the setting.&lt;br /&gt;
* allow_blank - [[Types/bool|bool]] - Optional. - Default: false&lt;br /&gt;
** Defines whether it&#039;s possible for the user to set the textfield to empty and apply the setting.&lt;br /&gt;
* auto_trim - [[Types/bool|bool]] - Optional. - Default: false&lt;br /&gt;
** Whether values that are input by the user should have whitespace removed from both ends of the string.&lt;br /&gt;
* allowed_values - [[Types/table|array]] of [[Types/string|string]] - Optional.&lt;br /&gt;
** Makes it possible to force the player to choose between the defined strings, creates a dropdown instead of a textfield. The strings in the dropdown can be localized (translated) and can have a tooltip, see below.&lt;br /&gt;
** If only one allowed value is given, the settings is forced to be of that value.&lt;br /&gt;
&lt;br /&gt;
==== color-setting ====&lt;br /&gt;
* default_value - [[Types/Color|Color]] - Mandatory.&lt;br /&gt;
** Defines the default value of the setting.&lt;br /&gt;
&lt;br /&gt;
=== The order property ===&lt;br /&gt;
&lt;br /&gt;
The order property can be used to change how the mod settings are ordered in the settings gui. Mod settings are sorted&lt;br /&gt;
* first by mod&lt;br /&gt;
* then by the setting &amp;quot;order&amp;quot; string&lt;br /&gt;
* then finally by the setting name.&lt;br /&gt;
&lt;br /&gt;
For more info on how to use the order string, see [[Types/Order]].&lt;br /&gt;
&lt;br /&gt;
=== The hidden property ===&lt;br /&gt;
&lt;br /&gt;
The hidden property can be used to hide mod settings from GUIs, so that they cannot be seen or changed by players. However, other mods can still access hidden settings.&amp;lt;sup&amp;gt;[https://forums.factorio.com/83316]&amp;lt;/sup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== The setting_type property ===&lt;br /&gt;
[[File:Mod_settings_gui.png|right|300px|thumb|The mod settings gui. Can be reached from the main menu → Settings → Mod settings.]]&lt;br /&gt;
There are the overall kinds of settings:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;startup&#039;&#039;&#039;: This kind of setting is available in the prototype stage, and can not be changed runtime. They have to be  set to the same values for all players on a server.&lt;br /&gt;
* &#039;&#039;&#039;runtime-global&#039;&#039;&#039;: This kind of setting is global to an entire save game and can be changed runtime. On servers, only admins can change these settings.&lt;br /&gt;
* &#039;&#039;&#039;runtime-per-user&#039;&#039;&#039;: This kind of setting is only available runtime in the control.lua stage and each player has their own instance of this setting. When a player joins a server their local setting of &amp;quot;keep mod settings per save&amp;quot; determines if the local settings they have set are synced to the loaded save or if the save&#039;s settings are used.&lt;br /&gt;
&lt;br /&gt;
This &amp;quot;setting_type&amp;quot; also determines in which tab the setting is showed in the mod settings menu.&lt;br /&gt;
&lt;br /&gt;
=== Locale ===&lt;br /&gt;
The locale for mod settings works like any other locale in the game. The names of the groups for the setting name and description (tooltip) are &amp;quot;mod-setting-name&amp;quot; and &amp;quot;mod-setting-description&amp;quot;. The dropdown items of a string setting can be localized in the &amp;quot;string-mod-setting&amp;quot; group, but the game falls back to just showing the name of the dropdown item if no localization is found. An example for mod setting localization that would be set within &amp;quot;locale/en/locale.cfg&amp;quot;, is:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[mod-setting-name]&lt;br /&gt;
my-mod-string-test-setting=Localized test setting name&lt;br /&gt;
&lt;br /&gt;
[mod-setting-description]&lt;br /&gt;
my-mod-string-test-setting=Localized test setting description&lt;br /&gt;
&lt;br /&gt;
[string-mod-setting]&lt;br /&gt;
#&amp;lt;setting-name&amp;gt;-&amp;lt;dropdown-item-name&amp;gt;=&amp;lt;translated dropdown item&amp;gt;&lt;br /&gt;
my-mod-string-test-setting-item-1=Item 1 localized string&lt;br /&gt;
&lt;br /&gt;
[string-mod-setting-description]&lt;br /&gt;
#&amp;lt;setting-name&amp;gt;-&amp;lt;dropdown-item-name&amp;gt;=&amp;lt;tooltip of dropdown item&amp;gt;&lt;br /&gt;
my-mod-string-test-setting-item-1=Item 1 localized tooltip&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Usage ==&lt;br /&gt;
=== Reading settings ===&lt;br /&gt;
When accessing any mod setting, you will have to specifically access the &#039;&#039;value&#039;&#039; of the setting. The data type of the value depends on the type of the setting. For string settings that use a selection of allowed values, the value of the setting is one of the original string values defined in the prototype, the localization is ignored. See also: [http://lua-api.factorio.com/latest/Concepts.html#ModSetting ModSetting concept].&lt;br /&gt;
&lt;br /&gt;
In the prototype stage you can access settings of the setting_type &amp;quot;startup&amp;quot; by indexing &amp;lt;code&amp;gt;settings.startup&amp;lt;/code&amp;gt; with the name of the setting. Example:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
--in settings.lua:&lt;br /&gt;
data:extend({&lt;br /&gt;
    {&lt;br /&gt;
        type = &amp;quot;int-setting&amp;quot;,&lt;br /&gt;
        name = &amp;quot;my-mod-stone-wall-stack-size&amp;quot;,&lt;br /&gt;
        setting_type = &amp;quot;startup&amp;quot;,&lt;br /&gt;
        minimum_value = 1,&lt;br /&gt;
        default_value = 100&lt;br /&gt;
    }&lt;br /&gt;
})&lt;br /&gt;
&lt;br /&gt;
--in data.lua:&lt;br /&gt;
data.raw.item[&amp;quot;stone-wall&amp;quot;].stack_size = settings.startup[&amp;quot;my-mod-stone-wall-stack-size&amp;quot;].value&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;plainlinks&amp;quot;&amp;gt;&lt;br /&gt;
In the control stage, the settings of the setting_type &amp;quot;runtime-global&amp;quot; can be accessed using &amp;lt;code&amp;gt;settings.global[&amp;quot;setting-name&amp;quot;]&amp;lt;/code&amp;gt; (see [https://lua-api.factorio.com/latest/LuaSettings.html LuaSettings]). Settings of the setting_type &amp;quot;runtime-per-user&amp;quot; are accessed using &amp;lt;code&amp;gt;settings.get_player_settings([https://lua-api.factorio.com/latest/Concepts.html#PlayerIdentification &amp;amp;lt;PlayerIdentification&amp;amp;gt;])[&amp;quot;setting-name&amp;quot;]&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;game.players[[https://lua-api.factorio.com/latest/Concepts.html#PlayerIdentification &amp;amp;lt;PlayerIdentification&amp;amp;gt;]].mod_settings[&amp;quot;setting-name&amp;quot;]&amp;lt;/code&amp;gt;.&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
--in settings.lua:&lt;br /&gt;
data:extend({&lt;br /&gt;
    {&lt;br /&gt;
        type = &amp;quot;string-setting&amp;quot;,&lt;br /&gt;
        name = &amp;quot;my-mod-always-difficult&amp;quot;,&lt;br /&gt;
        setting_type = &amp;quot;runtime-global&amp;quot;,&lt;br /&gt;
        default_value = &amp;quot;yes&amp;quot;,&lt;br /&gt;
        allowed_values = {&amp;quot;yes&amp;quot;, &amp;quot;no&amp;quot;}&lt;br /&gt;
    },&lt;br /&gt;
    {&lt;br /&gt;
        type = &amp;quot;bool-setting&amp;quot;,&lt;br /&gt;
        name = &amp;quot;my-mod-kill-player-on-entity-built&amp;quot;,&lt;br /&gt;
        setting_type = &amp;quot;runtime-per-user&amp;quot;,&lt;br /&gt;
        default_value = false&lt;br /&gt;
    }&lt;br /&gt;
})&lt;br /&gt;
&lt;br /&gt;
--in control.lua:&lt;br /&gt;
script.on_init(function()&lt;br /&gt;
    if settings.global[&amp;quot;my-mod-always-difficult&amp;quot;].value == &amp;quot;yes&amp;quot; then&lt;br /&gt;
        game.difficulty_settings.recipe_difficulty = 1&lt;br /&gt;
        game.difficulty_settings.technology_difficulty = 1&lt;br /&gt;
        game.difficulty_settings.technology_price_multiplier = 4&lt;br /&gt;
    end&lt;br /&gt;
end)&lt;br /&gt;
&lt;br /&gt;
script.on_event(defines.events.on_built_entity, function(event)&lt;br /&gt;
    local setting_value = settings.get_player_settings(event.player_index)[&amp;quot;my-mod-kill-player-on-entity-built&amp;quot;].value&lt;br /&gt;
    if setting_value then&lt;br /&gt;
        game.get_player(event.player_index).die()&lt;br /&gt;
    end&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Writing to your own settings ===&lt;br /&gt;
It is possible for mods to write to their own runtime (global or per player) mod settings. This is done by writing a new [https://lua-api.factorio.com/latest/Concepts.html#ModSetting ModSetting] table to the setting.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
--in settings.lua:&lt;br /&gt;
data:extend({&lt;br /&gt;
    {&lt;br /&gt;
        type = &amp;quot;string-setting&amp;quot;,&lt;br /&gt;
        name = &amp;quot;my-mod-always-difficult&amp;quot;,&lt;br /&gt;
        setting_type = &amp;quot;runtime-global&amp;quot;,&lt;br /&gt;
        default_value = &amp;quot;yes&amp;quot;,&lt;br /&gt;
        allowed_values = {&amp;quot;yes&amp;quot;, &amp;quot;no&amp;quot;}&lt;br /&gt;
    }&lt;br /&gt;
})&lt;br /&gt;
&lt;br /&gt;
--in control.lua:&lt;br /&gt;
script.on_event(defines.events.on_rocket_launched, function()&lt;br /&gt;
    settings.global[&amp;quot;my-mod-always-difficult&amp;quot;] = {value = &amp;quot;yes&amp;quot;}&lt;br /&gt;
end)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Changing another mod&#039;s settings ===&lt;br /&gt;
After creating a setting in the settings stage, it is stored in data.raw until the end of the stage, so it can be altered from another mod.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
--in settings-updates.lua:&lt;br /&gt;
data.raw[&amp;quot;string-setting&amp;quot;][&amp;quot;my-mod-always-difficult&amp;quot;].order = &amp;quot;abc&amp;quot;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If the intent is to force the setting to be of a certain value that cannot be modified by players, the properties [[#The_hidden_property|hidden]], allowed_values and forced_value can be used. Modifying existing settings of other mods can be useful for mod packs or other mod compatibility goals.[https://forums.factorio.com/viewtopic.php?p=531322#p531322]&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
--in settings-updates.lua:&lt;br /&gt;
data.raw[&amp;quot;string-setting&amp;quot;][&amp;quot;my-mod-always-difficult&amp;quot;].hidden = true&lt;br /&gt;
data.raw[&amp;quot;string-setting&amp;quot;][&amp;quot;my-mod-always-difficult&amp;quot;].allowed_values = {&amp;quot;no&amp;quot;}&lt;br /&gt;
data.raw[&amp;quot;string-setting&amp;quot;][&amp;quot;my-mod-always-difficult&amp;quot;].default_value = &amp;quot;no&amp;quot;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Tips ===&lt;br /&gt;
* Do not conditionally &#039;require(...)&#039; things depending on mod settings: This breaks the CRC checks and people will get errors trying to use your mod in multiplayer. &#039;require(...)&#039; everything and then conditionally add the values to data.raw using the settings.&lt;br /&gt;
* You should cache the settings table inside the event you use it in. Accessing it is relatively expensive (about as expensive as accessing game.*prototypes[...]), so when accessing it mutliple times within the same event, you should set a local variable to it (within the event) to improve performance.&lt;br /&gt;
** If you want to cache startup/and runtime settings outside of events, you will have to makes sure that the local variable of settings of the setting_type &amp;quot;runtime-global&amp;quot; are updated in the &amp;lt;code&amp;gt;on_runtime_mod_setting_changed&amp;lt;/code&amp;gt; event.&lt;br /&gt;
* If you want to detect whether a certain mod is installed in the settings stage, you can use &amp;lt;code&amp;gt;if mods[&amp;quot;another-mods-name&amp;quot;] then&amp;lt;/code&amp;gt;, just like in the data stage.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
* [https://forums.factorio.com/viewtopic.php?p=207275 Forum post documenting mod settings]&lt;br /&gt;
* [https://forums.factorio.com/viewtopic.php?p=305644#p305644 per_user is not a valid property and has no effects!]&lt;br /&gt;
* [http://lua-api.factorio.com/latest/LuaSettings.html Lua api documentation on the settings table]&lt;br /&gt;
&lt;br /&gt;
[[Category:Modding]]&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Prototype/MiningDrill&amp;diff=190892</id>
		<title>Prototype/MiningDrill</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Prototype/MiningDrill&amp;diff=190892"/>
		<updated>2023-02-27T21:33:29Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: corrected base_productivity&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Prototype parent|Prototype/EntityWithOwner}}&lt;br /&gt;
A mining drill for automatically extracting resources from [[Prototype/ResourceEntity|resource entities]]. This prototype type is used by [[burner mining drill]], [[electric mining drill]] and [[pumpjack]] in vanilla.&lt;br /&gt;
&lt;br /&gt;
{{Prototype TOC|mining-drill}}&lt;br /&gt;
&lt;br /&gt;
== Mandatory properties ==&lt;br /&gt;
This prototype inherits the properties of [[Prototype/EntityWithOwner]].&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|vector_to_place_result|[[Types/vector|vector]]}}&lt;br /&gt;
The position where any item results are placed, when the mining drill is facing north (default direction). If the drill does not produce any solid items but uses a fluidbox output instead (e.g. pumpjacks), a vector of {0,0} disables the yellow arrow alt-mode indicator for the placed item location.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|resource_searching_radius|[[Types/double|double]]}}&lt;br /&gt;
The distance from the centre of the mining drill to search for resources in.&lt;br /&gt;
&lt;br /&gt;
This is 2.49 for electric mining drills (a 5x5 area) and 0.99 for burner mining drills (a 2x2 area). The drill searches resource outside its natural boundary box, which is 0.01 (the middle of the entity); making it 2.5 and 1.0 gives it another block radius.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|energy_usage|[[Types/Energy|Energy]]}}&lt;br /&gt;
The amount of energy used by the drill while mining. Can&#039;t be less than or equal to 0.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|mining_speed|[[Types/double|double]]}}&lt;br /&gt;
The speed of this drill.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|energy_source|[[Types/EnergySource|EnergySource]]}}&lt;br /&gt;
The energy source of this mining drill.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|resource_categories|[[Types/table|array]] of [[Types/string|string]]}}&lt;br /&gt;
The names of the [[Prototype/ResourceCategory]] that can be mined by this drill. For a list on built-in categories, see [[Data.raw#resource-category]].&amp;lt;/br&amp;gt;&lt;br /&gt;
Note: Categories containing resources which produce items, fluids, or items+fluids may be combined on the same entity, but may not work as expected.&amp;lt;/br&amp;gt;&lt;br /&gt;
Examples: Miner does not rotate fluid-resulting resources until depletion. Fluid isn&#039;t output (fluid resource change and fluidbox matches previous fluid). Miner with no vector_to_place_result can&#039;t output an item result and halts.&lt;br /&gt;
&lt;br /&gt;
== Optional properties ==&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|output_fluid_box|[[Types/FluidBox|FluidBox]]|optional=true}}&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|input_fluid_box|[[Types/FluidBox|FluidBox]]|optional=true}}&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|animations|[[Types/Animation4Way|Animation4Way]]|optional=true}}&lt;br /&gt;
Loaded only if &amp;lt;code&amp;gt;graphics_set&amp;lt;/code&amp;gt; does not exist.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|graphics_set|[[Types/MiningDrillGraphicsSet|MiningDrillGraphicsSet]]|optional=true}}&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|wet_mining_graphics_set|[[Types/MiningDrillGraphicsSet|MiningDrillGraphicsSet]]|optional=true}}&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|base_picture|[[Types/Sprite4Way|Sprite4Way]]|optional=true}}&lt;br /&gt;
Used by the [[pumpjack]] to have a static 4 way sprite.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|allowed_effects|[[Types/EffectTypeLimitation|EffectTypeLimitation]]|All effects are allowed|optional=true}}&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|radius_visualisation_picture|[[Types/Sprite|Sprite]]|optional=true}}&lt;br /&gt;
The sprite used to show the range of the mining drill.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|circuit_wire_max_distance|[[Types/double|double]]|0|optional=true}}&lt;br /&gt;
The maximum circuit wire distance for this entity.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|draw_copper_wires|[[Types/bool|bool]]|true|optional=true}}&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|draw_circuit_wires|[[Types/bool|bool]]|true|optional=true}}&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|base_render_layer|[[Types/RenderLayer|RenderLayer]]|&amp;quot;lower-object&amp;quot;|optional=true}}&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|base_productivity|[[Types/float|float]]|0|optional=true}}&lt;br /&gt;
Productivity bonus that this machine always has. Any values below 0 will be changed to -100, disabling any productivity, even bonus productivity from research.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|monitor_visualization_tint|[[Types/Color|Color]]|optional=true}}&lt;br /&gt;
When this mining drill is connected to the circuit network, the resource that it is reading (either the entire resource patch, or the resource in the mining area of the drill, depending on circuit network setting), is tinted in this color when mousing over the mining drill.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|circuit_wire_connection_points|[[Types/table|table]] of [[Types/WireConnectionPoint|WireConnectionPoint]]|optional=true}}&lt;br /&gt;
Mandatory if circuit_wire_max_distance  &amp;gt; 0.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|circuit_connector_sprites|[[Types/table|table]] of [[Types/CircuitConnectorSprites|CircuitConnectorSprites]]|optional=true}}&lt;br /&gt;
Mandatory if circuit_wire_max_distance  &amp;gt; 0.&lt;br /&gt;
&lt;br /&gt;
{{Prototype property|module_specification|[[Types/ModuleSpecification|ModuleSpecification]]|optional=true}}&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=User:Lovely_santa&amp;diff=186473</id>
		<title>User:Lovely santa</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=User:Lovely_santa&amp;diff=186473"/>
		<updated>2021-07-01T17:02:03Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hi, I am lovely_santa, I live in Belgium and I am a 25 year old electrical engineer. I am a casual gamer who likes to share his creations with others. I mostly play Factorio, and I try also to create some mod content for this game in my free time.&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Property_tree&amp;diff=186472</id>
		<title>Property tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Property_tree&amp;diff=186472"/>
		<updated>2021-07-01T16:57:23Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: Fixed wrong link to string datatype (https://forums.factorio.com/viewtopic.php?p=548580#p548580)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}A PropertyTree (the Factorio class name) is a recursive variant format that holds a key &amp;lt;&amp;gt; value pair where the key may be empty and the value may be only one of the following types:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|+PropertyTreeType ([[Data_types#unsigned byte|unsigned byte]])&lt;br /&gt;
|-&lt;br /&gt;
! Value !! Name&lt;br /&gt;
|-&lt;br /&gt;
| 0 || [[Property_tree#None|none]]&lt;br /&gt;
|-&lt;br /&gt;
| 1 || [[Property_tree#Bool|bool]]&lt;br /&gt;
|-&lt;br /&gt;
| 2 || [[Property_tree#Number|number]]&lt;br /&gt;
|-&lt;br /&gt;
| 3 || [[Property_tree#String|string]]&lt;br /&gt;
|-&lt;br /&gt;
| 4 || [[Property_tree#List|list]]&lt;br /&gt;
|-&lt;br /&gt;
| 5 || [[Property_tree#Dictionary|dictionary]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== The file format ==&lt;br /&gt;
&lt;br /&gt;
1 [[Data_types#unsigned byte|unsigned byte]] representing the PropertyTreeType.&lt;br /&gt;
&lt;br /&gt;
1 [[Data_types#bool|bool]] the any-type flag (currently not important outside of Factorio internals; default value is false)&lt;br /&gt;
&lt;br /&gt;
== Property Tree Type ==&lt;br /&gt;
&lt;br /&gt;
=== None ===&lt;br /&gt;
Nothing&lt;br /&gt;
&lt;br /&gt;
=== Bool ===&lt;br /&gt;
1 [[Data_types#bool|bool]]&lt;br /&gt;
&lt;br /&gt;
=== Number ===&lt;br /&gt;
1 [[Data_types#double|double]]&lt;br /&gt;
&lt;br /&gt;
=== String ===&lt;br /&gt;
1 [[Data_types#bool|bool]] if there is no string - otherwise, if there is a string:&lt;br /&gt;
&lt;br /&gt;
1 [[Data_types#Space optimized|Space optimized]] [[Data_types#unsigned int|unsigned int]] the size of the string&lt;br /&gt;
&lt;br /&gt;
N [[Data_types#byte|byte]] the string contents&lt;br /&gt;
&lt;br /&gt;
=== List ===&lt;br /&gt;
Identical to Dictionary&lt;br /&gt;
&lt;br /&gt;
=== Dictionary ===&lt;br /&gt;
1 [[Data_types#unsigned int|unsigned int]] the number of PropertyTree elements&lt;br /&gt;
&lt;br /&gt;
For each element:&lt;br /&gt;
&lt;br /&gt;
1 [[Data_types#string|string]] the dictionary element name or it can be empty if loading a list&lt;br /&gt;
&lt;br /&gt;
1 [[Property_tree]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Technical]]&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/RenderLayer&amp;diff=174475</id>
		<title>Types/RenderLayer</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/RenderLayer&amp;diff=174475"/>
		<updated>2019-07-23T21:21:09Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: Added example&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The render layer specifies the order of the sprite when rendering, most of the objects have it hardcoded in the source, but some are configurable.&lt;br /&gt;
&lt;br /&gt;
The value is specified as [[Types/uint8]] or [[Types/string]] (for example 7 and &amp;quot;decals&amp;quot; are both valid).&lt;br /&gt;
&lt;br /&gt;
The order of acceptable string values are listed from lowest to highest:&lt;br /&gt;
* water-tile&lt;br /&gt;
* ground-tile&lt;br /&gt;
* tile-transition&lt;br /&gt;
* decals&lt;br /&gt;
* lower-radius-visualization&lt;br /&gt;
* radius-visualization&lt;br /&gt;
* transport-belt-integration&lt;br /&gt;
* resource&lt;br /&gt;
* building-smoke&lt;br /&gt;
* decorative&lt;br /&gt;
* ground-patch&lt;br /&gt;
* ground-patch-higher&lt;br /&gt;
* ground-patch-higher2&lt;br /&gt;
* remnants&lt;br /&gt;
* floor&lt;br /&gt;
* transport-belt&lt;br /&gt;
* transport-belt-endings&lt;br /&gt;
* corpse&lt;br /&gt;
* floor-mechanics&lt;br /&gt;
* item&lt;br /&gt;
* lower-object&lt;br /&gt;
* transport-belt-circuit-connector&lt;br /&gt;
* lower-object-above-shadow&lt;br /&gt;
* object&lt;br /&gt;
* higher-object-under&lt;br /&gt;
* higher-object-above&lt;br /&gt;
* item-in-inserter-hand&lt;br /&gt;
* wires&lt;br /&gt;
* wires-above&lt;br /&gt;
* entity-info-icon&lt;br /&gt;
* entity-info-icon-above&lt;br /&gt;
* explosion&lt;br /&gt;
* projectile&lt;br /&gt;
* smoke&lt;br /&gt;
* air-object&lt;br /&gt;
* air-entity-info-icon&lt;br /&gt;
* light-effect&lt;br /&gt;
* selection-box&lt;br /&gt;
* collision-selection-box&lt;br /&gt;
* arrow&lt;br /&gt;
* cursor&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/RenderLayer&amp;diff=174474</id>
		<title>Types/RenderLayer</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/RenderLayer&amp;diff=174474"/>
		<updated>2019-07-23T21:19:49Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: Types/RenderLayer can be represented as a value in range 0-255 as well&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The render layer specifies the order of the sprite when rendering, most of the objects have it hardcoded in the source, but some are configurable.&lt;br /&gt;
&lt;br /&gt;
The value is specified as [[Types/uint8]] or [[Types/string]].&lt;br /&gt;
&lt;br /&gt;
The order of acceptable string values are listed from lowest to highest:&lt;br /&gt;
* water-tile&lt;br /&gt;
* ground-tile&lt;br /&gt;
* tile-transition&lt;br /&gt;
* decals&lt;br /&gt;
* lower-radius-visualization&lt;br /&gt;
* radius-visualization&lt;br /&gt;
* transport-belt-integration&lt;br /&gt;
* resource&lt;br /&gt;
* building-smoke&lt;br /&gt;
* decorative&lt;br /&gt;
* ground-patch&lt;br /&gt;
* ground-patch-higher&lt;br /&gt;
* ground-patch-higher2&lt;br /&gt;
* remnants&lt;br /&gt;
* floor&lt;br /&gt;
* transport-belt&lt;br /&gt;
* transport-belt-endings&lt;br /&gt;
* corpse&lt;br /&gt;
* floor-mechanics&lt;br /&gt;
* item&lt;br /&gt;
* lower-object&lt;br /&gt;
* transport-belt-circuit-connector&lt;br /&gt;
* lower-object-above-shadow&lt;br /&gt;
* object&lt;br /&gt;
* higher-object-under&lt;br /&gt;
* higher-object-above&lt;br /&gt;
* item-in-inserter-hand&lt;br /&gt;
* wires&lt;br /&gt;
* wires-above&lt;br /&gt;
* entity-info-icon&lt;br /&gt;
* entity-info-icon-above&lt;br /&gt;
* explosion&lt;br /&gt;
* projectile&lt;br /&gt;
* smoke&lt;br /&gt;
* air-object&lt;br /&gt;
* air-entity-info-icon&lt;br /&gt;
* light-effect&lt;br /&gt;
* selection-box&lt;br /&gt;
* collision-selection-box&lt;br /&gt;
* arrow&lt;br /&gt;
* cursor&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Console&amp;diff=174080</id>
		<title>Console</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Console&amp;diff=174080"/>
		<updated>2019-07-04T11:03:32Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: changed 2nd part of the code to also have the radius variable to be more inline with the first part.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
== Overview ==&lt;br /&gt;
The &#039;&#039;&#039;Console&#039;&#039;&#039; is Factorio&#039;s command-line interface.&lt;br /&gt;
&lt;br /&gt;
The in-game console is used for:&lt;br /&gt;
&lt;br /&gt;
* Chatting with other players&lt;br /&gt;
* Running commands / scripts / cheats&lt;br /&gt;
* Occasional status updates&lt;br /&gt;
&lt;br /&gt;
There are three types of commands:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[#Normal commands|Normal]]&#039;&#039;&#039; - Display information about the game and customize your experience.&lt;br /&gt;
* &#039;&#039;&#039;[[#Multiplayer commands|Multiplayer]]&#039;&#039;&#039; - Message filtering, banning users, etc.&lt;br /&gt;
* &#039;&#039;&#039;[[#Scripting and cheat commands|Scripting/Cheating]]&#039;&#039;&#039; - Run small Lua scripts (but they &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;disable achievements for the save game&amp;lt;/span&amp;gt;)&lt;br /&gt;
&lt;br /&gt;
=== Using the console ===&lt;br /&gt;
The console display can be toggled with the {{keybinding|/}} (slash) or {{keybinding|~}} (tilde) keys.&lt;br /&gt;
&lt;br /&gt;
You can customize the keys via &#039;&#039;&#039;Options Menu → Keyboard → Toggle Lua console&#039;&#039;&#039;.&lt;br /&gt;
When the console is open, you&#039;ll see a blinking cursor at the bottom of the screen; type your message or command and hit &#039;&#039;&#039;Return&#039;&#039;&#039; to send it (this will also close the console).&lt;br /&gt;
Documentation about message and command prefixes can be found further down this page.&lt;br /&gt;
&lt;br /&gt;
The console supports [[rich text]] tags. These tags are useful for sharing blueprints, marking map locations in chat or adding icons to map markers and train stations. Ctrl+alt clicking the map or ground will automatically insert a gps tag and post it into the console. Shift clicking most things with the console open will insert a tag for that thing into chat. &lt;br /&gt;
&lt;br /&gt;
When console is closed, only the most recent messages/commands will be displayed, but they will gradually fade away (opening the console will immediately re-display all recent messages).&lt;br /&gt;
Note that by default, all executed commands are made visible to all users. You can set the fade out time via &#039;&#039;&#039;Options Menu → Other Settings → Message Delay&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
If you want to immediately hide the console, open the console and then press &#039;&#039;&#039;Escape&#039;&#039;&#039; key (or press &#039;&#039;&#039;Return&#039;&#039;&#039; without entering any message/command).&lt;br /&gt;
This not only closes the console, but it also hides all the recent messages/commands.&lt;br /&gt;
The console can be cleared with the &#039;&#039;&#039;/clear&#039;&#039;&#039; command.&lt;br /&gt;
&lt;br /&gt;
Note that the console can also accept raw Lua code as well as game commands.&lt;br /&gt;
&lt;br /&gt;
=== Console history ===&lt;br /&gt;
&lt;br /&gt;
The console has an inbuilt history; it&#039;s a bit like a text editor where only one line of text is displayed at a time.&lt;br /&gt;
&lt;br /&gt;
Use the {{keybinding|&amp;amp;uarr;}} and {{keybinding|&amp;amp;darr;}} keys to scroll through the console history.&lt;br /&gt;
&lt;br /&gt;
Use the {{keybinding|&amp;amp;larr;}} and {{keybinding|&amp;amp;rarr;}} keys to cursor through the currently displayed message or command, which you can edit (delete, insert, etc.) and resend (by pressing &#039;&#039;&#039;Return&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
The {{keybinding|Tab}} key will auto-complete commands and player ids.&lt;br /&gt;
&lt;br /&gt;
== Normal commands ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! style=&amp;quot;width:25%&amp;quot;| Command&lt;br /&gt;
! style=&amp;quot;width:25%&amp;quot;| Example&lt;br /&gt;
! style=&amp;quot;width:46%&amp;quot;| Description&lt;br /&gt;
! style=&amp;quot;width:4%&amp;quot;| Admin only&lt;br /&gt;
|-&lt;br /&gt;
| /alerts &amp;lt;enable/disable/mute/unmute&amp;gt; &amp;lt;alert&amp;gt;&lt;br /&gt;
| /alerts disable turret_fire&lt;br /&gt;
| Enables, disables, mutes, or unmutes the given  [[alerts|alert]] type. Available alerts: entity_destroyed, entity_under_attack, not_enough_construction_robots, no_material_for_construction, not_enough_repair packs, turret_fire, custom, no_storage, train_out_of_fuel, fluid_mixing.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /clear&lt;br /&gt;
| /clear&lt;br /&gt;
| Clears the console.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /color &amp;lt;color&amp;gt;&lt;br /&gt;
| /color 20 255 255 100&lt;br /&gt;
| Changes your color. Can either be one of the pre-defined colors or [[:Wikipedia:RGBA_color_space|RGBA value]] in the format of “# # # #”. Available colors: default, red, green, blue, orange, yellow, pink, purple, white, black, gray, brown, cyan, acid.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /evolution&lt;br /&gt;
| /evolution&lt;br /&gt;
| Prints info about the alien evolution factor.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /help [command]&lt;br /&gt;
| /help&lt;br /&gt;
| Prints a list of available commands, the optional argument can specify the command that should be described.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /h [command]&lt;br /&gt;
| /h&lt;br /&gt;
| Same as /help.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /mute-programmable-speaker &amp;lt;mute/unmute&amp;gt; &amp;lt;local/everyone&amp;gt;&lt;br /&gt;
| /mute-programmable-speaker mute local&lt;br /&gt;
| Mutes or unmutes the global sounds created by the Programmable Speaker. Use “local” to mute just the local client. Admins can use “everyone” to mute the sounds for everyone on the server.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /perf-avg-frames &amp;lt;number&amp;gt;&lt;br /&gt;
| /perf-avg-frames 100&lt;br /&gt;
| Number of ticks/updates used to average performance counters. Default is 100. Value of 5-10 is recommended for fast convergence, but numbers will jitter more rapidly.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /permissions&lt;br /&gt;
| /permissions&lt;br /&gt;
| Opens the permissions GUI.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /screenshot [x resolution] [y resolution] [zoom]&lt;br /&gt;
| /screenshot&lt;br /&gt;
| Takes a screenshot with the GUI hidden, centered on the player. It is saved in the &amp;quot;script-output&amp;quot; subfolder of your [[User data directory]].  Resolution is optional and defaults to the current window size. Zoom is optional and defaults to 1.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /seed&lt;br /&gt;
| /seed&lt;br /&gt;
| Prints the starting map seed.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /time&lt;br /&gt;
| /time&lt;br /&gt;
| Prints info about how old the map is.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /toggle-action-logging&lt;br /&gt;
| /toggle-action-logging&lt;br /&gt;
| Toggles logging all input actions performed by the game. This value isn’t persisted between game restarts and only affects your local game in multiplayer sessions.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /toggle-heavy-mode&lt;br /&gt;
| /toggle-heavy-mode&lt;br /&gt;
| Used to investigate [[Desynchronization#Using_heavy_mode_command|desyncs]]. Will slow down the game and make multiplayer unplayable.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /toggle-rockets-sent-gui&lt;br /&gt;
| /toggle-rockets-sent-gui&lt;br /&gt;
| Toggles if the rockets sent button is shown in the upper left corner of the screen.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /unlock-shortcut-bar&lt;br /&gt;
| /unlock-shortcut-bar&lt;br /&gt;
| Unlocks all shortcut bar items.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /version&lt;br /&gt;
| /version&lt;br /&gt;
| Prints the current game version.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Multiplayer commands ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! style=&amp;quot;width:25%&amp;quot;| Command&lt;br /&gt;
! style=&amp;quot;width:25%&amp;quot;| Example&lt;br /&gt;
! style=&amp;quot;width:46%&amp;quot;| Description&lt;br /&gt;
! style=&amp;quot;width:4%&amp;quot;| Admin only&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;message&amp;gt;&lt;br /&gt;
| Hello team!&lt;br /&gt;
| Console input that does not start with {{keybinding|/}} is shown as a chat message to your team.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /admin&lt;br /&gt;
| /admin&lt;br /&gt;
| Opens the player management GUI.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /admins&lt;br /&gt;
| /admins&lt;br /&gt;
| Prints a list of game admins.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /ban &amp;lt;player&amp;gt; &amp;lt;reason&amp;gt;&lt;br /&gt;
| /ban xTROLLx Throwing grenades in base&lt;br /&gt;
| Bans the specified player.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /banlist &amp;lt;add/remove/get/clear&amp;gt; &amp;lt;player&amp;gt;&lt;br /&gt;
| /banlist get&lt;br /&gt;
| Adds or removes a player from the banlist. Same as /ban or /unban.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /config &amp;lt;get/set&amp;gt; &amp;lt;option&amp;gt; &amp;lt;value&amp;gt;&lt;br /&gt;
| /config set password hunter2&lt;br /&gt;
| Gets or sets various multiplayer game settings. Available configs are: afk-auto-kick, allow-commands, allow-debug-settings, autosave-interval, autosave-only-on-server, ignore-player-limit-for-returning-players, max-players, max-upload-speed, only-admins-can-pause, password, require-user-verification, visibility-lan, visibility-public.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /delete-blueprint-library &amp;lt;player&amp;gt;&lt;br /&gt;
| /delete-blueprint-library everybody confirm&lt;br /&gt;
| Deletes the blueprint library storage for the given offline player from the save file. Enter “everybody confirm” to delete the storage of all offline players.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /demote &amp;lt;player&amp;gt;&lt;br /&gt;
| /demote AzureDiamond&lt;br /&gt;
| Demotes the player from admin.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /ignore &amp;lt;player&amp;gt;&lt;br /&gt;
| /ignore Cthon98&lt;br /&gt;
| Prevents the chat from showing messages from this player. Admin messages are still shown.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /ignores&lt;br /&gt;
| /ignores&lt;br /&gt;
| Prints a list of ignored players.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /kick &amp;lt;player&amp;gt; &amp;lt;reason&amp;gt;&lt;br /&gt;
| /kick xTROLLx Throwing grenades in base&lt;br /&gt;
| Kicks the specified player.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /mute &amp;lt;player&amp;gt;&lt;br /&gt;
| /mute Cthon98&lt;br /&gt;
| Prevents the player from saying anything in chat.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /mutes&lt;br /&gt;
| /mutes&lt;br /&gt;
| All players that are muted (can’t talk in chat).&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /open &amp;lt;player&amp;gt;&lt;br /&gt;
| /open AzureDiamond&lt;br /&gt;
| Opens another player’s inventory.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /o &amp;lt;player&amp;gt;&lt;br /&gt;
| /o AzureDiamond&lt;br /&gt;
| Same as /open.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /players [online/o/count/c]&lt;br /&gt;
| /players&lt;br /&gt;
| Prints a list of players in the game. (parameter online/o, it prints only players that are online, count/c prints only count)&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /promote &amp;lt;player&amp;gt;&lt;br /&gt;
| /promote AzureDiamond&lt;br /&gt;
| Promotes the player to admin.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /purge &amp;lt;player&amp;gt;&lt;br /&gt;
| /purge Cthon98&lt;br /&gt;
| Clears all the messages from this player from the chat log.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /reply &amp;lt;message&amp;gt;&lt;br /&gt;
| /reply oh, really?&lt;br /&gt;
| Replies to the last player that whispered to you.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /r &amp;lt;message&amp;gt;&lt;br /&gt;
| /r oh, really?&lt;br /&gt;
| Same as /reply.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /server-save&lt;br /&gt;
| /server-save&lt;br /&gt;
| Saves the game on the server in a multiplayer game.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /shout &amp;lt;message&amp;gt;&lt;br /&gt;
| /shout Hello world!&lt;br /&gt;
| Sends a message to all players including other forces.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /s &amp;lt;message&amp;gt;&lt;br /&gt;
| /s Hello world!&lt;br /&gt;
| Same as /shout.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /swap-players &amp;lt;player&amp;gt; [player]&lt;br /&gt;
| /swap-players AzureDiamond&lt;br /&gt;
| Swaps your character with the given player’s character, or if two players are given swaps the two player characters.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /unban &amp;lt;player&amp;gt;&lt;br /&gt;
| /unban xTROLLx&lt;br /&gt;
| Unbans the specified player.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /unignore &amp;lt;player&amp;gt;&lt;br /&gt;
| /unignore Cthon98&lt;br /&gt;
| Allows the chat to show messages from this player.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /unmute &amp;lt;player&amp;gt;&lt;br /&gt;
| /unmute Cthon98&lt;br /&gt;
| Allows the player to talk in chat again.&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| /whisper &amp;lt;player&amp;gt; &amp;lt;message&amp;gt;&lt;br /&gt;
| /whisper AzureDiamond thats what I see&lt;br /&gt;
| Sends a message to the specified player.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /w &amp;lt;player&amp;gt; &amp;lt;message&amp;gt;&lt;br /&gt;
| /w AzureDiamond thats what I see&lt;br /&gt;
| Same as /whisper.&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| /whitelist &amp;lt;add/remove/get/clear&amp;gt; [player]&lt;br /&gt;
| /whitelist get&lt;br /&gt;
| Adds or removes a player from the whitelist, where only whitelisted players can join the game. Enter nothing for “player” when using “get” to print a list of all whitelisted players. An empty whitelist disables the whitelist functionality allowing anyone to join.&lt;br /&gt;
| No&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Scripting and cheat commands ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Command&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| /cheat &amp;lt;all&amp;gt;&lt;br /&gt;
| Researches all technologies and enables cheat mode. Using the &#039;&#039;&#039;all&#039;&#039;&#039; option also gives the player some additional items.&lt;br /&gt;
|-&lt;br /&gt;
| /command &amp;lt;command&amp;gt;&lt;br /&gt;
| Executes a Lua command.&lt;br /&gt;
|-&lt;br /&gt;
| /c &amp;lt;command&amp;gt;&lt;br /&gt;
| Executes a Lua command.&lt;br /&gt;
|-&lt;br /&gt;
| /editor&lt;br /&gt;
| Toggles the map editor.&lt;br /&gt;
|-&lt;br /&gt;
| /measured-command &amp;lt;command&amp;gt;&lt;br /&gt;
| Executes a Lua command and measures time it took.&lt;br /&gt;
|-&lt;br /&gt;
| /silent-command &amp;lt;command&amp;gt;&lt;br /&gt;
| Executes a Lua command without printing it to the console.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
This is a very powerful feature, which also allows cheating, and as such &amp;lt;span style=&amp;quot;color:#FF0000&amp;quot;&amp;gt;achievements will be permanently disabled for the save&amp;lt;/span&amp;gt; as soon as you use a script command.&lt;br /&gt;
&lt;br /&gt;
== Basic example scripts ==&lt;br /&gt;
&lt;br /&gt;
=== Use it as calculator ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.print(1234*5678)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Zoom beyond normal bounds ===&lt;br /&gt;
Note that zooming too far out can cause performance hits. Be careful.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.zoom=0.1&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Mine faster ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.manual_mining_speed_modifier=1000&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Craft faster ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.manual_crafting_speed_modifier=1000&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Unlock and research all technologies ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.research_all_technologies()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Undo this with the command in the next section.&lt;br /&gt;
&lt;br /&gt;
=== Unresearch all technologies ===&lt;br /&gt;
This does not reset manually applied bonuses&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c for _, tech in pairs(game.player.force.technologies) do &lt;br /&gt;
	tech.researched=false&lt;br /&gt;
	game.player.force.set_saved_technology_progress(tech, 0)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Reset your force ===&lt;br /&gt;
This resets all data for your force, including kill and production statistics, technologies, bonuses and charting status.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.reset()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Always show rail block visualization ===&lt;br /&gt;
Permanently show the rail block visualization instead of only when holding a rail signal. Disable by replacing true with false.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.game_view_settings.show_rail_block_visualisation = true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Inventory manipulation scripts ==&lt;br /&gt;
&lt;br /&gt;
=== Cheat mode ===&lt;br /&gt;
Allows for infinite free crafting. Disable by replacing true with false.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.cheat_mode=true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Refill resources (refill oil, iron etc.) ===&lt;br /&gt;
While holding the cursor over a resource tile in-game&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.selected.amount=7500&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alternatively you can refill all resources in the map with the following command. Change ore.amount to the desired value.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c surface = game.player.surface&lt;br /&gt;
for _, ore in pairs(surface.find_entities_filtered({type=&amp;quot;resource&amp;quot;})) do&lt;br /&gt;
    ore.amount = 10000&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Add items to the player&#039;s inventory ===&lt;br /&gt;
Replace iron-plate with the [[data.raw|internal name]] of the item desired.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.insert{name=&amp;quot;iron-plate&amp;quot;, count=100}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For instance, here&#039;s a stack of the god-mode energy system interface:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.insert{name=&amp;quot;electric-energy-interface&amp;quot;}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Add a powerful armor with equipment and some tools for construction:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c	local player = game.player&lt;br /&gt;
player.insert{name=&amp;quot;power-armor-mk2&amp;quot;, count = 1}&lt;br /&gt;
local p_armor = player.get_inventory(5)[1].grid&lt;br /&gt;
	p_armor.put({name = &amp;quot;fusion-reactor-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;fusion-reactor-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;fusion-reactor-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;exoskeleton-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;exoskeleton-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;exoskeleton-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;exoskeleton-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;energy-shield-mk2-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;energy-shield-mk2-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;personal-roboport-mk2-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;night-vision-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;battery-mk2-equipment&amp;quot;})&lt;br /&gt;
	p_armor.put({name = &amp;quot;battery-mk2-equipment&amp;quot;})&lt;br /&gt;
player.insert{name=&amp;quot;construction-robot&amp;quot;, count = 25}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== World manipulation scripts ==&lt;br /&gt;
&lt;br /&gt;
=== Reveal the map around the player ===&lt;br /&gt;
&lt;br /&gt;
Reveals the map around the player, similar to a [[radar]].&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local radius=150&lt;br /&gt;
game.player.force.chart(game.player.surface, {{game.player.position.x-radius, game.player.position.y-radius}, {game.player.position.x+radius, game.player.position.y+radius}})&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
or from start position&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local radius=150&lt;br /&gt;
game.player.force.chart(game.player.surface, {{x = -radius, y = -radius}, {x = radius, y = radius}})&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
Change 150 to the desired radius, higher values take longer.&lt;br /&gt;
&lt;br /&gt;
=== Hide revealed map ===&lt;br /&gt;
&lt;br /&gt;
Hides all revealed chunks, inverted map revealing.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface = game.player.surface&lt;br /&gt;
local force = game.player.force&lt;br /&gt;
for chunk in surface.get_chunks() do&lt;br /&gt;
  force.unchart_chunk({x = chunk.x, y = chunk.y}, surface)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Delete chunks ===&lt;br /&gt;
If much of the map is revealed, it increases the size of the save file. The following command cancels the generation of all chunks that are currently queued for generation and removes chunks outside a 32 chunks radius around 0,0. Note that this will remove player entities if there are any on these chunks.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface = game.player.surface;&lt;br /&gt;
game.player.force.cancel_charting(surface); &lt;br /&gt;
local chunk_radius = 32;&lt;br /&gt;
for chunk in surface.get_chunks() do&lt;br /&gt;
  if (chunk.x &amp;lt; -chunk_radius or chunk.x &amp;gt; chunk_radius or chunk.y &amp;lt; -chunk_radius or chunk.y &amp;gt; chunk_radius) then&lt;br /&gt;
    surface.delete_chunk(chunk)&lt;br /&gt;
  end&lt;br /&gt;
end &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Turn off night ===&lt;br /&gt;
Enables eternal day.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.surface.always_day=true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Change game speed ===&lt;br /&gt;
0.5 is half speed, 1 is default, 2 is double speed, etc. Minimum is 0.01. This can be used for a lot of things like when you know you will have to wait for long periods of time for something to complete. Increasing will decrease performance, be careful.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.speed=X&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Expensive (marathon) or normal mode ===&lt;br /&gt;
To change from normal to expensive mode preset (this changes the research cost and intermediate product cost):&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.difficulty_settings.recipe_difficulty=1&lt;br /&gt;
game.difficulty_settings.technology_difficulty=1&lt;br /&gt;
game.difficulty_settings.technology_price_multiplier=4&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To change back to normal:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.difficulty_settings.recipe_difficulty=0&lt;br /&gt;
game.difficulty_settings.technology_difficulty=0&lt;br /&gt;
game.difficulty_settings.technology_price_multiplier=1&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Freeze time ===&lt;br /&gt;
Stops the advancement of the time if you replace &amp;quot;BOOL&amp;quot; with &amp;quot;true&amp;quot; or unfreezes it if you replace it with &amp;quot;false&amp;quot;.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.surface.freeze_daytime=BOOL&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Remove all pollution ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.surface.clear_pollution()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Completely turn off pollution ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c for _, surface in pairs(game.surfaces) do&lt;br /&gt;
  surface.clear_pollution()&lt;br /&gt;
end&lt;br /&gt;
game.map_settings.pollution.enabled = false&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Add a lot of pollution ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.surface.pollute(game.player.position, 1000000)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Where speakers are, by who ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c speakers = game.player.surface.find_entities_filtered{force = game.player.force, type=&amp;quot;programmable-speaker&amp;quot;}&lt;br /&gt;
for key, speaker in pairs(speakers) do&lt;br /&gt;
    game.player.print(speaker.last_user.name .. &amp;quot; placed a speaker at X=&amp;quot; .. speaker.position.x .. &amp;quot;, Y=&amp;quot; .. speaker.position.y)&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Disable friendly fire for your force ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.friendly_fire = false&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Add new resource patch ===&lt;br /&gt;
This creates a new 11×11 patch of resources, centered on the player character, where the ground is not water.&lt;br /&gt;
The patch it creates is perfectly square but it randomizes the amount similar to natural generation, with fewer ore at the edges and more ore in the center.&lt;br /&gt;
The default numbers result in a patch with 2500-3000 ore.&lt;br /&gt;
&lt;br /&gt;
If you want a larger patch, change &amp;quot;local size = 5&amp;quot; to a larger number.&lt;br /&gt;
A larger patch will have exponentially more ore.&lt;br /&gt;
Entering a number above 30 is not recommended.&lt;br /&gt;
&lt;br /&gt;
If you want a richer patch, change &amp;quot;local density = 10&amp;quot; to a larger number.&lt;br /&gt;
Entering a very large number shouldn&#039;t hurt anything but you probably don&#039;t need to go above 100.&lt;br /&gt;
&lt;br /&gt;
To choose which resource is spawned, change &amp;quot;stone&amp;quot; near the bottom to &amp;quot;iron-ore&amp;quot;, &amp;quot;copper-ore&amp;quot;, &amp;quot;coal&amp;quot;, or &amp;quot;uranium-ore&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface=game.player.surface&lt;br /&gt;
local ore=nil&lt;br /&gt;
local size=5&lt;br /&gt;
local density=10&lt;br /&gt;
for y=-size, size do&lt;br /&gt;
	for x=-size, size do&lt;br /&gt;
		a=(size+1-math.abs(x))*10&lt;br /&gt;
		b=(size+1-math.abs(y))*10&lt;br /&gt;
		if a&amp;lt;b then&lt;br /&gt;
			ore=math.random(a*density-a*(density-8), a*density+a*(density-8))&lt;br /&gt;
		end&lt;br /&gt;
		if b&amp;lt;a then&lt;br /&gt;
			ore=math.random(b*density-b*(density-8), b*density+b*(density-8))&lt;br /&gt;
		end&lt;br /&gt;
		if surface.get_tile(game.player.position.x+x, game.player.position.y+y).collides_with(&amp;quot;ground-tile&amp;quot;) then&lt;br /&gt;
			surface.create_entity({name=&amp;quot;stone&amp;quot;, amount=ore, position={game.player.position.x+x, game.player.position.y+y}})&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Remove resources around the player ===&lt;br /&gt;
Removes all resource patches from the ground in a 50 x 50 area around the player.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface=game.player.surface&lt;br /&gt;
local size=50&lt;br /&gt;
local pos=game.player.position&lt;br /&gt;
&lt;br /&gt;
for _, e in pairs(surface.find_entities_filtered{area={{pos.x-size, pos.y-size},{pos.x+size, pos.y+size}}, type=&amp;quot;resource&amp;quot;}) &lt;br /&gt;
	do e.destroy() &lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Add new oil patch ===&lt;br /&gt;
This creates 9 crude oil patches in a 3×3 square.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c for y=0,2 do&lt;br /&gt;
	for x=0,2 do&lt;br /&gt;
		game.player.surface.create_entity({name=&amp;quot;crude-oil&amp;quot;, amount=100000, position={game.player.position.x+x*7-7, game.player.position.y+y*7-7}})&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or randomly without any collision:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local position=nil&lt;br /&gt;
for i=1,9 do&lt;br /&gt;
	position=game.player.surface.find_non_colliding_position(&amp;quot;crude-oil&amp;quot;, game.player.position, 0, i/2+1.5)&lt;br /&gt;
	if position then &lt;br /&gt;
		game.player.surface.create_entity({name=&amp;quot;crude-oil&amp;quot;, amount=100000, position=position})&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Create 10 fishes ===&lt;br /&gt;
This creates 10 fishes around of player. The player must be on the water edge.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local player = game.player&lt;br /&gt;
local surface = player.surface&lt;br /&gt;
for i = 1, 10 do&lt;br /&gt;
  local position = surface.find_non_colliding_position(&#039;fish&#039;, player.position, 10, 1)&lt;br /&gt;
  if not position then return end&lt;br /&gt;
  surface.create_entity {name = &#039;fish&#039;, position = position}&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Count entities ===&lt;br /&gt;
Counts all entities whose name includes the string in local entity.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local entity=&amp;quot;belt&amp;quot;&lt;br /&gt;
local surface=game.player.surface&lt;br /&gt;
local count=0&lt;br /&gt;
for key, ent in pairs(surface.find_entities_filtered({force=game.player.force})) do&lt;br /&gt;
	if string.find(ent.name,entity) then&lt;br /&gt;
		count=count+1&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
game.player.print(count)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Emptying all pipes, underground pipes and pumps ===&lt;br /&gt;
Useful when pipes contain a fluid you dont want.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface = game.player.surface&lt;br /&gt;
local deleted=0&lt;br /&gt;
for key, entity in pairs(surface.find_entities_filtered({force=game.player.force})) do&lt;br /&gt;
	if string.find(entity.name, &amp;quot;pipe&amp;quot;) or &lt;br /&gt;
		string.find(entity.name, &amp;quot;pump&amp;quot;) &lt;br /&gt;
	then&lt;br /&gt;
		for i=1,#entity.fluidbox do&lt;br /&gt;
			deleted = deleted + 1&lt;br /&gt;
			entity.fluidbox[i] = nil;&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
game.player.print(&amp;quot;Fluids removed from &amp;quot;..deleted ..&amp;quot; entities&amp;quot;)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Turn off cliff generation ===&lt;br /&gt;
Sets size to &amp;quot;none&amp;quot;. Only effective on chunks that are generated after using this command. Use [[#Remove all cliffs]] to delete existing cliffs.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local mgs = game.player.surface.map_gen_settings&lt;br /&gt;
mgs.cliff_settings.cliff_elevation_0 = 1024&lt;br /&gt;
game.player.surface.map_gen_settings = mgs&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Remove all cliffs ===&lt;br /&gt;
Removes all cliffs existing cliffs from the world. Use [[#Turn off cliff generation]] to turn off cliff generation in new chunks.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c for _, v in pairs(game.player.surface.find_entities_filtered{type=&amp;quot;cliff&amp;quot;}) do&lt;br /&gt;
  v.destroy()&lt;br /&gt;
end&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Delete all decoratives ===&lt;br /&gt;
Delete the decoratives that can be found in the world.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface = game.player.surface&lt;br /&gt;
for c in surface.get_chunks() do&lt;br /&gt;
	surface.destroy_decoratives({{c.x*32, c.y*32}, {c.x*32+32, c.y*32+32}})&lt;br /&gt;
end&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Change map generation settings ===&lt;br /&gt;
This allows to change the map generation settings for new chunks; it does not alter already generated chunks. [[#Delete chunks|Deleted chunks]] are affected by the setting change because they are newly generated when they get explored again.&lt;br /&gt;
&lt;br /&gt;
To change resource generation settings, replace &amp;quot;iron-ore&amp;quot; with the [[Data.raw#resource|resource]] that should be changed and replace &amp;quot;very-high&amp;quot; with the desired [https://lua-api.factorio.com/latest/Concepts.html#MapGenSize MapGenSize] in the following command. Replace &amp;quot;iron-ore&amp;quot; with &amp;quot;enemy-base&amp;quot; to change the enemy base generation settings. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface = game.player.surface&lt;br /&gt;
local resource = &amp;quot;iron-ore&amp;quot;&lt;br /&gt;
local autoplace = surface.map_gen_settings.autoplace_controls&lt;br /&gt;
autoplace[resource].size = &amp;quot;very-high&amp;quot;&lt;br /&gt;
autoplace[resource].frequency = &amp;quot;very-high&amp;quot;&lt;br /&gt;
autoplace[resource].richness = &amp;quot;very-high&amp;quot;&lt;br /&gt;
surface.map_gen_settings.autoplace_controls = autoplace&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To change water generation settings, replace &amp;quot;very-high&amp;quot; with the desired [https://lua-api.factorio.com/latest/Concepts.html#MapGenSize MapGenSize] in the following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface = game.player.surface&lt;br /&gt;
local mgs = surface.map_gen_settings&lt;br /&gt;
mgs.water = &amp;quot;very-high&amp;quot; --[[ size]]&lt;br /&gt;
mgs.terrain_segmentation  = &amp;quot;very-high&amp;quot; --[[ frequency]]&lt;br /&gt;
surface.map_gen_settings = mgs &amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Enemy/evolution scripts ==&lt;br /&gt;
&lt;br /&gt;
=== Set evolution factor ===&lt;br /&gt;
Ranges from 0 (new game) to 1.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.forces[&amp;quot;enemy&amp;quot;].evolution_factor=X&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Disable time-based evolution &amp;amp; increases pollution-based evolution ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.map_settings.enemy_evolution.time_factor=0&lt;br /&gt;
/c game.map_settings.enemy_evolution.pollution_factor=game.map_settings.enemy_evolution.pollution_factor*2&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;2&amp;quot; at the end of the last command will double the default pollution factor. You can substitute another number to increase (or decrease) the pollution factor further.&lt;br /&gt;
&lt;br /&gt;
=== Kill all biters on the &amp;quot;enemy&amp;quot; force ===&lt;br /&gt;
Note that this will kill only mobile units, spawners will not be killed.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.forces[&amp;quot;enemy&amp;quot;].kill_all_units()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Kill all enemies ===&lt;br /&gt;
This will kill all biters, bases and worms. Anything that is an enemy will be completely destroyed. This only affects enemies in the explored world, so any unexplored parts of the map which still need to be generated will still have enemies. You can [[#Prevent biters being on newly generated chunks|prevent biters being on newly generated chunks]] if desired.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface=game.player.surface&lt;br /&gt;
for key, entity in pairs(surface.find_entities_filtered({force=&amp;quot;enemy&amp;quot;})) do&lt;br /&gt;
	entity.destroy()&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Kill all nearby enemies ===&lt;br /&gt;
&lt;br /&gt;
This will kill all biters, bases and worms in a configurable radius. The default, 250 tiles, is about two zoomed-out screen widths on full HD. After destruction, it shows how many objects were destroyed.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local radius = 250&lt;br /&gt;
local surface=game.player.surface&lt;br /&gt;
local pp = game.player.position&lt;br /&gt;
local cnt = 0&lt;br /&gt;
for key, entity in pairs(surface.find_entities_filtered({force=&amp;quot;enemy&amp;quot;})) do&lt;br /&gt;
    if entity.position.x &amp;gt; pp.x - radius and entity.position.x &amp;lt; pp.x + radius&lt;br /&gt;
        and entity.position.y &amp;gt; pp.y - radius and entity.position.y &amp;lt; pp.y + radius then&lt;br /&gt;
        cnt = cnt+1&lt;br /&gt;
        entity.destroy()&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
game.player.print(cnt)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Enable/Disable peaceful mode ===&lt;br /&gt;
Enabling peaceful mode prevents biter attacks until provoked. Substitute true for false to disable. Already existing biters are not affected by this command so attacks could continue for a while after activating peaceful mode.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.surface.peaceful_mode = true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Enable/Disable biter expansion ===&lt;br /&gt;
Biter expansion allows biters to create new nests, it is enabled by default. Substitute true for false to disable.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.map_settings.enemy_expansion.enabled = true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Prevent biters being on newly generated chunks ===&lt;br /&gt;
On newly generated chunks no biters will be present, however all current biters will remain unaffected. Equivalent of setting the Enemy Base Size to None under the Terrain settings during map generation but achieved mid game by [[#Change map generation settings|changing map generation settings]].&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local surface = game.player.surface&lt;br /&gt;
local mgs = surface.map_gen_settings&lt;br /&gt;
mgs.autoplace_controls[&amp;quot;enemy-base&amp;quot;].size = &amp;quot;none&amp;quot;&lt;br /&gt;
surface.map_gen_settings = mgs&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Player character scripts ==&lt;br /&gt;
Commands concerning the player directly.&lt;br /&gt;
=== Get player position ===&lt;br /&gt;
Prints coordinates of your current position.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.print(game.player.position.x .. &amp;quot;, &amp;quot; .. game.player.position.y)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Teleport player ===&lt;br /&gt;
Moves the player to the specified location. You should be able to teleport to a specific player if you obtain their coordinates via them executing the previous command and giving them to you.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.teleport({X, Y})&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To teleport to the world&#039;s origin, use 0,0.&lt;br /&gt;
&lt;br /&gt;
=== Enable god mode ===&lt;br /&gt;
God mode removes your player character allowing you to fly over obstacles and take no damage.&lt;br /&gt;
&lt;br /&gt;
Disassociate your controls from the player:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.character=nil&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then, hover the mouse over the useless player and destroy it by typing:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.selected.destroy()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To undo, spawn a player character. This will spawn a new player at the spawn point of the world, and connect your controls to it.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.create_character()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Enable long reach ===&lt;br /&gt;
Enables long reach, which allows the player to build and interact with entities at a greater distance. The default reach is 10.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local reach = 10000&lt;br /&gt;
game.player.force.character_build_distance_bonus = reach&lt;br /&gt;
game.player.force.character_reach_distance_bonus = reach&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Research scripts ==&lt;br /&gt;
&lt;br /&gt;
=== Enable Research Queue ===&lt;br /&gt;
Enable the research queue for the players current team. Can be done after the game has started if it was forgotten during the map&#039;s setup.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.research_queue_enabled = true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Enable faster research ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.laboratory_speed_modifier=1&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
1 is normal speed, 2 is double speed 3 is triple etc.&lt;br /&gt;
&lt;br /&gt;
=== Research specific technologies ===&lt;br /&gt;
The internal technology names can be found in the infoboxes on their respective pages.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.technologies[&#039;electric-energy-distribution-1&#039;].researched=true&lt;br /&gt;
/c game.player.force.technologies[&#039;steel-processing&#039;].researched=true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Unresearch specific technologies ===&lt;br /&gt;
The internal technology names can be found in the infoboxes on their respective pages.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.technologies[&#039;electric-energy-distribution-1&#039;].researched=false; game.player.force.set_saved_technology_progress(&#039;electric-energy-distribution-1&#039;, 0)&lt;br /&gt;
/c game.player.force.technologies[&#039;steel-processing&#039;].researched=false; game.player.force.set_saved_technology_progress(&#039;steel-processing&#039;, 0)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Enabling specific recipes ===&lt;br /&gt;
The internal recipe/item names can be found in the infoboxes on their respective pages.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.force.recipes[&amp;quot;electric-energy-interface&amp;quot;].enabled=true&lt;br /&gt;
/c game.player.force.recipes[&amp;quot;rocket-silo&amp;quot;].enabled=true&lt;br /&gt;
/c game.player.force.recipes.loader.enabled=true&lt;br /&gt;
/c game.player.force.recipes[&amp;quot;fast-loader&amp;quot;].enabled = true&lt;br /&gt;
/c game.player.force.recipes[&amp;quot;express-loader&amp;quot;].enabled = true&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Enable all recipes ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c for name, recipe in pairs(game.player.force.recipes) do recipe.enabled = true end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Command line parameters ==&lt;br /&gt;
&#039;&#039;&#039;As of Game Version 0.17.5&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Command line parameters can be used to set settings in the command line before the game launches, this is useful mainly for advanced users or server hosts.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&#039;&#039;&#039;General options:&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
| -h, --help&lt;br /&gt;
| display help&lt;br /&gt;
|-&lt;br /&gt;
| --version&lt;br /&gt;
|show version information&lt;br /&gt;
|-&lt;br /&gt;
| -v, --verbose&lt;br /&gt;
|enable verbose logging&lt;br /&gt;
|-&lt;br /&gt;
| -c, --config PATH&lt;br /&gt;
|config file to use&lt;br /&gt;
|-&lt;br /&gt;
| --no-log-rotation&lt;br /&gt;
|don&#039;t rotate log file&lt;br /&gt;
|-&lt;br /&gt;
| --mod-directory PATH&lt;br /&gt;
|Mod directory to use&lt;br /&gt;
|-&lt;br /&gt;
| --check-unused-prototype-data&lt;br /&gt;
|Print a warning for all prototype values that were not accessed&lt;br /&gt;
|-&lt;br /&gt;
| --executable-path PATH&lt;br /&gt;
|Override autodetected __PATH__executable. Usually not needed except on very weird systems.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&#039;&#039;&#039;Running options:&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
| -s, --map2scenario arg&lt;br /&gt;
|map to scenario conversion&lt;br /&gt;
|-&lt;br /&gt;
| -m, --scenario2map arg&lt;br /&gt;
|scenario to map conversion&lt;br /&gt;
|-&lt;br /&gt;
| --apply-update arg&lt;br /&gt;
|immediately apply update package&lt;br /&gt;
|-&lt;br /&gt;
| --create FILE&lt;br /&gt;
|create a new map&lt;br /&gt;
|-&lt;br /&gt;
| --map-gen-settings FILE&lt;br /&gt;
|Map generation settings for use with --create, --start-server-load-scenario or --generate-map-preview. See data/map-gen-settings.example.json&lt;br /&gt;
|-&lt;br /&gt;
| --map-gen-seed SEED&lt;br /&gt;
|Map generation seed for use with --create, --start-server-load-scenario or --generate-map-preview. Will override seed specified in map gen settings&lt;br /&gt;
|-&lt;br /&gt;
| --map-settings FILE&lt;br /&gt;
|Map settings for use with --create or --start-server-load-scenario. See data/base/prototypes/map-settings.lua&lt;br /&gt;
|-&lt;br /&gt;
| --preset arg&lt;br /&gt;
|Name of the map generation preset to be used.&lt;br /&gt;
|-&lt;br /&gt;
| --enable-runtime-autoplace-modification&lt;br /&gt;
|Allows changing autoplace specifications runtime in non-multiplayer non-replay enabled games for debug purposes.&lt;br /&gt;
|-&lt;br /&gt;
| --generate-map-preview PNGFILE&lt;br /&gt;
|Generate preview images of the map&lt;br /&gt;
|-&lt;br /&gt;
| --generate-tile-properties-csv CSVFILE&lt;br /&gt;
|Generate tile properties into a CSV file; can be used with --generate-map-preview&lt;br /&gt;
|-&lt;br /&gt;
| --map-preview-size SCALE&lt;br /&gt;
|Size (in pixels) of map preview (default: 1024)&lt;br /&gt;
|-&lt;br /&gt;
| --map-preview-scale SCALE&lt;br /&gt;
|Scale (meters per pixel) of map preview (default: 1)&lt;br /&gt;
|-&lt;br /&gt;
| --map-preview-offset X,Y&lt;br /&gt;
|Offset of the center of the map, in meters (default: 0,0)&lt;br /&gt;
|-&lt;br /&gt;
| --noise-outputs TAG,TAG...&lt;br /&gt;
|Indicate which variables of noise program to output&lt;br /&gt;
|-&lt;br /&gt;
| --slope-shading SHADEAMOUNT&lt;br /&gt;
|Apply elevation shading to map preview&lt;br /&gt;
|-&lt;br /&gt;
| --slope-shade-property SHADEPROP&lt;br /&gt;
|Property to apply slope shading to (default: elevation)&lt;br /&gt;
|-&lt;br /&gt;
| --report-quantities PROTOTYPE,...&lt;br /&gt;
|When generating map preview, report approximate quantities of the named entity prototypes&lt;br /&gt;
|-&lt;br /&gt;
| --threads THREADCOUNT&lt;br /&gt;
|Number of threads to use when generating map previews&lt;br /&gt;
|-&lt;br /&gt;
| --disable-migration-window&lt;br /&gt;
|Disables the gui that is shown when opening a save with migrated content&lt;br /&gt;
|-&lt;br /&gt;
| --start-server FILE&lt;br /&gt;
|start a multiplayer server&lt;br /&gt;
|-&lt;br /&gt;
| --start-server-load-scenario [MOD/]NAME&lt;br /&gt;
|start a multiplayer server and load the specified scenario. The scenario is looked for inside the given mod. If no mod is given, it is looked for in the top-level scenarios directory.&lt;br /&gt;
|-&lt;br /&gt;
| --start-server-load-latest&lt;br /&gt;
|start a multiplayer server and load the latest available save&lt;br /&gt;
|-&lt;br /&gt;
| --until-tick TICK&lt;br /&gt;
|run a save until given map tick&lt;br /&gt;
|-&lt;br /&gt;
| --benchmark FILE&lt;br /&gt;
|load save and run benchmark&lt;br /&gt;
|-&lt;br /&gt;
| --benchmark-ticks N&lt;br /&gt;
|number of ticks for benchmarking. Default is 1000 (default: 1000)&lt;br /&gt;
|-&lt;br /&gt;
| --benchmark-verbose FILE&lt;br /&gt;
|comma seperated list of timings to ouput each tick. &amp;quot;all&amp;quot;, &amp;quot;timestamp&amp;quot; as well as all other values seen in the debug view are allowed here. An empty string disabled verbose benchmarking. (default: )&lt;br /&gt;
|-&lt;br /&gt;
| --output-perf-stats FILE&lt;br /&gt;
|path of file to which performance statistics measurements should be saved. Special tags {api}, {hw}, {time} and {tag} will be replaced.&lt;br /&gt;
|-&lt;br /&gt;
| --mp-connect ADDRESS&lt;br /&gt;
|start factorio and connect to address&lt;br /&gt;
|-&lt;br /&gt;
| --load-game FILE&lt;br /&gt;
|start Factorio and load a game in singleplayer&lt;br /&gt;
|-&lt;br /&gt;
| --benchmark-graphics FILE&lt;br /&gt;
|load save and run it with graphics for benchmark-ticks number of ticks as normal game would&lt;br /&gt;
|-&lt;br /&gt;
| --benchmark-frame FILE&lt;br /&gt;
|load save and benchmark graphics rendering of single frame (prepare + render) without updating the game&lt;br /&gt;
|-&lt;br /&gt;
| --force-opengl&lt;br /&gt;
|use OpenGL for rendering&lt;br /&gt;
|-&lt;br /&gt;
| --force-d3d&lt;br /&gt;
|use Direct3D for rendering&lt;br /&gt;
|-&lt;br /&gt;
| --debug-graphics&lt;br /&gt;
|enables debugging layer for graphics API. If DirectX is used DirectX SDK needs to be installed for this to work.&lt;br /&gt;
|-&lt;br /&gt;
| --fullscreen&lt;br /&gt;
|start game in windowed mode (saved to configuration)&lt;br /&gt;
|-&lt;br /&gt;
| --max-texture-size N&lt;br /&gt;
|maximal size of texture that the game can use (saved to configuration). Should be power of two greater than 2048&lt;br /&gt;
|-&lt;br /&gt;
| --graphics-quality arg&lt;br /&gt;
|accepted values: normal, low, very-low&lt;br /&gt;
|-&lt;br /&gt;
| --video-memory-usage arg&lt;br /&gt;
|accepted values: all, high, medium, low&lt;br /&gt;
|-&lt;br /&gt;
| --force-graphics-preset arg&lt;br /&gt;
|accepted values: very-low, low, mac-with-low-ram, medium-with-low-vram, medium, high, very-high, extreme&lt;br /&gt;
|-&lt;br /&gt;
| --gfx-safe-mode&lt;br /&gt;
|resets some graphics settings to values that should work on most configurations&lt;br /&gt;
|-&lt;br /&gt;
| --low-vram&lt;br /&gt;
|sprites that are not put into sprite atlases won&#039;t be allocated as texture objects&lt;br /&gt;
|-&lt;br /&gt;
| --shader arg&lt;br /&gt;
|enable/disable shader postprocessing (saved to configuration)&lt;br /&gt;
|-&lt;br /&gt;
| --disable-audio&lt;br /&gt;
|Disable audio. Mainly for faster startup during development.&lt;br /&gt;
|-&lt;br /&gt;
| --window-size arg&lt;br /&gt;
|Desired window resolution. For example &amp;quot;1680x1050&amp;quot;. Or &amp;quot;maximized&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| --single-thread-loading&lt;br /&gt;
|Disables loading of sprites in multiple threads.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&#039;&#039;&#039;Server options:&#039;&#039;&#039;&lt;br /&gt;
|-&lt;br /&gt;
| --port N&lt;br /&gt;
|network port to use&lt;br /&gt;
|-&lt;br /&gt;
| --bind ADDRESS[:PORT]&lt;br /&gt;
|IP address (and optionally port) to bind to&lt;br /&gt;
|-&lt;br /&gt;
| --rcon-port N&lt;br /&gt;
|Port to use for RCON&lt;br /&gt;
|-&lt;br /&gt;
| --rcon-password PASSWORD&lt;br /&gt;
|Password for RCON&lt;br /&gt;
|-&lt;br /&gt;
| --server-settings FILE&lt;br /&gt;
|Path to file with server settings. See data/server-settings.example.json&lt;br /&gt;
|-&lt;br /&gt;
| --use-server-whitelist&lt;br /&gt;
|If the whitelist should be used.&lt;br /&gt;
|-&lt;br /&gt;
| --server-whitelist FILE&lt;br /&gt;
|Path to file with server whitelist.&lt;br /&gt;
|-&lt;br /&gt;
| --server-banlist FILE&lt;br /&gt;
|Path to file with server banlist.&lt;br /&gt;
|-&lt;br /&gt;
| --server-adminlist FILE&lt;br /&gt;
|Path to file with server adminlist.&lt;br /&gt;
|-&lt;br /&gt;
| --console-log FILE&lt;br /&gt;
|Path to file where a copy of the server&#039;s log will be stored&lt;br /&gt;
|-&lt;br /&gt;
| --server-id FILE&lt;br /&gt;
|Path where server ID will be stored or read from&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Multiplayer ===&lt;br /&gt;
&lt;br /&gt;
  --start-server SAVE&lt;br /&gt;
&lt;br /&gt;
Will start a Headless (Dedicated) server, with no GUI.&lt;br /&gt;
&lt;br /&gt;
  --mp-connect ADDRESS&lt;br /&gt;
ADDRESS is the IP:port of the remote host. Port is optional.&lt;br /&gt;
Examples:&lt;br /&gt;
&lt;br /&gt;
  ./factorio --mp-connect 192.168.1.101&lt;br /&gt;
  ./factorio --mp-connect 192.168.1.101:2345&lt;br /&gt;
&lt;br /&gt;
As above, port can be specified by placing the port number after a colon in the address.&lt;br /&gt;
&lt;br /&gt;
  --map2scenario SAVE&lt;br /&gt;
Converts a save game to a User Scenario, allows saved game state to be loaded into map editor.&lt;br /&gt;
Assuming that save game name is &amp;quot;foo.zip&amp;quot;, executing &#039;./factorio --map2scenario s1&#039; will result in Factorio loading, opening the save file, and saving the scenario into the scenario folder.&lt;br /&gt;
&lt;br /&gt;
== Modding tools ==&lt;br /&gt;
A list of the internal names of most things in the vanilla game can also be found on [[data.raw]].&lt;br /&gt;
&lt;br /&gt;
=== Print to console which tile are you have under the player position ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c game.player.print(game.player.surface.get_tile(game.player.position.x, game.player.position.y).name)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Write all researched technologies to file ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local list = {}&lt;br /&gt;
for _, tech in pairs(game.player.force.technologies) do &lt;br /&gt;
	if tech.researched then&lt;br /&gt;
    list[#list+1] = tech.name&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
game.write_file(&amp;quot;techs.lua&amp;quot;, serpent.block(list) .. &amp;quot;\n&amp;quot;, true)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Write all enabled recipes to file ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
/c local list = {}&lt;br /&gt;
for _, recipe in pairs(game.player.force.recipes) do &lt;br /&gt;
	if recipe.enabled then&lt;br /&gt;
    list[#list+1] = recipe.name&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
game.write_file(&amp;quot;recipes.lua&amp;quot;, serpent.block(list) .. &amp;quot;\n&amp;quot;, true)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
* http://lua-api.factorio.com/latest/ - Factorio API reference for latest version&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Prototype/Sprite&amp;diff=173595</id>
		<title>Prototype/Sprite</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Prototype/Sprite&amp;diff=173595"/>
		<updated>2019-05-28T12:13:57Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: Example didn&amp;#039;t have type defined&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Basics ==&lt;br /&gt;
Prototype type: &#039;&#039;&#039;sprite&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Specifies a picture that can be used with https://lua-api.factorio.com/latest/Concepts.html#SpritePath during runtime.&lt;br /&gt;
== Mandatory properties ==&lt;br /&gt;
&lt;br /&gt;
=== type ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/string]]&lt;br /&gt;
&lt;br /&gt;
Must be &amp;quot;sprite&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
=== name ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/string]]&lt;br /&gt;
&lt;br /&gt;
Name of the sprite. Must be unique. Used in https://lua-api.factorio.com/latest/Concepts.html#SpritePath.&lt;br /&gt;
&lt;br /&gt;
=== filename ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/FileName]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: &amp;quot;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Technically optional, but path to sprite cannot be empty.&lt;br /&gt;
&lt;br /&gt;
== Optional properties ==&lt;br /&gt;
&lt;br /&gt;
=== layers ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/table]] of [[Types/Sprite]]&lt;br /&gt;
&lt;br /&gt;
If this property is present, all Sprite definitions have to be placed as entries in the array, and they will all be loaded from there. Each item (Sprite definition) in the array may also have the &amp;lt;code&amp;gt;layers&amp;lt;/code&amp;gt; property.&lt;br /&gt;
&lt;br /&gt;
If this property is present, all other properties are ignored and the mandatory properties do not have to be defined.&lt;br /&gt;
&lt;br /&gt;
=== hr_version ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/Sprite]]&lt;br /&gt;
&lt;br /&gt;
If this property exists and high resolution sprites are turned on, its contents are used to load the sprite.&lt;br /&gt;
&lt;br /&gt;
=== slice ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
Number of slices this is sliced into when using the &amp;quot;optimized atlas packing&amp;quot; option. If you are a modder, you can just ignore this property.&lt;br /&gt;
&lt;br /&gt;
Example: If this is 4, the sprite will be sliced into a 4×4 grid.&lt;br /&gt;
&lt;br /&gt;
=== slice_x ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
Same as &amp;lt;code&amp;gt;slice&amp;lt;/code&amp;gt; above, but this specifies only how many slices there are on the x axis.&lt;br /&gt;
&lt;br /&gt;
=== slice_y ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
Same as &amp;lt;code&amp;gt;slice&amp;lt;/code&amp;gt; above, but this specifies only how many slices there are on the y axis.&lt;br /&gt;
&lt;br /&gt;
=== priority ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/string]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: &amp;quot;medium&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Possible values:&lt;br /&gt;
* &amp;quot;extra-high-no-scale&amp;quot;&lt;br /&gt;
* &amp;quot;extra-high&amp;quot;&lt;br /&gt;
* &amp;quot;high&amp;quot;&lt;br /&gt;
* &amp;quot;medium&amp;quot;&lt;br /&gt;
* &amp;quot;low&amp;quot;&lt;br /&gt;
* &amp;quot;very-low&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== flags ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteFlags]]&lt;br /&gt;
&lt;br /&gt;
=== size ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]] or [[Types/table]] of [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
The width and height of the sprite. If this is an array, the first member of the array is the width and the second is the height. Otherwise the size is both width and height.&lt;br /&gt;
&lt;br /&gt;
Width and height may only be in the range of 0-8192.&lt;br /&gt;
&lt;br /&gt;
=== width ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
Mandatory if &amp;lt;code&amp;gt;size&amp;lt;/code&amp;gt; is not given. Width of the picture in pixels, from 0-8192.&lt;br /&gt;
&lt;br /&gt;
=== height ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
Mandatory if &amp;lt;code&amp;gt;size&amp;lt;/code&amp;gt; is not given. Height of the picture in pixels, from 0-8192.&lt;br /&gt;
&lt;br /&gt;
=== x ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 0&lt;br /&gt;
&lt;br /&gt;
Horizontal position of the sprite in the source file in pixels.&lt;br /&gt;
&lt;br /&gt;
=== y ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 0&lt;br /&gt;
&lt;br /&gt;
Vertical position of the sprite in the source file in pixels.&lt;br /&gt;
&lt;br /&gt;
=== position ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/table]] of [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
Loaded only when &amp;lt;code&amp;gt;x&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;y&amp;lt;/code&amp;gt; are both 0. The first member of the array is x and the second is y. &lt;br /&gt;
&lt;br /&gt;
=== shift ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/vector]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: {0, 0}&lt;br /&gt;
&lt;br /&gt;
In tiles. util.by_pixel() can be used to divide the shift by 32 which is the usual pixel height/width of 1 tile in normal resolution. Note that 32 pixel tile height/width is not enforced anywhere - any other tile height or width is also possible.&lt;br /&gt;
&lt;br /&gt;
=== scale ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/double]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 1&lt;br /&gt;
&lt;br /&gt;
Values different than 1 specify the scale of the sprite on default zoom.&lt;br /&gt;
Scale 2 means that the picture will be 2 times bigger on screen (and more pixelated).&lt;br /&gt;
&lt;br /&gt;
=== draw_as_shadow ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/bool]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: false&lt;br /&gt;
&lt;br /&gt;
=== apply_runtime_tint ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/bool]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: false&lt;br /&gt;
&lt;br /&gt;
=== tint ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/Color]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: {r=1, g=1, b=1, a=1} (white)&lt;br /&gt;
&lt;br /&gt;
=== blend_mode ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/string]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: &amp;quot;normal&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Possible values:&lt;br /&gt;
* &amp;quot;normal&amp;quot;&lt;br /&gt;
* &amp;quot;additive&amp;quot;&lt;br /&gt;
* &amp;quot;additive-soft&amp;quot;&lt;br /&gt;
* &amp;quot;multiplicative&amp;quot;&lt;br /&gt;
* &amp;quot;overwrite&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== load_in_minimal_mode ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/bool]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: false&lt;br /&gt;
&lt;br /&gt;
Minimal mode is entered when mod loading fails. You are in it when you see the gray box after (part of) the loading screen that tells you a mod error ([https://cdn.discordapp.com/attachments/340530709712076801/532315796626472972/unknown.png Example]). If you are a modder, you can just ignore this property.&lt;br /&gt;
&lt;br /&gt;
=== premul_alpha ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/bool]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: true&lt;br /&gt;
&lt;br /&gt;
Whether alpha should be premultiplied.&lt;br /&gt;
&lt;br /&gt;
=== generate_sdf ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/bool]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: false&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
    {&lt;br /&gt;
      type = &amp;quot;sprite&amp;quot;&lt;br /&gt;
      name = &amp;quot;accumulator-sprite&amp;quot;,&lt;br /&gt;
      filename = &amp;quot;__base__/graphics/entity/basic-accumulator/basic-accumulator.png&amp;quot;,&lt;br /&gt;
      priority = &amp;quot;extra-high&amp;quot;,&lt;br /&gt;
      width = 124,&lt;br /&gt;
      height = 103,&lt;br /&gt;
      shift = {0.7, -0.2}&lt;br /&gt;
    }&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/SpriteFlags&amp;diff=173524</id>
		<title>Types/SpriteFlags</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/SpriteFlags&amp;diff=173524"/>
		<updated>2019-05-23T12:30:49Z</updated>

		<summary type="html">&lt;p&gt;Lovely santa: Updated SpriteFlags; Added new flags as game state v0.17.42; Updated layout and added example as is with Types/EntityPrototypeFlags&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Array ([[Types/table]]) of strings. The possible strings are listed below.&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;none&amp;quot; ==&lt;br /&gt;
When no flags, or when an invalid flag (such as &amp;quot;compressed&amp;quot;) is set.&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;no-crop&amp;quot; ==&lt;br /&gt;
The sprite won&#039;t be automatically cropped.&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;not-compressed&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;always-compressed&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;mipmap&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;linear-minification&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;linear-magnification&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;linear-mip-level&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;alpha-mask&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;no-scale&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;mask&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;icon&amp;quot; ==&lt;br /&gt;
When this flag is set, it will automaticaly set these flags:&lt;br /&gt;
* &amp;quot;no-crop&amp;quot;&lt;br /&gt;
* &amp;quot;not-compressed&amp;quot;&lt;br /&gt;
* &amp;quot;mipmap&amp;quot;&lt;br /&gt;
* &amp;quot;linear-minification&amp;quot;&lt;br /&gt;
* &amp;quot;linear-magnification&amp;quot;&lt;br /&gt;
* &amp;quot;linear-mip-level&amp;quot;&lt;br /&gt;
* &amp;quot;no-scale&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;light&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;terrain&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;shadow&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;smoke&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;decal&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;low-object&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== &amp;quot;trilinear-filtering&amp;quot; ==&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
    flags = {&amp;quot;icon&amp;quot;, &amp;quot;no-crop&amp;quot;}&lt;/div&gt;</summary>
		<author><name>Lovely santa</name></author>
	</entry>
</feed>