Code: Select all
{
type = "item",
name = "foo",
icon = "__base__/graphics/icons/battery.png",
flags = {},
subgroup = "foo-group",
order = "b",
place_result = "foo",
stack_size = 50,
},
{
type = "simple-entity",
name = "foo",
icon = "__base__/graphics/icons/battery.png",
flags = {"placeable-neutral", "not-on-map", "placeable-off-grid", "player-creation"},
minable = {hardness = 0.1, mining_time = 0.1, result = "foo"},
max_health = 0,
picture =
{
filename = "__base__/graphics/icons/battery.png",
priority = "extra-high",
width = 32,
height = 32,
},
render_layer = "object",
},
Code: Select all
/c game.player.surface.create_entity{name="entity-ghost", inner_name="foo", position=game.player.position, force=game.player.force}
Code: Select all
Cannot execute command. Error: Entity creation of entity-ghost failed stack traceback: [string "game.player.surface.create_entity{name="entit..."].1: in main chunk