[2.0.20] ItemStackDefinition.quality should be QualityID
Posted: Wed Nov 20, 2024 11:34 pm
The type of "ItemStackDefinition.quality" is currently "string" but it should be "QualityID" (string or prototype).
All of the following commands work, showing that both string and prototype are accepted by "ItemStackDefinition.quality":
(params are of type "ItemStackIdentification" -> "SimpleItemStack" -> "ItemStackDefinition")
All of the following commands work, showing that both string and prototype are accepted by "ItemStackDefinition.quality":
(params are of type "ItemStackIdentification" -> "SimpleItemStack" -> "ItemStackDefinition")
Code: Select all
/c game.player.surface.spill_item_stack{ position={5, 5}, stack={ name="iron-plate", quality="epic" } }
/c game.player.surface.spill_item_stack{ position={5, 5}, stack={ name="iron-plate", quality=prototypes.quality.epic } }
/c game.player.insert{ name="iron-plate", quality="epic" }
/c game.player.insert{ name="iron-plate", quality=prototypes.quality.epic }
/c game.player.get_main_inventory().find_empty_stack().set_stack{ name="iron-plate", quality="epic" }
/c game.player.get_main_inventory().find_empty_stack().set_stack{ name="iron-plate", quality=prototypes.quality.epic }