Hi everyone. This game, and this branch of the game in particular are right up my alley, so I'm joining the project to write some code and knock some items off of the todo list. I'm tackling the maintenance stuff first. After looking over the existing systems and what's been proposed, here's how I think everything should end up fitting together.
Wear
Vehicles wear out through use, increasing maintenance costs and reducing resale value. Wear increases slowly at first, then quickly as major parts reach the end of their intended lifespans, and then slowly again. Wear is measured in kilometers. The properties of this S-shaped curve are defined in the pakset based on:
- the original maintenance costs / resale value
- a maximum maintenance cost / minimum resale value
- the number of kilometers of wear at which the maximum cost is reached
- the number of kilometers of wear where the greatest increase in cost occurs
Regular maintenance
Vehicles normally accumulate wear at a 1:1 ratio of kilometers traveled to kilometers of wear. If a vehicle is not maintained regularly, the rate of wear increases due to neglect. Vehicles must visit a depot for annual maintenance to avoid this penalty. Convoys will automatically visit a depot on their schedule once per year based on the following rules. All depot visits should use these rules, including visits triggered by clicking Go To Depot and future Upgrade orders.
- The rate of extra wear due to lack of maintenance should be universal, but configured by the pakset / potentially overriden by player configuration
- Each depot will only automatically service one convoy per line at a time
- Each depot has a maximum number of convoys that it can service at once
- To avoid convoys dumping loads of cargo on each depot visit, the decision to visit a depot (and reserving a spot) will happen each time the convoy skips a depot on the schedule, rather than at the last minute
- The length of time needed to service a vehicle is determined by availability % data for that vehicle in the pakset
- Maintenance time for a convoy is equal to the longest maintenance time out of the vehicles in the convoy
Overhauls
Vehicles which are not obsolete can be overhauled, which resets their wear kilometers to zero. The cost to do so must be less than the net cost of selling the vehicle and purchasing a new one. Whether overhauls occur automatically should be enabled/disabled on a per-line basis. If disabled, a message should be presented to inform the player that it's time for an overhaul. Automated overhauls/messages will occur at the time when maintenance costs are increasing at their greatest rate. Obsolete vehicles cannot be overhauled, as the necessary parts are no longer available. An obsolete vehicle must be upgraded to one that is not obsolete or scrapped. This eliminates the need for any explicit obsolescence penalty; the vehicle will reach its maximum maintenance cost and remain there naturally once it can no longer be overhauled or upgraded.
What does everyone think about this? I know there's been some concerns about requiring regular maintenance at depots, but I think this strikes the right balance between all concerns. There shouldn't be any micromanagement; all of the required decision making happens at the network planning and construction stages or during fleet management.