Transport Fever 2

Transport Fever 2

85 ratings
Auto Line Namer 0.1.4
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
2.432 MB
4 Nov, 2024 @ 2:07pm
7 Nov, 2024 @ 11:12am
5 Change Notes ( view )

Subscribe to download
Auto Line Namer 0.1.4

Description
Please use with caution
Please save your city before enabling the mod in case of sudden game crash, there is no known issues for now, but keeping a save is handy sometimes.

Automatic Line Naming (ALN) for Transport Fever 2

Description:
The Automatic Line Naming (ALN) mod for Transport Fever 2 dynamically generates names for player-created lines based on route details, transport type, and whether they carry cargo or passengers. This mod simplifies gameplay by automatically creating unique, informative names for each line, helping you keep track of your network effortlessly. Featuring configurable settings, renaming options, and detailed logging, ALN lets you focus on managing your network without the hassle of manual naming.

GitHub Repository[github.com]

Current Features

Automated Naming Convention:
Each line name follows this structure:
[Transport Type] - [(Cargo Types)]: [First Town Initials] - [Last Town Initials] [Line Type] #[Count]

Components of the Naming Convention:
  • Transport Type: Abbreviation based on transport mode (e.g., RC for Road Cargo, TP for Train Passenger).
  • Cargo Types: If applicable, displays the types of cargo in parentheses (e.g., (Grain)), or is left blank for passenger-only lines.
  • Town Initials: Up to three-letter initials of the starting and ending towns (e.g., Spr for Springfield).
  • Line Type:
    • LO (Local): A line that operates within a single town, typically shorter routes such as urban buses or short-distance trams.
    • IC (Intercity): A line that connects two distinct towns, often medium-range routes like regional trains, intercity buses, or cargo trucks between two locations.
    • RE (Regional): A line that passes through three or more towns, typically longer routes covering multiple cities or regions, like express trains or multi-stop cargo routes.
  • Count: If multiple lines share the same name, a unique count (e.g., #1, #2) is added to avoid duplicates.

Examples:
  • Road Cargo Line: RC - (Grain): Spr - Cap IC #1
  • Passenger Train Line: TP - Spr - She IC
  • Air Passenger Line: AP - Cap - Ogd LO

Transport Type Detection: Differentiates between passenger and cargo lines across all transport types, with shorthand for each mode.

Renaming Options:
  • Manual Refresh: Set a line’s name to "reload" or "r" to trigger an automatic renaming based on the current route and transport type.
  • Default Naming: Lines with default values (e.g., "Line 1", "Line 2") or prefixed with "UNK" are automatically renamed.
  • Tag Exclusion: Use the [NoAuto] tag to exclude lines from auto-renaming.

Upcoming Features

  • In-Game Customization GUI: Directly adjust naming conventions, logging levels, and tag exclusions in-game.
  • Additional Naming Patterns: More flexible patterns, including customizable prefixes and suffixes.
  • Support for Custom Cargo Types: Enhanced detection for modded or custom cargo types to improve naming accuracy.

How to Use

Install the Mod:
Subscribe on the Steam Workshop and enable it in Transport Fever 2’s mod settings.

Create a New Line:
Set up a line as usual. ALN will automatically generate a name based on its details. First, your line name will be an UNK, but when you add some stops and some vehicles, ALN will automatically update it. If you need to update it again, just rename the line with single "r" or "reload".

Rename Existing Lines:
ALN renames existing lines with default or placeholder names. You can also rename a line by setting its name to "reload" or "r".

Troubleshooting and Tips

Why is my line not renamed?
The line may already have a custom name or might not meet renaming conditions (e.g., no assigned stops). Set the line name to "reload" or "r" to force a renaming.

How do I exclude a line from renaming?
Use the [NoAuto] tag in the line name to prevent auto-renaming.

Notes
This mod automatically names new and default-named lines, making it ideal for quickly expanding your network. For feedback or bug reports, open an issue to GitHub Repository[github.com] or please leave a comment on the mod’s Steam Workshop page!

When creating this mod, I tutored myself using Timetables Mod and Linemanager Mod so special thanks to the creators.
31 Comments
Baedeker 21 Sep @ 6:04am 
Causes too many game crashes, even after you disable it.
华南小无 10 Sep @ 8:29am 
hello, It seems like you haven't updated your Githup code for a long time. I have added a default name judgment for Simplified Chinese characters. Can I add it to the Githup code repository?
H2O 30 Aug @ 8:19pm 
This a great! I looked at your script code and it is excellent. Thanks for including comments! I was looking at the code to see if I could find where the the names come from. The reason is, I changed the name of a station and even after an "r" it did not see the change..Looking at the code, it appears that the end points come from city names, not the station names. I wouldn't know how to fix it but, would it be possible to use station names instead? Regardless, thanks for a great mod!
Scullsglory 25 Aug @ 1:18pm 
Jo Mr. Devman. I fiddled around a bit and added automatic renaming support for other languages. Before the localized names weren't recognized.
I issued a merge request on the git, if you want to offiially add it. :)
Idle Boy 30 Jun @ 8:25am 
Used this for some games, works fine, but it needs some manual renames. I used "r" multiple times to force reload yet there were some issues with the cargo naming.

But i loved this mod. Thanks for your hard work. :steamthumbsup:
Sizzel 2 Jun @ 6:46pm 
any way to update this for industries expanded? with abbreviations for the new materials?
Ur Jesus !  [author] 7 Apr @ 2:19pm 
Hi all! It seems like I've given up on this, but it's not. Some life hustle and bustle kept going for me nowadays. I'll be publishing the new version soon with all the improvements comments mentioned. Have a good year!
roger_noel 29 Mar @ 5:05am 
Unfortunately not working for me. Nothing happens.
Sabretooth78 20 Jan @ 8:41am 
When assigning new vehicles to a new line, the vehicle manager seems to switch focus from the specific depot to "all". I'm assuming this is a result of the line's name being changed and the manager refreshing or something like that. Is there any chance this behavior could be prevented, and focus remains on the depot?

This is especially annoying when there are still more new vehicles to assign, and you need to go back down to the depot in the list - or as in my case you don't realize it did this and you think you still have the depot selected and then you accidentally reassign vehicles between lines!
PzSniper 18 Jan @ 5:47pm 
Hey @Ur Jesus, i can't wait for the customizable names update. How are progress so far bro?