| Inherits from SpriteSource |
| priority optional | :: SpritePriority | |
| flags optional | :: SpriteFlags | |
| shift optional | :: Vector | The shift in tiles. [...] |
The shift in tiles. [...] | ||
| rotate_shift optional | :: bool | |
| apply_special_effect optional | :: bool | |
| scale optional | :: double | Values other than |
Values other than | ||
| draw_as_shadow optional | :: bool | Only one of |
Only one of | ||
| draw_as_glow optional | :: bool | Only one of |
Only one of | ||
| draw_as_light optional | :: bool | Only one of |
Only one of | ||
| mipmap_count optional | :: uint8 | Only loaded if this is an icon, that is it has the flag |
Only loaded if this is an icon, that is it has the flag | ||
| apply_runtime_tint optional | :: bool | |
| tint_as_overlay optional | :: bool | |
| invert_colors optional | :: bool | |
| tint optional | :: Color | |
| blend_mode optional | :: BlendMode | |
| generate_sdf optional | :: bool | This property is only used by sprites used in UtilitySprites that have the |
This property is only used by sprites used in UtilitySprites that have the | ||
| surface optional | :: SpriteUsageSurfaceHint | Provides hint to sprite atlas system, so it can try to put sprites that are intended to be used at the same locations to the same sprite atlas. |
Provides hint to sprite atlas system, so it can try to put sprites that are intended to be used at the same locations to the same sprite atlas. | ||
| usage optional | :: SpriteUsageHint | Provides hint to sprite atlas system, so it can pack sprites that are related to each other to the same sprite atlas. |
Provides hint to sprite atlas system, so it can pack sprites that are related to each other to the same sprite atlas. | ||
| filename | :: FileName | The path to the sprite file to use. |
The path to the sprite file to use. | ||
| size optional | :: SpriteSizeType or {SpriteSizeType, SpriteSizeType} | The width and height of the sprite. [...] |
The width and height of the sprite. [...] | ||
| width optional | :: SpriteSizeType | Mandatory if |
Mandatory if | ||
| height optional | :: SpriteSizeType | Mandatory if |
Mandatory if | ||
| x optional | :: SpriteSizeType | Horizontal position of the sprite in the source file in pixels. |
Horizontal position of the sprite in the source file in pixels. | ||
| y optional | :: SpriteSizeType | Vertical position of the sprite in the source file in pixels. |
Vertical position of the sprite in the source file in pixels. | ||
| position optional | :: {SpriteSizeType, SpriteSizeType} | Loaded only when |
Loaded only when | ||
| load_in_minimal_mode optional | :: bool | Minimal mode is entered when mod loading fails. [...] |
Minimal mode is entered when mod loading fails. [...] | ||
| premul_alpha optional | :: bool | Whether alpha should be pre-multiplied. |
Whether alpha should be pre-multiplied. | ||
| apply_runtime_tint optional | :: bool | |
| apply_special_effect optional | :: bool | |
| blend_mode optional | :: BlendMode | |
| draw_as_glow optional | :: bool | Only one of |
Only one of | ||
| draw_as_light optional | :: bool | Only one of |
Only one of | ||
| draw_as_shadow optional | :: bool | Only one of |
Only one of | ||
| flags optional | :: SpriteFlags | |
| generate_sdf optional | :: bool | This property is only used by sprites used in UtilitySprites that have the |
This property is only used by sprites used in UtilitySprites that have the | ||
| invert_colors optional | :: bool | |
| mipmap_count optional | :: uint8 | Only loaded if this is an icon, that is it has the flag |
Only loaded if this is an icon, that is it has the flag | ||
| priority optional | :: SpritePriority | |
| rotate_shift optional | :: bool | |
| scale optional | :: double | Values other than |
Values other than | ||
| shift optional | :: Vector | The shift in tiles. [...] |
The shift in tiles. [...] | ||
| surface optional | :: SpriteUsageSurfaceHint | Provides hint to sprite atlas system, so it can try to put sprites that are intended to be used at the same locations to the same sprite atlas. |
Provides hint to sprite atlas system, so it can try to put sprites that are intended to be used at the same locations to the same sprite atlas. | ||
| tint optional | :: Color | |
| tint_as_overlay optional | :: bool | |
| usage optional | :: SpriteUsageHint | Provides hint to sprite atlas system, so it can pack sprites that are related to each other to the same sprite atlas. |
Provides hint to sprite atlas system, so it can pack sprites that are related to each other to the same sprite atlas. | ||
| filename | :: FileName | The path to the sprite file to use. |
The path to the sprite file to use. | ||
| height optional | :: SpriteSizeType | Mandatory if |
Mandatory if | ||
| load_in_minimal_mode optional | :: bool | Minimal mode is entered when mod loading fails. [...] |
Minimal mode is entered when mod loading fails. [...] | ||
| position optional | :: {SpriteSizeType, SpriteSizeType} | Loaded only when |
Loaded only when | ||
| premul_alpha optional | :: bool | Whether alpha should be pre-multiplied. |
Whether alpha should be pre-multiplied. | ||
| size optional | :: SpriteSizeType or {SpriteSizeType, SpriteSizeType} | The width and height of the sprite. [...] |
The width and height of the sprite. [...] | ||
| width optional | :: SpriteSizeType | Mandatory if |
Mandatory if | ||
| x optional | :: SpriteSizeType | Horizontal position of the sprite in the source file in pixels. |
Horizontal position of the sprite in the source file in pixels. | ||
| y optional | :: SpriteSizeType | Vertical position of the sprite in the source file in pixels. |
Vertical position of the sprite in the source file in pixels. | ||

Default: "medium"


Default: {0, 0}
The shift 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.

Default: 1
Values other than 1 specify the scale of the sprite on default zoom. A scale of 2 means that the picture will be two times bigger on screen (and thus more pixelated).

Default: false
Only one of draw_as_shadow, draw_as_glow and draw_as_light can be true. This takes precedence over draw_as_glow and draw_as_light.

Default: false
Only one of draw_as_shadow, draw_as_glow and draw_as_light can be true. This takes precedence over draw_as_light.
Draws first as a normal sprite, then again as a light layer. See https://forums.factorio.com/91682.

Default: false
Only one of draw_as_shadow, draw_as_glow and draw_as_light can be true.

Default: 0
Only loaded if this is an icon, that is it has the flag "group=icon" or "group=gui". Will be clamped to range [0, 5].

Default: {r=1, g=1, b=1, a=1}

Default: "normal"

Default: false
This property is only used by sprites used in UtilitySprites that have the "icon" flag set.
If this is set to true, the game will generate an icon shadow (using signed distance fields) for the sprite.

Default: "any"
Provides hint to sprite atlas system, so it can try to put sprites that are intended to be used at the same locations to the same sprite atlas.

Default: "any"
Provides hint to sprite atlas system, so it can pack sprites that are related to each other to the same sprite atlas.

Prototypes
Types
Defines