Types/IconData: Difference between revisions

From Official Factorio Wiki
Jump to navigation Jump to search
(Created page with "== Basics == Data of one icon "layer" for the <code>icons</code> property of the Types/IconSpecification. == Mandatory properties == === icon === '''Type''': Types/File...")
 
(Removed old prototype docs)
 
(17 intermediate revisions by 4 users not shown)
Line 1: Line 1:
== Basics ==
<div class="stub"><p>'''The prototype docs have moved to a new website with an improved format.''' This documentation page can now be found here: [https://lua-api.factorio.com/latest/types/IconData.html https://lua-api.factorio.com/latest/types/IconData.html]
Data of one icon "layer" for the <code>icons</code> property of the [[Types/IconSpecification]].


== Mandatory properties ==
</p><p>This wiki page is no longer updated and '''will be removed at some point in the future''', so please update your browser bookmarks or other links that sent you here. If you'd like to contribute to the new docs, you can leave your feedback [https://forums.factorio.com/viewforum.php?f=233 on the forums].</p></div>
=== icon ===
'''Type''': [[Types/FileName]]
 
The path to the icon.
 
=== icon_size ===
'''Type''': [[Types/SpriteSizeType]]
 
Mandatory if <code>icon_size</code> is not specified outside of <code>icons</code>. The size of the square icon, in pixels, e.g. 32 for a 32px by 32px icon.
 
== Optional properties ==
=== tint ===
'''Type''': [[Types/Color]]
 
'''Default''': {r=0, g=0, b=0, a=1}
 
Tint of the icon.
 
=== shift ===
'''Type''': [[Types/vector]]
 
'''Default''': {0, 0}
 
Used to offset the icon "layer" from the overall icon.
 
=== scale ===
'''Type''': [[Types/double]]
 
'''Default''': 1
 
Values different than 1 specify the scale of the icon on default gui scale.
Scale 2 means that the icon will be 2 times bigger on screen (and more pixelated).

Latest revision as of 14:32, 25 October 2024

The prototype docs have moved to a new website with an improved format. This documentation page can now be found here: https://lua-api.factorio.com/latest/types/IconData.html

This wiki page is no longer updated and will be removed at some point in the future, so please update your browser bookmarks or other links that sent you here. If you'd like to contribute to the new docs, you can leave your feedback on the forums.