[1.1.107] LuaSurface.create_entity docs missing stack property
Posted: Mon Apr 15, 2024 9:00 pm
Attempting to create an item-on-ground with LuaSurface.create_entity without providing the stack parameter results in an error.
https://lua-api.factorio.com/latest/cla ... ate_entity
The stack property works fine, however it is not documented that it is accepted by the function.
/c game.player.surface.create_entity{name = "item-on-ground", position = game.player.position}
Error: Key "stack" not found in property tree
/c game.player.surface.create_entity{name = "item-on-ground", position = game.player.position, stack = "blueprint"} works sucessfully. I assume it accepts a SimpleItemStack.
https://lua-api.factorio.com/latest/cla ... ate_entity
The stack property works fine, however it is not documented that it is accepted by the function.
/c game.player.surface.create_entity{name = "item-on-ground", position = game.player.position}
Error: Key "stack" not found in property tree
/c game.player.surface.create_entity{name = "item-on-ground", position = game.player.position, stack = "blueprint"} works sucessfully. I assume it accepts a SimpleItemStack.