[0.16.12] Crash on placing entity

Things that has been reported already before.
User avatar
darkfrei
Smart Inserter
Smart Inserter
Posts: 2905
Joined: Thu Nov 20, 2014 11:11 pm
Contact:

[0.16.12] Crash on placing entity

Post by darkfrei »

Error message:
2018-01-09 19_21_03.png
2018-01-09 19_21_03.png (99.23 KiB) Viewed 1005 times
How to reproduce: just place this entity.

Log file, dump and mod with this entity:
factorio-dump_001.7z
(108.41 KiB) Downloaded 80 times
Free_Real_Estate_1.1.0.7z
(468.25 KiB) Downloaded 78 times
save_0.16_error_01.zip
(6.99 MiB) Downloaded 75 times
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,
	})
<few hours of exploring>

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},
	})
Last edited by darkfrei on Tue Jan 09, 2018 9:23 pm, edited 3 times in total.
Bilka
Factorio Staff
Factorio Staff
Posts: 3677
Joined: Sat Aug 13, 2016 9:20 am
Contact:

Re: [0.16.12] Crash on placing entity

Post by Bilka »

Duplicate: 56407 ?
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.
User avatar
darkfrei
Smart Inserter
Smart Inserter
Posts: 2905
Joined: Thu Nov 20, 2014 11:11 pm
Contact:

Re: [0.16.12] Crash on placing entity

Post by darkfrei »

Bilka wrote:Duplicate: 56407 ?
Ohh, yes.
Post Reply

Return to “Duplicates”