Transport Fever 2

Transport Fever 2

Street fine tuning
156 Comments
scarecrowwill23 9 Jun @ 2:28pm 
I have a problem i dont have the Items to build or fine tuning
takashi 5 May @ 9:38am 
I am able to understand it much better than when I first read it.
I'll write down the points that I didn't quite understand at first, so that others can take it as reference.

・Bus lane: If there is an alternative road, AI vehicles will not use it. In other words, it will be exclusive to your trucks and buses.

・ There are two places where locking is mentioned: Locking prevents the AI ​​from automatically creating roads that connect to the locked road.

・On roads with multiple lanes in each direction: trams only run on the outermost lane.

・This mod exists to connect one road to many other roads.

・I tried to write it simply. It might be wrong.

Finally, I'd like to thank the creator for the MOD.
Ragno 27 Jan @ 3:13am 
Proverò grazie :D
lollus  [author] 27 Jan @ 2:59am 
Aprilo con un editor di testo tipo VS Code, aggiungi quelle due righe lì e salva.
La stazione dei camion la copi dal gioco (è un file *.mdl), la apri con VS Code, togli il contenuto di "lods", salvala come parte di un nuovo mod. Per far prima copia da qualche altro mod perché devi rispettare certe regole, tipo avere una directory "res" e un file "mod.lua". Poi salva il tutto dentro la directory "staging_area".
Ragno 27 Jan @ 2:51am 
Thanks, I will try to modify this mod, but I have never modded this game before and don't know the code. :)

Anyway, here is another question not related to your mod (i hope you can respond): Is there a way to make a truck station cargo completely invisible for customization? I want to create an industry with an invisible cargo station inside.
lollus  [author] 26 Jan @ 5:20am 
That mod is buggy but you can fix it yourself:

setPriorityModifier = function (fileName, data)
if data and data.name then -- THIS IS WHAT I ADDED
for prefix, priority in pairs(streetPriorityLookupTable) do
if string.find(data.name , prefix) == 1 then
data.priority = priority
end
end
end -- AND THIS OF COURSE

return data
end

Try fixing it (instead of deactivating) and see if your game starts.
lollus  [author] 26 Jan @ 3:06am 
What minor version are you playing?
Are you using https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2563512381 ?
Can you reproduce your error in a test game with only this mod installed?
Ragno 26 Jan @ 2:15am 
Hello, what type of problem there is here?

Lua exception

Exception type: Lua exception

This error is usually caused by modding. Some game resources contain incorrect data.

Details:

Error message: error: F:/SteamLibrary/steamapps/workshop/content/1066780/2563512381/mod.lua:52: bad argument #1 to 'find' (string expected, got nil)
stack traceback:
=[C](-1) :?
=[C](-1): find
@F:/SteamLibrary/steamapps/workshop/content/1066780/2563512381/mod.lua(52): v
@res/scripts/mod.lua(102): origApplyModifiers
@F:/SteamLibrary/steamapps/workshop/content/1066780/2267827829/res/scripts/eatglobal/mod.lua(163): ?


File name: F:/SteamLibrary/steamapps/workshop/content/1066780/2021038808/res/config/street/lollo_ultrathin_street.lua

Minidump: D:/STEAM/userdata/467138915/1066780/local/crash_dump/5d02357c-a794-4a3e-9296-1dbc347e76df.dmp

Mod: "Street fine tuning" (*2021038808, 1) (consider removing this mod and contacting the mod author)
Eddie Krueger 9 Nov, 2024 @ 4:11am 
Okay, thanks!
And I just realized I'm blind, because there is a dedicated thread for this in Popular Discussions... Anyway, thanks again!
lollus  [author] 9 Nov, 2024 @ 3:22am 
I think it's available from 1925.
Eddie Krueger 8 Nov, 2024 @ 10:43pm 
Is it possible that it's not available before a certain date? I've got Info, the two Splitters and Flat Foundation only.
https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=3362495984
lollus  [author] 8 Nov, 2024 @ 7:35am 
It's in the "street constructions" menu.
Eddie Krueger 6 Nov, 2024 @ 8:24am 
I'm missing something. How can I put tracks in every lane on a four-lane road/street?
galaxy055 18 Oct, 2024 @ 4:37am 
@Ragno
Not crashes with this mod but some weird glitches where in some places passenger busses/trams stops at bus stop but then never leave. However with his modular lorry station mod I do have crashes and had to remove that mod.
Ragno 27 Sep, 2024 @ 10:41pm 
Hi, Anyone have crash with the last update or only me?
lollus  [author] 19 Apr, 2024 @ 1:53am 
I am sorry about that. I'd suggest:
- verify the game files once again
- disconnect the PC from the internet
- move all the other mods to a temporary directory. Later, you can restore them in batches, until you have found the culprit.
- start a fresh game with this mod only
tom13 18 Apr, 2024 @ 11:01am 
I am useing Windows 10.
I know that something is not right, because usually it should not crash... Well, i guess I have to save my savegames and reinstall the game, while hoping that it works. Checking my game files with Steam did not help. Let's see what the support says
lollus  [author] 13 Apr, 2024 @ 4:03pm 
Are you on a Mac by any chance? Everything works fine on my PC. Something is not right.
tom13 13 Apr, 2024 @ 2:25pm 
Since nothing worked out so far, I tried to just create a completly new savegame, but with your mod enabled. I had no other active mods, except for you and still I get the nil value gamecrash. Now not at 4% but at 6%... And yes, I checked my game files for errors xd
lollus  [author] 12 Apr, 2024 @ 1:59pm 
You need to be patient and disable more mods until you single out the culprit. You can disable a few, then a few more, in batches, so it won't take forever. You can also try a test game with this mod alone, then you add a few more and so on.
tom13 12 Apr, 2024 @ 1:46pm 
Disableing the yellow bus lanes in the setting did not help. I even disabeled all building mods, but that did not help. Still the error message with the nil value.
lollus  [author] 7 Apr, 2024 @ 4:22pm 
It appears that some other mod tampers with the street materials. Try disabling the yellow bus lanes in the mod settings. If it still crashes, try disabling some more mods until you find the culprit.
tom13 6 Apr, 2024 @ 11:17am 
Error message: error: [string "D:/Steam/steamapps/workshop/content/1066780/2021038808/res/models/material/street/new_medium_bus (2021_03_22 16_37_21 UTC).mtl"]:3: attempt to call field 'get' (a nil value)
stack traceback:
=[C](-1): get
D:/Steam/steamapps/workshop/content/1066780/2021038808/res/models/material/street/new_medium_bus (2021_03_22 16_37_21 UTC).mtl(3): ?
tom13 6 Apr, 2024 @ 11:17am 
Well, I unsubscribed and redownloaded your mod again, deactivated all street or road mods (I went through my whole modlist) and also deactivated the common api. I left your mod active with all other street mod inactive but still it crashed at 4%.
lollus  [author] 29 Mar, 2024 @ 10:12am 
Unsubscribe and subscribe again, to be sure you have the latest version of this mod and it is not tampered with. Then undo any changes you have made to the game files.
Now, the required files will be there and you will be able to see them with Windows Explorer at /steamapps/workshop/content/1066780/2021038808/res/config/street (or something like that).
If the game fails anyway, there is bound to be some other mod that tampers with them. To fix this, disable your other street mods and the common api. This might cause more crashes if you are unlucky.
I am wary of that website and street mods in general. Hopefully, you keep an orderly collection of savegames and you can revert to a previous one with fewer mods installed.
tom13 28 Mar, 2024 @ 4:35pm 
Details:

Error message: 1 resource file(s) are missing:
res/config/street/lollo_large_4_lane_4_tram_tracks_country_road.lua

Minidump: D:/Steam/userdata/243878057/1066780/local/crash_dump/3d821c0a-726b-4dd2-a689-d2dfb4866aea.dmp

In file: urban_games/train_fever/src/Game/GameStateLegacyHandler.cpp:2051

In function: void __cdecl GameStateLegacyHandler::MakeCheckFn::<lambda_bf736033d0919dea2f66d7b605f00f46>::operator ()(const class ecs::Engine *) const
tom13 28 Mar, 2024 @ 4:35pm 
__CRASHDB_CRASH__ struct ResourceMismatchException: urban_games/train_fever/src/Game/GameStateLegacyHandler.cpp:2051: void __cdecl GameStateLegacyHandler::MakeCheckFn::<lambda_bf736033d0919dea2f66d7b605f00f46>::operator ()(const class ecs::Engine *) const: 1 resource file(s) are missing:
res/config/street/lollo_large_4_lane_4_tram_tracks_country_road.lua
Exception type: Resource mismatch error

This error is usually caused by modding. In some cases, existing save games cannot be loaded with a modified game version, since resources have been deleted or modified.
tom13 28 Mar, 2024 @ 4:34pm 
When you mod is active, it still crashes at 4% now, but when I deacitvate it, it loads until 70% before it crashes. I added the 3 mentioned lua files into the games default folder, where all the other lua files for streets are. I even added the mentioned "res/config/street/lollo_large_4_lane_4_tram_tracks_country_road.lua" there, but sadly the game still crashes at 70%, but this time just because the latter lua file could not be found. Can you tell me where it has to be placed? I found it at "\steamapps\workshop\content\1066780\2021038808\res\config\street" but that seems not to be enough
AverageEuropeanTramEnjoyer 28 Mar, 2024 @ 4:56am 
@lollus https://www.transportfever.net/filebase/entry/6263-eis-os-strassenpaket-strassen-mit-rasengleis-mitteltram/
Requires CommonAPI2 [www.transportfever.net] along with NewLineEvents enabled in the API menu.
lollus  [author] 28 Mar, 2024 @ 12:45am 
Try deactivating the mod with
res/config/street/standard/parkslots_side_45.lua
res/config/street/standard/parkslots_side_45_90.lua
res/config/street/standard/parkslots_side_90
(find it with Windows Explorer) and see if the crash persists.
tom13 27 Mar, 2024 @ 7:01pm 
Minidump: D:/Steam/userdata/243878057/1066780/local/crash_dump/f17b97c6-c79d-4bb1-b574-f6a4d5711f97.dmp

In file: urban_games/train_fever/src/Game/GameStateLegacyHandler.cpp:2051

In function: void __cdecl GameStateLegacyHandler::MakeCheckFn::<lambda_bf736033d0919dea2f66d7b605f00f46>::operator ()(const class ecs::Engine *) const


__CRASHDB_CRASH__ struct ResourceMismatchException: urban_games/train_fluaever/src/Game/GameStateLegacyHandler.cpp:2051: void __cdecl GameStateLegacyHandler::MakeCheckFn::<lambda_bf736033d0919dea2f66d7b605f00f46>::operator ()(const class ecs::Engine *) const: 4 resource file(s) are missing:
res/config/street/lollo_large_4_lane_4_tram_tracks_country_road.lua
res/config/street/standard/parkslots_side_45.lua
res/config/street/standard/parkslots_side_45_90.lua
res/config/street/standard/parkslots_side_90.
tom13 27 Mar, 2024 @ 7:01pm 
When I deactivate your mod in order to avoid my game crashing at 4%, it keeps loading the game until 70% until it crashes with: Details:

Error message: 4 resource file(s) are missing:
res/config/street/lollo_large_4_lane_4_tram_tracks_country_road.lua
res/config/street/standard/parkslots_side_45.lua
res/config/street/standard/parkslots_side_45_90.lua
res/config/street/standard/parkslots_side_90.lua
lollus  [author] 27 Mar, 2024 @ 3:59pm 
What mod is that?
AverageEuropeanTramEnjoyer 27 Mar, 2024 @ 2:55pm 
Apparently this mod removes the roads from CAPI2 streetpackage that has tram lanes in the middle.
lollus  [author] 2 Feb, 2024 @ 3:24pm 
A stab in the dark: this second error could have to do with a mod that makes new cargo types, or a vehicle that is supposed to carry it.
tom13 2 Feb, 2024 @ 2:39pm 
Do you have any alternative idea?
tom13 2 Feb, 2024 @ 2:38pm 
I used the programm now and deactivated all the mods that appear when I search for "api.res". Once I even deactivated yours but it still does not work then.
Assertion Failure: Assertion `AreIdsUnique(legacyLoad)' failed.

Minidump: D:/Steam/userdata/243878057/1066780/local/crash_dump/dc0d3e10-822c-4081-8a5a-01a442f5c6b5.dmp

In file: urban_games/train_fever/src/Game/transport/CargoTypeRep.cpp:74

In function: __cdecl transport::CargoTypeRep::CargoTypeRep(const class FileSystem *,const class lua::Loader *,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >)
lollus  [author] 9 Dec, 2023 @ 6:08pm 
lollus  [author] 9 Dec, 2023 @ 2:11pm 
Install Visual Studio Code.
Use it to open the folder where you keep your mods (right click the folder + open with Visual Studio Code).
Now find "api.res" in all files (Ctrl + Shift + F).
This will probably find a handful of mods, so you can narrow it down.
tom13 9 Dec, 2023 @ 12:15pm 
And if I load the savegame without your mod: __CRASHDB_CRASH__ struct AssertException: Urban_games/train_fever/src/Game/transport/CargoTypeRep.cpp:74: __cdecl transport::CargoTypeRep::CargoTypeRep(const class FileSystem *,const class lua::Loader *,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >): Assertion `AreIdsUnique(legacyLoad)' failed. Exception type: Fatal error Details: Assertion Failure: Assertion `AreIdsUnique(legacyLoad)' failed. Minidump:
/Steam/userdata/243878057/1066780/local/crash_dump/6f4b5347-8ce0-4640-829f-234565536a56.dmp In file: urban_games/train_fever/src/Game/transport/CargoTypeRep.cpp:74
In function: __cdecl transport::CargoTypeRep::CargoTypeRep(const class FileSystem *,const class lua::Loader *,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >) MinidumpCallback: dumpPath "D:/Steam/userdata/243878057/1066780/local/crash_dump/", minidumpId "5cb2e33a-015b-485a-b7e0-793142958b62"
tom13 9 Dec, 2023 @ 11:02am 
__CRASHDB_CRASH__ struct lua::LuaException: urban_games/train_fever/src/Lib/lua/State.cpp:646: void __cdecl lua::State::Call(int,int): error: [string "*2021038808_1::res/models/material/street/new_medium_bus (2021_03_22 16_37_21 UTC).mtl"]:3: attempt to call field 'get' (a nil value)
stack traceback:
=[C](-1): get
*2021038808_1::res/models/material/street/new_medium_bus (2021_03_22 16_37_21 UTC).mtl(3): ?
Exception type: Lua exception
This error is usually caused by modding. Some game resources contain incorrect data.
Details:
Error message: error: [string "D:/Steam/steamapps/workshop/content/1066780/2021038808/res/models/material/street/new_medium_bus (2021_03_22 16_37_21 UTC).mtl"]:3: attempt to call field 'get' (a nil value) stack traceback:
=[C](-1): get D:/Steam/steamapps/workshop/content/1066780/2021038808/res/models/material/street/new_medium_bus (2021_03_22 16_37_21 UTC).mtl(3): ?
tom13 9 Dec, 2023 @ 10:58am 
Here is what the Crash log tells me. Do you have a guess which mod or which kind of mod could cause it? It used to run perfectly fine in March when I played the last time: __CRASHDB_DUMP__ 21434a0e-ea64-4101-977e-a735e02aeaba
ModelRep: 872641 ms
Exception during init
Exception type: Lua exception

This error is usually caused by modding. Some game resources contain incorrect data.

Details:

Error message: error: [string "D:/Steam/steamapps/workshop/content/1066780/2021038808/res/models/material/street/new_medium_bus (2021_03_22 16_37_21 UTC).mtl"]:3: attempt to call field 'get' (a nil value)
stack traceback:
=[C](-1): get
D:/Steam/steamapps/workshop/content/1066780/2021038808/res/models/material/street/new_medium_bus (2021_03_22 16_37_21 UTC).mtl(3): ?


Minidump: D:/Steam/userdata/243878057/1066780/local/crash_dump/21434a0e-ea64-4101-977e-a735e02aeaba.dmp

In file: urban_games/train_fever/src/Lib/lua/State.cpp:646

In function: void __cdecl lua::State::Call(int,int)
tom13 8 Dec, 2023 @ 4:22pm 
I get the same error like Nightquest. Nightquest, can you please tell me which other mod caused the error then? I have too many to try each one out manually
lollus  [author] 5 Dec, 2023 @ 2:18am 
From the docu: "Both slicers destroy themselves after placement, leaving your road split in two segments. Debug mode and AltGr + L will reveal their effect."
Pdguru 4 Dec, 2023 @ 7:12pm 
Is there a tutorial for this somewhere? I have no idea what you mean by "slicing" etc.
Snazz 2 Mar, 2023 @ 3:45pm 
Thanks for keeping this mod updated Lollus. It's one of the true game-changers.
Nightquest 30 Jan, 2023 @ 3:42pm 
Sorry, you are right, the error was not caused by the original files, rather because of my modifications. I did it long time ago, I forgot about it. So it was a false alarm :)
lollus  [author] 28 Jan, 2023 @ 3:55pm 
I don't know where that "res/models/material/backup/street/new_medium_bus.mtl" comes from, it's not part of the mod. You probably need to update this mod, or remove a conflicting mod.
If the problem persists, write a detailed error description.
Nightquest 28 Jan, 2023 @ 3:34pm 
It doesn't work with the new beta, the error is:

Error message: error: [string "res/models/material/backup/street/new_medium_bus.mtl"]:3: attempt to call field 'get' (a nil value)
stack traceback:
=[C](-1): get
res/models/material/backup/street/new_medium_bus.mtl(3): ?
Nolantherailfan 28 Jan, 2023 @ 10:14am 
There is a mod that I always use which is the american roads mod, what will happen if I keep that On?