Transport Fever 2

Transport Fever 2

Priority signals for tracks
51 Comments
lollus  [author] 25 Apr @ 3:59am 
I don't understand, sorry.
joshwiz23 3 Apr @ 8:46am 
I like the passin segment. I thought thats what ordinary signals are supposed to do? but when i tried with ordinary signmals the game just ignores and the signla is green then 2 trains get stuck on the one way track. even right in front of this station when the train is stopped there or on its way to the station. elsewhere it can work so idk the issue.
What is the difference with priority signals i dont get it? thx
lollus  [author] 10 Jan @ 6:51am 
You decide which tracks get priority and which do not, the signals do not look at train speed. I use "fast train" as short for "train transiting along a track with priority signals".
Old Knotty 19 Dec, 2024 @ 6:46am 
This looks interesting, thank you for developing the mod. Before I try it out, what constitutes a faster or a slower train? For freight trains, I usually try to make them all have close to the same weight and power. This helps them fit behind one another in each block between signals, making the most of busy tracks. How, then, would the priority signal decide which train to let through first?
Brummbær 2 Nov, 2024 @ 8:53am 
This is probably the one feature I was missing in game right from the beginning. It's frustrating, when your highspeed trains stop, because a slow cargo train just got to it's signal a bit faster. Would be even better if we could designate trains as priority, but this mod solves the problem almost as well. Good job =)
Jean-Luc Picard 9 Oct, 2024 @ 5:57am 
I tried again yesterday with the old version of Transport Fever 2 (pre autumn patch) and it seems to work just fine. I would be very grateful if you can take a look again and update to the current version, I guess the new autumn version with three way switches broke your script!
lollus  [author] 7 Oct, 2024 @ 4:08am 
Stations end the route calculations, ie priority a signal before a station will not affect what happens after the station.
Jean-Luc Picard 6 Oct, 2024 @ 9:33am 
Does the routing stop at stations completely are does it consider passing tracks for faster lines built into the station?
lollus  [author] 10 Jul, 2024 @ 8:18am 
You may have a concurrent mod, or an error in the layout. If it worked before, it is weird that it fails now, after no changes whatsoever.
You may have a new mod that hogs gameScript.update(), maybe the minimap?
† Young Gun Tenne † 9 Jul, 2024 @ 3:42am 
Ergänzen sollte ich noch, dass die untergeordneten Fahrten mitten auf der Weiche stehen bleiben, sie fahren dann nicht mal komplett vorbei
† Young Gun Tenne † 9 Jul, 2024 @ 3:41am 
Aktuell fahren die Züge an den "normalen Signalen" einfach in den Fahrtweg der Prioritäts Fahrt und blockieren so den Zug. Muss dann die untergeordneten Fahrten erst zurück fahren lassen. So ist das blöd. Ich habe vor einigen Wochen die Strecke noch ohne Probleme betrieben, es sind keine Mods oder etwas neues dazu gekommen. Was kann ich tun?
Canadian_67 10 Jan, 2024 @ 3:47pm 
Finally!
gohkenytp 7 Jan, 2024 @ 4:47pm 
Would've been fun if there were also Priority signs for motor vehicles
lollus  [author] 16 Nov, 2023 @ 3:19am 
You can use invisible priority signals and decorate them with functionless signals from your mod.
MaxCheng95 15 Nov, 2023 @ 4:43am 
Hi there! Is there any future plans to have varients of signal models from other mods or how can one create a priority signal with other signal modals?
lollus  [author] 9 Sep, 2023 @ 7:45am 
This is more or less how it works.
meki98 8 Sep, 2023 @ 6:19pm 
is it possible to have master and slave signals ?
basically the master controls the mainline
and the slave signals wait for the green from the master before giving green to the sidings
Benjamin Crewz 19 Aug, 2023 @ 8:23am 
Would be a perfect mod if there was a togglable option for all train signals instead of another signal. :O
lollus  [author] 26 Jun, 2023 @ 1:29am 
Was hast du gemacht? Was passiert? Was denkst du, dass stattdessen passieren sollte?
mallard4468 25 Jun, 2023 @ 6:04am 
Kann es sein, dass sich Züge selbstständig auf "Angehalten" stellen, wenn sie an Prioritätssignalabschnitten angehalten werden?
Aegyssus 23 Jun, 2023 @ 11:07am 
YES
I knew I was missing something and just now found your mod !!!
Awesome
lollus  [author] 12 May, 2023 @ 6:48am 
Du hast wahrscheinlich eine andere Mod, die Scheisse baut; oder du hast nicht die letzte Version von dieser Mod. Auf jedem Fall, mit Fehlermeldungen ohne vernünftige Problembeschreibungen kann ich nichts anfangen.
Segrob 12 May, 2023 @ 4:18am 
wenn ich die signal leiste öfne stürst mir transport fiver ab!
lollus  [author] 11 May, 2023 @ 3:00am 
No I cannot, the game does a lot of magic with signals. However, you can use the invisible version and plop down an asset that looks like a signal, so you have form and function.
tsilaicosneknurd 11 May, 2023 @ 12:31am 
I like that mod a lot.
But could it be possible to just add a checkbox to existing signals, that makes it a priority signal? that way favorised/national variants could be used.
lollus  [author] 12 Apr, 2023 @ 7:43am 
I might add an invisible version. In the meantime, let me know if this thing works well and if it slows down the game.
stein 11 Apr, 2023 @ 11:53am 
Invisible version would be perfect!
sgyxu 11 Apr, 2023 @ 9:10am 
Hi, this mod is a brilliant work, but I wish if you could update a invisible version of priority signal to fit with other style of signal instead of vanilla. That's will be perfect mod, many thanks.
melectro 4 Apr, 2023 @ 7:52pm 
I placed the signal at the problematic section and here is the result: It is working without any lagging! :steamthumbsup:

Thank you!
lollus  [author] 4 Apr, 2023 @ 3:57am 
I posted a couple of small updates for this and for the automatic displays: install them first.
If the lag is solved, OK.

Otherwise, read on and help me guess.
lollus  [author] 4 Apr, 2023 @ 1:34am 
Go to the second intersection (the lagging one).
Go to the priority signal.
Following the white arrow (open the rail construction menu to bring it up), find the first place where two or more tracks cross.
From the cross, follow every stretch of track and make sure there is a signal (or a station) close by, just outside the intersection; it does not matter if it points towards the cross or the other way, or if it has priority, as long as there is one. If you find other crosses or switches in the process, follow all branches linked to them and make sure there is a signal (or a station) on each.
-> Does it still lag?

-> In any case, can you remake this layout without any other mods and post the savegame on swisstransfer or wetransfer? Chances are, the mod cannot resolve the intersection quickly enough and it needs a bit more slicing, and a (small) savegame will help me repro the lag.
melectro 3 Apr, 2023 @ 7:12pm 
Adding info

Today I tested the mod by placing the first and only signal on a different section. Here it works without any lagging:
https://steamuserimages-a.akamaihd.net/ugc/2030601140709593083/2E36BCBA23D97AA319843CDE6375753A72601AA2/?imw=5000&imh=5000&ima=fit&impolicy=Letterbox&imcolor=%23000000&letterbox=false

but at the intersection where it is really needed it doesn't. Lagging occur directly when signal is placed shown in the image. When the signal is removed the game is running as normal.
https://steamuserimages-a.akamaihd.net/ugc/2030601140709593274/276D43F0C7762EA1D08F96E52DE04256A0C44B22/?imw=5000&imh=5000&ima=fit&impolicy=Letterbox&imcolor=%23000000&letterbox=false

I hope I can help you find the cause because your mod idea is really good!
lollus  [author] 3 Apr, 2023 @ 5:00am 
I don't use that toxic forum, but thanks.
melectro 2 Apr, 2023 @ 7:21pm 
Timetable, yes
advanced statistics, yes
Common API, yes
Natural Environment Professional yes
rail and track industry mod, yes
active mods 213
road waypoints about 55
railrod signals about 350
If you like to investigate details: I have sent the log file and the ".sav.lua " .file to you in the tpf.net forum
lollus  [author] 2 Apr, 2023 @ 4:24pm 
What mods have you got that perform operations at every tick? Timetables? Advanced something? Digital displays? How many track signals, track waypoints, road waypoints and streetside stations have you got, in total?
melectro 1 Apr, 2023 @ 8:02pm 
Really nice idea! I can also confirm the lagging and changing the numCoroutineResumesPerTick to 1 makes it better, but it doesn't solve the lagging.

I would also benefit from an api that can set both railway and street signals to red. The ultimate solution would be that even ships could be stopped with signals.
lollus  [author] 30 Mar, 2023 @ 3:16pm 
I just released an experimental version with coroutines. They might work faster on weaker processors or very packed games.
If it's still too slow, set numCoroutineResumesPerTick to 3 or 2 or 1 and see if it gets better.
Marco aus Berlin 30 Mar, 2023 @ 8:46am 
I was waiting for such a mod for a long time, but after placing the first priority signal, my game started to lag extremely - up to 5 seconds every 10 seconds or so. I still had 40 to 60 fps, but the game was not playable anymore.

I tried it several times with priority signals at different locations on the map, but my game started to lag instantly every time.
lollus  [author] 29 Mar, 2023 @ 8:36am 
If you want to make priority signals look different, you can try and make a mod for this mod as I explained below to themeatballhero.
Elje0ett 29 Mar, 2023 @ 7:55am 
But is there some way of having a priority signal but its also a signal from a mod or would you have to make this into a script mod then?
themeatballhero 29 Mar, 2023 @ 5:59am 
yes, thats what i figured, just wasn't sure how tied to the mdl the mod was (havent been able to take a look at the code)

ModelCitizen may be interested in this!
lollus  [author] 29 Mar, 2023 @ 5:31am 
I believe you can write a "mod to a mod" that overwrites the /railroad/lollo_priority_signals/*.mdl files, and load it after this.
themeatballhero 29 Mar, 2023 @ 5:15am 
very cool. how easy is it to replace the mdl for another mesh, to add more signals to this?
76561198282054594 29 Mar, 2023 @ 3:36am 
Thanks for this GREAT mod. At least my mainline get's what it's entitled to: Priority over the branches and industrial sidings! (Could well be that this mod wil be one of the most used mods).

____________:loco::carriage::carriage::carriage::carriage::chooo::steamthumbsup::steamthumbsup::steamthumbsup:____________
Adam.. 29 Mar, 2023 @ 2:26am 
THANKYOU
EoF 28 Mar, 2023 @ 11:43am 
This way I wonder if it would conflict with the timetable mod. Definitely would be very helpful if this came out pre-timetable
mongolteiko 28 Mar, 2023 @ 11:25am 
That last picture looks like they both got green and passed the signal....crash! lol
lollus  [author] 28 Mar, 2023 @ 5:15am 
@Blast yes it does, hopefully
@EoF no, I crudely stop the trains. An API to turn signals red would help, but there isn't one for now.
Blast Hardcheese 28 Mar, 2023 @ 2:27am 
This looks like it will work perfectly for two lines on separate tracks merging into one track where there is need for priority of one of the lines.
EoF 28 Mar, 2023 @ 1:19am 
How does this function? Does the game allow signal/block programming now?