Page 1 of 1

LuaSurface.create_entity{mirroring=true}

Posted: Sat Oct 26, 2024 11:36 am
by sparr
I would like to be able to do this for all entity types that support mirroring, and also their ghosts.

Code: Select all

/c game.player.surface.create_entity{position={game.player.position.x+5,game.player.position.y},direction=0,force=game.player.force,mirroring=false,recipe="heavy-oil-cracking",name="chemical-plant"} game.player.surface.create_entity{position={game.player.position.x-5, game.player.position.y},direction=0,force=game.player.force,mirroring=true,recipe="heavy-oil-cracking",name="chemical-plant"} game.player.surface.create_entity{position={game.player.position.x+5,game.player.position.y+10},direction=0,force=game.player.force,mirroring=false,recipe="heavy-oil-cracking",name="entity-ghost",ghost_name="chemical-plant"} game.player.surface.create_entity{position={game.player.position.x-5, game.player.position.y+10},direction=0,force=game.player.force,mirroring=true,recipe="heavy-oil-cracking",name="entity-ghost",ghost_name="chemical-plant"}

Re: LuaSurface.create_entity{mirroring=true}

Posted: Sat Oct 26, 2024 5:22 pm
by ahicks
This also sort of falls under my request for flipping blueprints fwiw. Not exactly a duplicate but I will cross-link that since they are related concerns: viewtopic.php?f=28&t=114819