How to reproduce: just place this entity.
Log file, dump and mod with this entity: The error comes here: %mod_folder%\factory\factory.lua
Code: Select all
local bb = factory.prototype.selection_box
local entry_item_pos = {x=factory.position.x, y=factory.position.y + bb.right_bottom.y - 0.5}
local exit_item_pos = {x=mid+1.0, y=bottom+3}
-- players can teleport if they manage to reach an exit in another factory somehow
-- probably not a big problem
self.transit.enter = global.waypoints:create({
item_surface=factory.surface,
item_pos=entry_item_pos,
tp_surface=surface,
tp_pos={exit_item_pos.x, exit_item_pos.y-3},
fresh=true,
data=self,
})
self.transit.exit = global.waypoints:create({
item_surface=surface,
item_pos=exit_item_pos,
tp_surface=factory.surface,
tp_pos={entry_item_pos.x, entry_item_pos.y+1.5},
fresh=false,
})The error comes with negative health of item on the ground.
Code: Select all
local negative_health = -100
surface.create_entity({
name='fre_item-pickup-only', -- prototype type = "item-entity"
position=transit.item_pos,
force='neutral',
stack={name='fre_factory_transit', count=1, health=negative_health},
})
