Factorio Prototype DocsVersion 1.1.107

ItemGroup - 'item-group' Example code

An item group. Item groups are the tabs shown above the list of craftable items in the player's inventory GUI. The built-in groups are "logistics", "production", "intermediate-products" and "combat" but mods can define their own.

Items are sorted into item groups by sorting them into a subgroup which then belongs to an item group.

Prototype limited to 255 total instances.

Inherits from PrototypeBase

Properties

icons optional :: array[IconData]

The icon that is shown to represent this item group. [...]

The icon that is shown to represent this item group. [...]

icon optional :: FileName

Path to the icon that is shown to represent this item group. [...]

Path to the icon that is shown to represent this item group. [...]

icon_size optional :: SpriteSizeType

The size of the square icon, in pixels. [...]

The size of the square icon, in pixels. [...]

icon_mipmaps optional :: IconMipMapType

Icons of reduced size will be used at decreased scale.

Icons of reduced size will be used at decreased scale.

order_in_recipe optional :: Order

Item ingredients in recipes are ordered by item group. [...]

Item ingredients in recipes are ordered by item group. [...]

Inherited from PrototypeBase
type :: string

Specifies the kind of prototype this is. [...]

Specifies the kind of prototype this is. [...]

name :: string

Unique textual identification of the prototype. [...]

Unique textual identification of the prototype. [...]

order optional :: Order

Used to order prototypes in inventory, recipes and GUIs. [...]

Used to order prototypes in inventory, recipes and GUIs. [...]

localised_name optional :: LocalisedString

Overwrites the name set in the locale file. [...]

Overwrites the name set in the locale file. [...]

localised_description optional :: LocalisedString

Overwrites the description set in the locale file. [...]

Overwrites the description set in the locale file. [...]

Properties

icons :: array[IconData] optional

The icon that is shown to represent this item group. Can't be an empty array.

icon :: FileName optional

Path to the icon that is shown to represent this item group.

Mandatory if icons is not defined.

icon_size :: SpriteSizeType optional

The size of the square icon, in pixels. E.g. 32 for a 32px by 32px icon.

Mandatory if icons is not defined, or if icon_size is not specified for all instances of icons.

icon_mipmaps :: IconMipMapType optional

Default: 0

Icons of reduced size will be used at decreased scale.

order_in_recipe :: Order optional

Default: The order of this item group.

Item ingredients in recipes are ordered by item group. The order_in_recipe property can be used to specify the ordering in recipes without affecting the inventory order.

Example

{
  type = "item-group",
  name = "logistics",
  order = "a",
  icon = "__base__/graphics/item-group/logistics.png",
  icon_size = 128,
  icon_mipmaps = 2
}

Prototypes

Types