<?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=Stringweasel</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=Stringweasel"/>
	<link rel="alternate" type="text/html" href="https://wiki.factorio.com/Special:Contributions/Stringweasel"/>
	<updated>2026-04-22T07:44:56Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/AnimationFrameSequence&amp;diff=190751</id>
		<title>Types/AnimationFrameSequence</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/AnimationFrameSequence&amp;diff=190751"/>
		<updated>2023-02-05T10:23:37Z</updated>

		<summary type="html">&lt;p&gt;Stringweasel: Spelling mistake &amp;quot;comple&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;An [[Types/table|array]] of [[Types/uint16]]. Used by [[Types/Animation]] and similar.&lt;br /&gt;
&lt;br /&gt;
This is a list of 1-based frame indices into the spritesheet. The actual length of the animation will then be the length of the frame_sequence (times &amp;lt;code&amp;gt;repeat_count&amp;lt;/code&amp;gt;, times two if &amp;lt;code&amp;gt;run_mode&amp;lt;/code&amp;gt; is &amp;quot;forward-then-backward&amp;quot;). There is a limit for (actual) animation length of 255 frames.&lt;br /&gt;
&lt;br /&gt;
Indices can be used in any order, repeated or not used at all. Unused frames are not loaded into VRAM at all, frames referenced multiple times are loaded just once.[https://forums.factorio.com/53202]&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&lt;br /&gt;
Trivial example - frame_sequence defines same sequence in which the animation would load by default, so it is useless in this case:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
  frame_count = 4,&lt;br /&gt;
  frame_sequence = { 1, 2, 3, 4 }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Usage example - first five times repeat frame 2, then alternate between 4 and 3 two times. Frame 1 is not used:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
  frame_count = 4,&lt;br /&gt;
  frame_sequence = { 2, 2, 2, 2, 2, 4, 3, 4, 3 }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Complex example - animation contains different layers with different frame counts&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
  local custom_frame_sequence = { 2, 2, 2, 2, 2, 4, 3, 4, 3 }&lt;br /&gt;
  layers = {&lt;br /&gt;
    {&lt;br /&gt;
      -- Animation with custom frame sequence&lt;br /&gt;
      frame_count = 4,&lt;br /&gt;
      frame_sequence = custom_frame_sequence,&lt;br /&gt;
    },&lt;br /&gt;
    {&lt;br /&gt;
      -- Single sprite that&#039;s repeated&lt;br /&gt;
      repeat_count = #custom_frame_sequence,&lt;br /&gt;
    },&lt;br /&gt;
    {&lt;br /&gt;
      -- Other animation with different frame count&lt;br /&gt;
      -- Assuming: #custom_frame_sequence &amp;lt; frame_count&lt;br /&gt;
      frame_count = #custom_frame_sequence,&lt;br /&gt;
    },&lt;br /&gt;
  }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Stringweasel</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/UnitSpawnDefinition&amp;diff=190285</id>
		<title>Types/UnitSpawnDefinition</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/UnitSpawnDefinition&amp;diff=190285"/>
		<updated>2022-11-08T20:44:04Z</updated>

		<summary type="html">&lt;p&gt;Stringweasel: Add information about spawn points&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The definition of a spawnable unit for a [[Prototype/EnemySpawner]]. It can be specified as a table with named or numbered keys, but not a mix of both.&lt;br /&gt;
&lt;br /&gt;
== Mandatory properties ==&lt;br /&gt;
&lt;br /&gt;
=== unit or 1 ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/string]]&lt;br /&gt;
&lt;br /&gt;
The name of a [[Prototype/Entity]].&lt;br /&gt;
&lt;br /&gt;
=== spawn_points or 2 ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/table]] of [[Types/SpawnPoint]]&lt;br /&gt;
&lt;br /&gt;
Array of evolution and probability info.&lt;br /&gt;
* The evolution_factor must be ascending from entry to entry.&lt;br /&gt;
* The last entry&#039;s weight will be used when the evolution_factor is larger than the last entry.&lt;br /&gt;
* Weights are linearly interpolated between entries.&lt;br /&gt;
* Individual weights are scaled linearly so that the cumulative weight is 1.&lt;/div&gt;</summary>
		<author><name>Stringweasel</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/AnimationFrameSequence&amp;diff=190227</id>
		<title>Types/AnimationFrameSequence</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/AnimationFrameSequence&amp;diff=190227"/>
		<updated>2022-10-29T07:35:15Z</updated>

		<summary type="html">&lt;p&gt;Stringweasel: show advanced example using multiple layers&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;An [[Types/table|array]] of [[Types/uint16]]. Used by [[Types/Animation]] and similar.&lt;br /&gt;
&lt;br /&gt;
This is a list of 1-based frame indices into the spritesheet. The actual length of the animation will then be the length of the frame_sequence (times &amp;lt;code&amp;gt;repeat_count&amp;lt;/code&amp;gt;, times two if &amp;lt;code&amp;gt;run_mode&amp;lt;/code&amp;gt; is &amp;quot;forward-then-backward&amp;quot;). There is a limit for (actual) animation length of 255 frames.&lt;br /&gt;
&lt;br /&gt;
Indices can be used in any order, repeated or not used at all. Unused frames are not loaded into VRAM at all, frames referenced multiple times are loaded just once.[https://forums.factorio.com/53202]&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&lt;br /&gt;
Trivial example - frame_sequence defines same sequence in which the animation would load by default, so it is useless in this case:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
  frame_count = 4,&lt;br /&gt;
  frame_sequence = { 1, 2, 3, 4 }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Usage example - first five times repeat frame 2, then alternate between 4 and 3 two times. Frame 1 is not used:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
  frame_count = 4,&lt;br /&gt;
  frame_sequence = { 2, 2, 2, 2, 2, 4, 3, 4, 3 }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Comple example - animation contains different layers with different frame counts&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
  local custom_frame_sequence = { 2, 2, 2, 2, 2, 4, 3, 4, 3 }&lt;br /&gt;
  layers = {&lt;br /&gt;
    {&lt;br /&gt;
      -- Animation with custom frame sequence&lt;br /&gt;
      frame_count = 4,&lt;br /&gt;
      frame_sequence = custom_frame_sequence,&lt;br /&gt;
    },&lt;br /&gt;
    {&lt;br /&gt;
      -- Single sprite that&#039;s repeated&lt;br /&gt;
      repeat_count = #custom_frame_sequence,&lt;br /&gt;
    },&lt;br /&gt;
    {&lt;br /&gt;
      -- Other animation with different frame count&lt;br /&gt;
      -- Assuming: #custom_frame_sequence &amp;lt; frame_count&lt;br /&gt;
      frame_count = #custom_frame_sequence,&lt;br /&gt;
    },&lt;br /&gt;
  }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Stringweasel</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/Animation&amp;diff=190226</id>
		<title>Types/Animation</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/Animation&amp;diff=190226"/>
		<updated>2022-10-28T18:00:03Z</updated>

		<summary type="html">&lt;p&gt;Stringweasel: animation_speed only has to be defined in one layer&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Basics ==&lt;br /&gt;
Specifies animation that can be used in the game.&lt;br /&gt;
&lt;br /&gt;
Note that if any frame of the animation is specified from the same source as any other [[Types/Sprite]] or frame of other animation, it will be shared.&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/Animation]]&lt;br /&gt;
&lt;br /&gt;
If this property is present, all Animation definitions have to be placed as entries in the array, and they will all be loaded from there. Each item (Animation 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;
Layers may not be an empty table.&lt;br /&gt;
&lt;br /&gt;
=== hr_version ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/Animation]]&lt;br /&gt;
&lt;br /&gt;
If this property exists and high resolution sprites are turned on, its contents are used to load the Animation.&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;
Mandatory if &amp;lt;code&amp;gt;&amp;quot;stripes&amp;quot;&amp;lt;/code&amp;gt; is not specified.&lt;br /&gt;
&lt;br /&gt;
=== priority ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpritePriority]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: &amp;quot;medium&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 one frame. 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 one frame 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 one frame 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 animation 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 animation 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;
=== 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 animation 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;
Only one of &amp;lt;code&amp;gt;draw_as_shadow&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;draw_as_glow&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;draw_as_light&amp;lt;/code&amp;gt; can be true. &amp;lt;code&amp;gt;draw_as_shadow&amp;lt;/code&amp;gt; takes precedence over &amp;lt;code&amp;gt;draw_as_glow&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;draw_as_light&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== draw_as_glow ===&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;
Only one of &amp;lt;code&amp;gt;draw_as_shadow&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;draw_as_glow&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;draw_as_light&amp;lt;/code&amp;gt; can be true. &amp;lt;code&amp;gt;draw_as_glow&amp;lt;/code&amp;gt; takes precedence over &amp;lt;code&amp;gt;draw_as_light&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Draws first as a normal sprite, and again as a light layer.&amp;lt;sup&amp;gt;[https://forums.factorio.com/91682]&amp;lt;/sup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== draw_as_light ===&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;
Only one of &amp;lt;code&amp;gt;draw_as_shadow&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;draw_as_glow&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;draw_as_light&amp;lt;/code&amp;gt; can be true.&lt;br /&gt;
&lt;br /&gt;
=== mipmap_count ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint8]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 0&lt;br /&gt;
&lt;br /&gt;
Only loaded if this is an icon (has flag &amp;quot;group=icon&amp;quot; or &amp;quot;group=gui&amp;quot;).&amp;lt;br&amp;gt;&lt;br /&gt;
Note: mipmap_count doesn&#039;t make sense in animation, as it is not possible to layout mipmaps in a way, that would load correctly both the animation and the mipmaps (besides animations with just one frame).[https://forums.factorio.com/viewtopic.php?p=549058#p549058]&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/BlendMode]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: &amp;quot;normal&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;
Unused.&lt;br /&gt;
&lt;br /&gt;
=== run_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;forward&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Possible values are:&lt;br /&gt;
*forward&lt;br /&gt;
*backward&lt;br /&gt;
*forward-then-backward&lt;br /&gt;
&lt;br /&gt;
=== frame_count ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint32]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 1&lt;br /&gt;
&lt;br /&gt;
Can&#039;t be 0.&lt;br /&gt;
&lt;br /&gt;
=== line_length ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint32]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 0&lt;br /&gt;
&lt;br /&gt;
Once the specified number of pictures is loaded, other pictures are loaded on other line.&lt;br /&gt;
This is to allow having longer animations in matrix, to input files with too high width.&lt;br /&gt;
The game engine limits the width of any input files to 8192px, so it is compatible with most graphics cards.&lt;br /&gt;
0 means that all the pictures are in one horizontal line.&lt;br /&gt;
&lt;br /&gt;
=== animation_speed ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/float]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 1&lt;br /&gt;
&lt;br /&gt;
Modifier of the animation playing speed, the default is 1, which means one animation frame per tick (60 fps).&lt;br /&gt;
The speed of playing can often vary depending on the usage (output of steam engine for example). Has to be greater than 0.&lt;br /&gt;
If &amp;lt;code&amp;gt;layers&amp;lt;/code&amp;gt; are used then the &amp;lt;code&amp;gt;animation_speed&amp;lt;/code&amp;gt; only has to be defined in one layer. All layers will run at the same speed.&lt;br /&gt;
&lt;br /&gt;
=== max_advance ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/float]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: MAX_FLOAT&lt;br /&gt;
&lt;br /&gt;
=== repeat_count ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint8]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 1&lt;br /&gt;
&lt;br /&gt;
How many times to repeat the animation to complete an animation cycle. E.g. if one layer is 10 frames, a second layer of 1 frame would need repeat_count = 10 to match the complete cycle.&lt;br /&gt;
&lt;br /&gt;
Can&#039;t be 0.&lt;br /&gt;
&lt;br /&gt;
=== dice ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint8]]&lt;br /&gt;
&lt;br /&gt;
=== dice_x ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint8]]&lt;br /&gt;
&lt;br /&gt;
=== dice_y ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint8]]&lt;br /&gt;
&lt;br /&gt;
=== frame_sequence ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/AnimationFrameSequence]]&lt;br /&gt;
&lt;br /&gt;
=== stripes ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/table|table]] (array) of [[Types/Stripe|Stripe]]&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
Specification of animation of a beacon&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
animation =&lt;br /&gt;
{&lt;br /&gt;
  filename = &amp;quot;__base__/graphics/entity/beacon/beacon-antenna.png&amp;quot;,&lt;br /&gt;
  width = 54,&lt;br /&gt;
  height = 50,&lt;br /&gt;
  line_length = 8,&lt;br /&gt;
  frame_count = 32,&lt;br /&gt;
  shift = { -0.03125, -1.71875},&lt;br /&gt;
  animation_speed = 0.5&lt;br /&gt;
},&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Prototype property type usage|{{FULLPAGENAME}}?Animation]}}&lt;/div&gt;</summary>
		<author><name>Stringweasel</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Scenario_system&amp;diff=190201</id>
		<title>Scenario system</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Scenario_system&amp;diff=190201"/>
		<updated>2022-10-22T09:05:08Z</updated>

		<summary type="html">&lt;p&gt;Stringweasel: Scenarios need a info.json to be used to host a new multiplayer game.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Languages}}&lt;br /&gt;
The scenario system allows save-based mods to be created, so that installing mods separately is not necessary. This allows for server side scripting, or to provide a separate objective than the vanilla freeplay (which is actually a scenario, just like the [[tutorial|tutorial campaign]]).&lt;br /&gt;
&lt;br /&gt;
== Creation ==&lt;br /&gt;
&lt;br /&gt;
Creation of a scenario starts in the [[map editor]]. The map editor allows an author to save a map that they have created as a scenario. This allows players to add special scripting to the scenario.&lt;br /&gt;
&lt;br /&gt;
There are two ways to create a scenario:&lt;br /&gt;
&lt;br /&gt;
* Via the [[Map editor]].&lt;br /&gt;
* Creating a new folder in the scenarios folder, and adding a control.lua.&lt;br /&gt;
&lt;br /&gt;
== Differences between scenarios, saves, and mods ==&lt;br /&gt;
&lt;br /&gt;
There are a few differences between a scenario, a save, and a mod. In a way, a scenario takes parts from both.&lt;br /&gt;
&lt;br /&gt;
* Scenarios, unlike mods, cannot add anything to the game. The only type of scripting allowed in a scenario is scripting that would occur in control.lua.&lt;br /&gt;
* Scenarios can have premade maps, such as the supply scenario, or can have maps made with the map generator, such as freeplay.&lt;br /&gt;
* Scenarios do not need to be installed client side, unlike mods. This allows servers to implement small changes to gameplay on their end, such as displaying a MOTD to joining players.&lt;br /&gt;
* Scenarios, unlike normal saves, are stored in a different folder.&lt;br /&gt;
* Scenarios can be used to create a bit of a story, as the campaign does.&lt;br /&gt;
&lt;br /&gt;
== Limitations of Scenarios ==&lt;br /&gt;
&lt;br /&gt;
* Scenarios must be packaged into a mod to be distributed on the mod portal.&lt;br /&gt;
* Scenarios cannot add anything to the game (Namely, they may not make calls to data:extend()).&lt;br /&gt;
* Scenarios count as mods for the purpose of isolating [[achievements]].&lt;br /&gt;
* Scenarios can be packaged without an &amp;lt;code&amp;gt;info.json&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;description.json&amp;lt;/code&amp;gt;, but then it won&#039;t be possible to host a new multiplayer game using this scenario.&lt;br /&gt;
&lt;br /&gt;
== Playing a scenario ==&lt;br /&gt;
&lt;br /&gt;
There are several scenarios included into the game by default. To play a scenario, click Play-&amp;gt;Scenarios, and choose either a user scenario, or a scenario from the base game or mod. The Freeplay scenario is the same as the basic game, where the objective is to launch a rocket.&lt;br /&gt;
&lt;br /&gt;
Upon choosing a scenario to play and saving the game, a normal save will be created that encompasses the map itself, and the control.Lua scripting that was provided by the scenario. This can be removed by deleting the script.dat and control.Lua files from the save, turning it into a normal save. Do this at your own risk, as it may break the save depending on how intertwined the scenario is with the save.&lt;br /&gt;
&lt;br /&gt;
== Installing scenarios ==&lt;br /&gt;
&lt;br /&gt;
Scenarios made by other players can be installed into a folder called scenarios in the player&#039;s [[application directory#User_data_directory|user data directory]]. It can then be played from the scenarios menu.&lt;br /&gt;
&lt;br /&gt;
Scenarios added by mods are also shown in the Scenarios menu.&lt;br /&gt;
&lt;br /&gt;
== Packaging a scenario as a mod ==&lt;br /&gt;
Create an empty mod, as described in [[Tutorial:Mod_structure]]. Then, simply add a &amp;quot;scenarios&amp;quot; folder, and copy your scenario into that folder. If you created a scenario with the map editor, you can find it in the scenarios folder in your [[application directory#User_data_directory|user data directory]].&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
* [[Tutorial]]&lt;br /&gt;
* [[Map editor]]&lt;br /&gt;
* [[Map generator]]&lt;/div&gt;</summary>
		<author><name>Stringweasel</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/SimulationDefinition&amp;diff=190195</id>
		<title>Types/SimulationDefinition</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/SimulationDefinition&amp;diff=190195"/>
		<updated>2022-10-19T14:18:39Z</updated>

		<summary type="html">&lt;p&gt;Stringweasel: expand game.move_cursor with comment&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Used by [[Prototype/TipsAndTricksItem]] and by main menu simulations ([[Prototype/UtilityConstants#main_menu_simulations]]).&lt;br /&gt;
&lt;br /&gt;
== Optional properties ==&lt;br /&gt;
&lt;br /&gt;
=== save ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/FileName]]&lt;br /&gt;
&lt;br /&gt;
The save file that is used for this simulation. If not given and &amp;lt;code&amp;gt;generate_map&amp;lt;/code&amp;gt; is true, a map gets generated by the game.&lt;br /&gt;
&lt;br /&gt;
=== init_file ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/FileName]]&lt;br /&gt;
&lt;br /&gt;
This code is run as a (silent) console command inside the simulation when it is first initialized. Since this is run as a console command, the restrictions of console commands apply, e.g. &amp;lt;code&amp;gt;require&amp;lt;/code&amp;gt; is not available&amp;lt;sup&amp;gt;[https://lua-api.factorio.com/latest/Libraries.html]&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== init ===&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;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Only loaded if &amp;lt;code&amp;gt;init_file&amp;lt;/code&amp;gt; is not present.&lt;br /&gt;
&lt;br /&gt;
This code is run as a (silent) console command inside the simulation when it is first initialized. Since this is run as a console command, the restrictions of console commands apply, e.g. &amp;lt;code&amp;gt;require&amp;lt;/code&amp;gt; is not available&amp;lt;sup&amp;gt;[https://lua-api.factorio.com/latest/Libraries.html]&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== update_file ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/FileName]]&lt;br /&gt;
&lt;br /&gt;
This code is run as a (silent) console command inside the simulation every time the simulation is updated. Since this is run as a console command, the restrictions of console commands apply, e.g. &amp;lt;code&amp;gt;require&amp;lt;/code&amp;gt; is not available&amp;lt;sup&amp;gt;[https://lua-api.factorio.com/latest/Libraries.html]&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== update ===&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;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Only loaded if &amp;lt;code&amp;gt;update_file&amp;lt;/code&amp;gt; is not present.&lt;br /&gt;
&lt;br /&gt;
This code is run as a (silent) console command inside the simulation every time the simulation is updated. Since this is run as a console command, the restrictions of console commands apply, e.g. &amp;lt;code&amp;gt;require&amp;lt;/code&amp;gt; is not available&amp;lt;sup&amp;gt;[https://lua-api.factorio.com/latest/Libraries.html]&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== init_update_count ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint32]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 0&lt;br /&gt;
&lt;br /&gt;
Amount of ticks that this simulation should run for before the simulation is shown to the player. These updates happen after init/init_file has been run and at the highest possible rate (&amp;gt; 60 UPS).&lt;br /&gt;
&lt;br /&gt;
=== length ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint32]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 0&lt;br /&gt;
&lt;br /&gt;
How long this simulation takes. In the main menu simulations, another simulation will start after this simulation ends.&lt;br /&gt;
&lt;br /&gt;
=== generate_map ===&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;
If &amp;lt;code&amp;gt;save&amp;lt;/code&amp;gt; is not given and this is true, a map gets generated by the game for use in the simulation.&lt;br /&gt;
&lt;br /&gt;
=== checkboard ===&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;
If this is true, the map of the simulation is set to be a lab-tile checkerboard in the area of {{-20, -15},{20, 15}} when the scenario is first initialized (before init/init_file run).&lt;br /&gt;
&lt;br /&gt;
=== volume_modifier ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/float]]&lt;br /&gt;
&lt;br /&gt;
Multiplier for the simulation volume set by the player in the sound settings.&lt;br /&gt;
&lt;br /&gt;
=== override_volume ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/bool]]&lt;br /&gt;
&lt;br /&gt;
If true, overrides the simulation volume set by the player in the sound settings, simply setting the volume modifier to 1.&lt;br /&gt;
&lt;br /&gt;
== Addition API ==&lt;br /&gt;
&lt;br /&gt;
Simulation-only APIs:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
game.create_test_player{name=string}&lt;br /&gt;
game.activate_rail_planner{position=position,ghost_mode=bool}&lt;br /&gt;
game.deactivate_rail_planner()&lt;br /&gt;
game.move_cursor{position=position,speed=number}  --[[should be called every tick. Returns true when target is reached]]&lt;br /&gt;
game.activate_selection()&lt;br /&gt;
game.finish_selection()&lt;br /&gt;
game.deactivate_selection()&lt;br /&gt;
game.scroll_clipboard_forwards()&lt;br /&gt;
game.scroll_clipboard_backwards()&lt;br /&gt;
game.camera_player_cursor_position [RW]&lt;br /&gt;
game.camera_position [RW]&lt;br /&gt;
game.camera_zoom [W]&lt;br /&gt;
game.camera_player [W]&lt;br /&gt;
game.camera_player_cursor_direction [W]&lt;br /&gt;
game.camera_alt_info [W]&lt;br /&gt;
game.smart_belt_building [W]&lt;br /&gt;
&lt;br /&gt;
player.drag_start_position [W]&lt;br /&gt;
player.raw_build_from_cursor{ghost_mode=bool,created_by_moving=bool,position=position}&lt;br /&gt;
&lt;br /&gt;
surface.create_entities_from_blueprint_string{string=string,position=position,force=force,direction=defines.direction,flip_horizonal=bool,flip_vertical=bool,by_player=player}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Stringweasel</name></author>
	</entry>
	<entry>
		<id>https://wiki.factorio.com/index.php?title=Types/IconSpecification&amp;diff=190188</id>
		<title>Types/IconSpecification</title>
		<link rel="alternate" type="text/html" href="https://wiki.factorio.com/index.php?title=Types/IconSpecification&amp;diff=190188"/>
		<updated>2022-10-17T07:14:30Z</updated>

		<summary type="html">&lt;p&gt;Stringweasel: Add note about limitations in layered icon definitions.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Basics ==&lt;br /&gt;
Specifies the icon of an entity/item/technology/recipe etc. The properties are specified directly in the prototype, not in another sub-property.&lt;br /&gt;
&lt;br /&gt;
Either &amp;lt;code&amp;gt;icons&amp;lt;/code&amp;gt; and optionally &amp;lt;code&amp;gt;icon_size&amp;lt;/code&amp;gt;, or both &amp;lt;code&amp;gt;icon&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;icon_size&amp;lt;/code&amp;gt; have to be specified. If both &amp;lt;code&amp;gt;icons&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;icon&amp;lt;/code&amp;gt; are defined, &amp;lt;code&amp;gt;icon&amp;lt;/code&amp;gt; is ignored.&lt;br /&gt;
== Prototype properties: Option 1 ==&lt;br /&gt;
=== icons ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/table]] of [[Types/IconData]]&lt;br /&gt;
&lt;br /&gt;
The rendering order of the individual icons follows the table (array) order: Later added icons (higher index) get drawn on top of previously added icons (lower index). Can&#039;t be an empty table.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Icon layering was mainly designed for the barrel recipes and might not handle all modded instances correctly. Depending on the use-case it might be benifitial to use non-layered icons. For reference see [https://forums.factorio.com/69221 here] and [https://forums.factorio.com/98732 here].&lt;br /&gt;
&lt;br /&gt;
=== icon_size ===&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;icon_size&amp;lt;/code&amp;gt; is not specified inside all instances of [[Types/IconData]] inside &amp;lt;code&amp;gt;icons&amp;lt;/code&amp;gt;. The size of the square icon, in pixels, e.g. 32 for a 32px by 32px icon.&lt;br /&gt;
&lt;br /&gt;
=== icon_mipmaps ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint8]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 0&lt;br /&gt;
&lt;br /&gt;
== Prototype properties: Option 2 ==&lt;br /&gt;
=== icon ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/FileName]]&lt;br /&gt;
&lt;br /&gt;
Path to the icon file.&lt;br /&gt;
=== icon_size ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/SpriteSizeType]]&lt;br /&gt;
&lt;br /&gt;
Mandatory. The size of the square icon, in pixels, e.g. 32 for a 32px by 32px icon.&lt;br /&gt;
&lt;br /&gt;
=== icon_mipmaps ===&lt;br /&gt;
&#039;&#039;&#039;Type&#039;&#039;&#039;: [[Types/uint8]]&lt;br /&gt;
&lt;br /&gt;
Icons of reduced size will be used at decreased scale. 0 or 1 mipmaps is a single image. The file must contain 1/2 size images with a geometric-ratio, for each mipmap level. Each next level is aligned to the upper-left corner. Example sequence: 128x128@(0,0), 64,64@(128,0), 32x32@(196,0) is 3 mipmaps.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Default&#039;&#039;&#039;: 0&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&lt;br /&gt;
Simple icon with size:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
  icon = &amp;quot;__base__/graphics/icons/fluid/heavy-oil.png&amp;quot;,&lt;br /&gt;
  icon_size = 32,&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Layered icon, size defined outside of layers:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;icon_size = 32,&lt;br /&gt;
icons = {&lt;br /&gt;
  {&lt;br /&gt;
    icon = &amp;quot;__base__/graphics/icons/fluid/barreling/empty-barrel.png&amp;quot;&lt;br /&gt;
  },&lt;br /&gt;
  {&lt;br /&gt;
    icon = &amp;quot;__base__/graphics/icons/fluid/barreling/barrel-side-mask.png&amp;quot;,&lt;br /&gt;
    tint = { a = 0.75,  b = 0, g = 0, r = 0 }&lt;br /&gt;
  },&lt;br /&gt;
  {&lt;br /&gt;
    icon = &amp;quot;__base__/graphics/icons/fluid/barreling/barrel-hoop-top-mask.png&amp;quot;,&lt;br /&gt;
    tint = { a = 0.75, b = 0.5, g = 0.5, r = 0.5 }&lt;br /&gt;
  }&lt;br /&gt;
}&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Layered icon, size defined per layer:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;icons = {&lt;br /&gt;
  {&lt;br /&gt;
    icon = &amp;quot;__base__/graphics/icons/fluid/barreling/barrel-empty.png&amp;quot;,&lt;br /&gt;
    icon_size = 32&lt;br /&gt;
  },&lt;br /&gt;
  {&lt;br /&gt;
    icon = &amp;quot;__base__/graphics/icons/fluid/barreling/barrel-empty-side-mask.png&amp;quot;,&lt;br /&gt;
    icon_size = 32,&lt;br /&gt;
    tint = { a = 0.75, b = 0, g = 0, r = 0 }&lt;br /&gt;
  },&lt;br /&gt;
  {&lt;br /&gt;
    icon = &amp;quot;__base__/graphics/icons/fluid/barreling/barrel-empty-top-mask.png&amp;quot;,&lt;br /&gt;
    icon_size = 32,&lt;br /&gt;
    tint = { a = 0.75, b = 0.5, g = 0.5, r = 0.5 }&lt;br /&gt;
  },&lt;br /&gt;
  {&lt;br /&gt;
    icon = &amp;quot;__base__/graphics/icons/fluid/crude-oil.png&amp;quot;,&lt;br /&gt;
    icon_size = 32,&lt;br /&gt;
    scale = 0.5,&lt;br /&gt;
    shift = {7, 8 }&lt;br /&gt;
  }&lt;br /&gt;
}&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Stringweasel</name></author>
	</entry>
</feed>