Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

limit trains by composition signal #93

Closed
Sil3ntStorm opened this issue Dec 31, 2017 · 6 comments
Closed

limit trains by composition signal #93

Sil3ntStorm opened this issue Dec 31, 2017 · 6 comments

Comments

@Sil3ntStorm
Copy link

Sil3ntStorm commented Dec 31, 2017

There are two kind of trains available to LTN, a 1-1-1 and a 1-2-1.

The target station outputs 5 for encoded locomotive location, but LTN keeps creating the order on a 1-2-1 train, which doesn't match the locomotive locations asked for.

It also created an order on a 1-1-1 afterwards for a target station requesting a locomotive location of 9 and cargo wagon location of 6, which is asking for 1-2-1 trains.

LTN 1.6.1 on Factorio 0.16.10

@0ptera
Copy link
Owner

0ptera commented Dec 31, 2017

The problem with using composition as filter instead of train size was explained in an post in the old discussion thread:

Train composition can be used to service different train sizes and configurations in one station.
Why is it not a input?
Train composition is directional with the LSB facing the stop. When leaving a station trains change their front and back depending on track layout (RoRo vsTerminus) and the signal would become ambiguous.

@0ptera 0ptera closed this as completed Dec 31, 2017
@0ptera 0ptera changed the title Wrong train chosen for delivery limit trains by composition signal Dec 31, 2017
@Sil3ntStorm
Copy link
Author

so you're saying that having these composition signals is basically useless as it doesn't prevent trains that mismatch the station design from getting sent there.
I could have a train with say 1-4-1 and a train with 2-2-2, which both are the same length getting sent to any station. Which would mean that the 2-2-2 train would be sent to a station dealing with 1-4-1 trains, or even worse the other way around. As such the station won't be able to unload the train, nor would it necessarily be able to unload the requested amount from such a train as it won't fit into the limited cargo wagons matching up with the unloading equipment.
With the addition of artillery wagons, one may even add those to some trains which could also become an issue quickly.

I guess you're going to say one can do things with the outputs but rather than setting up overly complex, large (and expensive) circuitry at every station dealing with decoding the signal then disable some inserters / pumps it'd be much more fitting to do that in the request and only send matching trains.

@0ptera
Copy link
Owner

0ptera commented Dec 31, 2017

Composition signals are read only signals used to create stations capable of servicing multiple compositions
Have inserters capable of serving any composition and activate only the ones at positions with cargo wagons. It requires 4 additional combinators + 1 per cargo wagon position, I'd hardly call that overly complicated.

@labmonkey42
Copy link

I still wish for something like this in order to differentiate between solid and fluid trains. While I think I understand the forward/reverse ambiguity argument, how about the following logic:

  1. read the composition of each available train
  2. for each train, read the composition of that train in reverse order, discarding that train its composition is asymmetric
  3. attempt to select a train by composition from any remaining trains
    This means that selecting trains by composition would not work for asymmetric trains, but that's no different from the current behavior.

Using similar logic, a train could select a depot to which is should return:

  1. compare train composition with reverse composition
  2. if composition is symmetric, select a depot by composition; else select by current logic

Apologies for rehashing an old issue here, but I'd really like to see this work in order to avoid composing trains in which length indicates composition (primarily in order to standardize station blueprints).

@0ptera
Copy link
Owner

0ptera commented Feb 11, 2018

Since 1.7.0 stations can be assigned multiple network IDs.
Practically there's no need for limiting by length or composition any more.

@labmonkey42
Copy link

Fair enough. That handles every concern I can think of which would make use of train composition as input. Thanks for the feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants