[1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Things that we don't consider worth fixing at this moment.
Post Reply
User avatar
steinio
Smart Inserter
Smart Inserter
Posts: 2632
Joined: Sat Mar 12, 2016 4:19 pm
Contact:

[1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Post by steinio »

Hej,

i have a modded rail which consists of vanilla rails attached with placeable_by.

Blueprints and copy shortcut selects the correct modded rail.
Pipetting it selects the vanilla rail whch is then placed instead.

I expect that the pipette has the same behaviour like the blueprint tools.

Cu, steinio.
Image

Transport Belt Repair Man

View unread Posts

Jaren Taq
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sat Nov 28, 2020 8:26 am
Contact:

Re: [1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Post by Jaren Taq »

Can you post, which mod or the prototype definition?

User avatar
steinio
Smart Inserter
Smart Inserter
Posts: 2632
Joined: Sat Mar 12, 2016 4:19 pm
Contact:

Re: [1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Post by steinio »

Jaren Taq wrote:
Sat Nov 28, 2020 4:01 pm
Can you post, which mod or the prototype definition?
Well if you're actually interested:
https://mods.factorio.com/mod/naked-rails_se

Place vanilla rails, convert them with the shortcut tool to naked rails for example and pipette it.

Cu, steinio.
Image

Transport Belt Repair Man

View unread Posts

Rseding91
Factorio Staff
Factorio Staff
Posts: 13175
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Post by Rseding91 »

I don't know if this has a solution. When using an item directly to build a fresh entity it will always use the place_result on the item. An item can only have 1 place result.

Entities can be built by multiple items (multiple items can place the same entity). In the case of a ghost the first item-to-place-this-entity is used to revive the ghost. So it "works" with placeable_-by. Same thing for blueprints; they're just ghosts in the blueprint.

But direct building has no entity reference so it defaults to the place_result of the item - in this case the vanilla rail.

So with all that said; your use-case is unsupported and I don't think it will ever be supported fully. Sorry.
If you want to get ahold of me I'm almost always on Discord.

User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5206
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: [1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Post by eradicator »

Rseding91 wrote:
Sat Nov 28, 2020 6:40 pm
In the case of a ghost the first item-to-place-this-entity is used to revive the ghost.
If only the first item is ever used, why is it possible to specify more than one placeable_by item? I always assumed bots use the first compatible item they can find in the logistic network (i.e. if there's three possible items but the player only produces one of them).
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13175
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Post by Rseding91 »

eradicator wrote:
Sat Nov 28, 2020 6:56 pm
Rseding91 wrote:
Sat Nov 28, 2020 6:40 pm
In the case of a ghost the first item-to-place-this-entity is used to revive the ghost.
If only the first item is ever used, why is it possible to specify more than one placeable_by item? I always assumed bots use the first compatible item they can find in the logistic network (i.e. if there's three possible items but the player only produces one of them).
I could remove that. But it's only going to break more stuff than it fixes.
If you want to get ahold of me I'm almost always on Discord.

User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5206
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: [1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Post by eradicator »

Rseding91 wrote:
Sat Nov 28, 2020 8:28 pm
eradicator wrote:
Sat Nov 28, 2020 6:56 pm
Rseding91 wrote:
Sat Nov 28, 2020 6:40 pm
In the case of a ghost the first item-to-place-this-entity is used to revive the ghost.
If only the first item is ever used, why is it possible to specify more than one placeable_by item? I always assumed bots use the first compatible item they can find in the logistic network (i.e. if there's three possible items but the player only produces one of them).
I could remove that. But it's only going to break more stuff than it fixes.
I was kinda hoping for an "you misunderstood, they're actually used in edge case xyz" answer D:.
If they're actually never ever used i'd prefer if at least the wiki description mentioned that. But i am unsure how the "first" item is even determined. I.e. if there is an item that can place an entity, but the entity prototype itself specifies another 2 placeable_by items (for a total of 3 differnt items) then what... the item is used? or the first entry in the placeable_by array? or some sort of (alphabetic-)order? Without that knowledge i couldn't even fix the wiki page.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.

User avatar
steinio
Smart Inserter
Smart Inserter
Posts: 2632
Joined: Sat Mar 12, 2016 4:19 pm
Contact:

Re: [1.1.2] Modded rail pipettes wrong entity if placeable_by is used

Post by steinio »

eradicator wrote:
Sat Nov 28, 2020 8:51 pm
Rseding91 wrote:
Sat Nov 28, 2020 8:28 pm
eradicator wrote:
Sat Nov 28, 2020 6:56 pm
Rseding91 wrote:
Sat Nov 28, 2020 6:40 pm
In the case of a ghost the first item-to-place-this-entity is used to revive the ghost.
If only the first item is ever used, why is it possible to specify more than one placeable_by item? I always assumed bots use the first compatible item they can find in the logistic network (i.e. if there's three possible items but the player only produces one of them).
I could remove that. But it's only going to break more stuff than it fixes.
I was kinda hoping for an "you misunderstood, they're actually used in edge case xyz" answer D:.
If they're actually never ever used i'd prefer if at least the wiki description mentioned that. But i am unsure how the "first" item is even determined. I.e. if there is an item that can place an entity, but the entity prototype itself specifies another 2 placeable_by items (for a total of 3 differnt items) then what... the item is used? or the first entry in the placeable_by array? or some sort of (alphabetic-)order? Without that knowledge i couldn't even fix the wiki page.
placeable_by != place_result
Image

Transport Belt Repair Man

View unread Posts

Post Reply

Return to “Won't fix.”