Could there be an option in create_entity to force placement or respect collision?
I used this code in my control.lua to demonstrate the issue
Code: Select all
script.on_event(defines.events.on_chunk_generated, function(event)
local boundingBox = event.area
local surface = event.surface
local pos1 = boundingBox.left_top
local pos2 = {boundingBox.left_top.x+1,boundingBox.left_top.y+1}
local pos3 = {boundingBox.left_top.x+2,boundingBox.left_top.y+2}
local ent1 = surface.create_entity({
name="assembling-machine-1",
position=pos1,
force='player'
})
surface.create_entity({
name="assembling-machine-1",
position=pos2,
force='player'
})
surface.create_entity({
name="iron-ore",
position=pos3,
})
end)