maniak1349 wrote:While you at it, can you add an optional player-configurable signal to trains that will be transmitted alongside with the train id?
I don't like the idea of sending both a unique Train-ID (probably generated from some internal game entity ID) and a player-defined signal. In my opinion, it should be only one signal, either one or the other. Otherwise it would get too complicated.
In my opinion, the best solution would be to allow the user to specify an ID value for the train to send in the train orders window. That way, it would also be also possible for several trains to share an ID value if, for example, you want them to be treated the same way by the circuit network. However, if you want all trains to have a unique ID, you can do that too.
This would also allow grouping and assigning properties to trains. For example, I could assign all my iron ore trains an ID between 1000 and 1999 and all my copper trains an ID between 2000 and 2999. In other words, the first digit would define the type of train. Also, I could, for example, assign the length of the train to the second digit. That way, a train with an ID of 2348 would be a copper train with a length of 3. All of this information could easily be extracted by the circuit network simply by reading the ID of the train. The possibilities would be endless.
If the player is too lazy to assign a Train-ID to every one of his trains, the value sent by the train could default to either the number 1 (just a simple signal) or the internal Train-ID of the game. This ID would of course have to always be nonzero, because the circuit network is unable to distinguish between an empty station and a station with a train with an ID of 0.
: In this post, I proposed that the player should be able to specify the custom Train-ID in the train orders window. However, in this suggestion thread
, it has been proposed that the Locomotives can be set to act as a constant combinator, whose signal is then sent to the circuit network when the train stops at a station. I believe that this suggestion may be more in the spirit of Factorio than my suggestion.