Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skip Old Town pathfinding penalties for buses and taxi (optional) #1618

Merged
merged 1 commit into from
Jul 25, 2022

Conversation

krzychu124
Copy link
Member

After Dark DLC required

Optional pathfinding penalty skip for buses and taxi for segments in area with Old Town policy enabled.

This enhancement could be more accurate and eliminate cases where vehicles would use Old Town districts as a shortcut but determining district ID based only on segment is quite costly so I abandoned the idea. Still, better than nothing, might be improved later when we collect some more feedback how it actually works outside of simple testing scenarios.


This enhancement is pretty easy to test. Vanilla applies ~7x cost penalty so the key is to add bus stops outside of the district but making the road layout provoking vehicles to use Old Town as shortcut (they won't if not allowed).

Worth noting is the fact that bus line overlay may show incorrect path with the feature disabled where vehicle will go through Old Town but they actually won't follow restricted part of the path, unless you put bus stop in the district which obviously force them to enter it (less likely to overflow path penalty score on short paths between stops), so enhancement settings in that particular case won't make any difference.


Settings stored in GlobalConfig, both disabled by default (vanilla)

Closes #371 , closes #361

Test build zip

@krzychu124 krzychu124 added enhancement Improve existing feature Annoyance Not a bug, but just as annoying PATHFINDER Pathfinding tweaks or issues labels Jul 22, 2022
@krzychu124 krzychu124 added this to the 11.6.6.0 milestone Jul 22, 2022
@krzychu124 krzychu124 self-assigned this Jul 22, 2022
Copy link
Contributor

@chameleon-tbn chameleon-tbn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link
Collaborator

@kvakvs kvakvs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice

@krzychu124 krzychu124 merged commit 2de056a into master Jul 25, 2022
@krzychu124 krzychu124 deleted the enhancment/371-old-town-policy branch July 25, 2022 17:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Annoyance Not a bug, but just as annoying enhancement Improve existing feature PATHFINDER Pathfinding tweaks or issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Old Town policy shouldn't affect public transport Taxis despawn but roads are connected
3 participants