Create landfill ghost ?

Place to get help with not working mods / modding interface.
Post Reply
staviq
Fast Inserter
Fast Inserter
Posts: 129
Joined: Wed Jun 29, 2016 1:22 pm
Contact:

Create landfill ghost ?

Post by staviq »

I have a problem, where if i change a tile via surface.set_tiles landfill ghosts on this tile are deleted for some reason.

I'm trying to solve this problem by making a list of tiles i need to re create landfill ghost at, but i can't find a correct way to create a landfill ghost.

Code: Select all

for tgk,tgv in pairs(tileghosts) do
	evtsurface.create_entity( { name = "entity-ghost", inner_name = "landfill", position = tgv } )
end
results in "Unknown entity name: landfill", even though when the game creates landfill ghost it's ghost_name is literally "landfill"


What is the correct way to create landfill ghost at given tile, or perhaps is it possible to preserve the original landfill ghost when using set_tiles ?

Post Reply

Return to “Modding help”