[boskid] Splitter LuaTransportLine.output_lines

This subforum contains all the issues which we already resolved.
Post Reply
User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3612
Joined: Tue May 13, 2014 11:06 am
Contact:

[boskid] Splitter LuaTransportLine.output_lines

Post by DaveMcW »

I have a splitter, which contains 8 LuaTransportLines. If I select one of 4 output LuaTransportLines, I would expect that it only outputs to one line, since it is already past the splitter section.

However, this code prints 2, indicating it found two output lines. Further examination shows that it found lines with index 5 and 7.

Code: Select all

/c
splitter = game.player.surface.create_entity{name="splitter", position={0, 0.5}, force=game.player.force}
transport_line = splitter.get_transport_line(5)
game.print(#transport_line.output_lines)
Is this a bug?

User avatar
boskid
Factorio Staff
Factorio Staff
Posts: 1787
Joined: Thu Dec 14, 2017 6:56 pm
Contact:

Re: [boskid] Splitter LuaTransportLine.output_lines

Post by boskid »

Yes, it is a bug. It was incorrectly considering those output transport lines as the input transport lines because front entity covered by those transport lines was a splitter. This issue would only show when asking for output lines of unconnected splitter's output transport lines. Issue is now fixed for 1.1.54

Post Reply

Return to “Resolved Problems and Bugs”