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

Track type change breaks Two-Way EOL #5944

Closed
DorpsGek opened this issue Mar 16, 2014 · 9 comments
Closed

Track type change breaks Two-Way EOL #5944

DorpsGek opened this issue Mar 16, 2014 · 9 comments
Labels
bug Something isn't working component: NewGRF This issue is related to NewGRFs flyspray This issue is imported from FlySpray (https://bugs.openttd.org/) patch from FlySpray This issue is in fact a Patch, but imported from FlySrpay stale Stale issues

Comments

@DorpsGek
Copy link
Member

Hazzard opened the ticket and wrote:

Version: r26379 (probably all versions)

When Two-Way EOL is enabled,

Reported version: trunk
Operating system: All


This issue was imported from FlySpray: https://bugs.openttd.org/task/5944
@DorpsGek
Copy link
Member Author

Hazzard wrote:

When Two-Way EOL is enabled, it will usually force a train into a depot. However, if the track (of the depot) is of a different type, the train will not be forced into the depot.

Attachments


This comment was imported from FlySpray: https://bugs.openttd.org/task/5944#comment13158

@DorpsGek
Copy link
Member Author

DorpsGek commented Mar 20, 2014

Hazzard wrote:

Related to #5216


This comment was imported from FlySpray: https://bugs.openttd.org/task/5944#comment13161

@DorpsGek
Copy link
Member Author

cirdan wrote:

I am interested in fixing this issue in my development branch, and I think I have found out what is going on. Could you please upload a savegame exhibiting this behaviour, so that I can do further testing?


This comment was imported from FlySpray: https://bugs.openttd.org/task/5944#comment13180

@DorpsGek
Copy link
Member Author

Hazzard wrote:

Sure
You may need to enter "set yapf.rail_firstred_twoway_eol 1"
Note the different behavior when the depot is changed from electric to non-electric.

Attachments


This comment was imported from FlySpray: https://bugs.openttd.org/task/5944#comment13181

@DorpsGek
Copy link
Member Author

cirdan wrote:

Thanks! Your savegame is perfect for testing.

What happens here is that the wrong branch is being pruned when the first signal found is a red two-way signal but the best intermediate node so far is behind a junction, because the code starts pruning at the best intermediate node instead of at the segment that ends at the signal.

I have published a fix in my development branch (http://repo.or.cz/w/openttd/fttd.git/commit/2699f279fa7d75bbb09f1ddd07616f4743a6acef) in case anyone wants to pick it up.


This comment was imported from FlySpray: https://bugs.openttd.org/task/5944#comment13183

@DorpsGek
Copy link
Member Author

LordAro wrote:

Diff attached, for posterity

Attachments


This comment was imported from FlySpray: https://bugs.openttd.org/task/5944#comment14552

@DorpsGek DorpsGek added flyspray This issue is imported from FlySpray (https://bugs.openttd.org/) Vehicles labels Apr 7, 2018
@TrueBrain TrueBrain added patch from FlySpray This issue is in fact a Patch, but imported from FlySrpay bug Something isn't working and removed bug from FlySpray labels Apr 13, 2018
@frosch123 frosch123 added component: NewGRF This issue is related to NewGRFs and removed Vehicles labels Apr 14, 2018
@andythenorth andythenorth added the stale Stale issues label Jan 5, 2019
@andythenorth
Copy link
Contributor

andythenorth commented Jan 5, 2019

Thanks for this. There's been no activity on this for some time, and as it stands, it doesn't look likely that it will go any further. Since OpenTTD moved to GitHub, we use pull requests rather than patches, as they are a much more productive workflow.

I'm planning to close this, as we try to keep the issue count low for OpenTTD, it helps us focus on things that are important and fun.

If you would like to continue with this patch, the best way would be to move the patch to your own GitHub fork, update it for the current OpenTTD master, and then create a pull request. For more information, please see our CONTRIBUTING.md.

We are also happy to discuss directly on the issue, or in #openttd irc, including help to get this into a pull request. Thanks for your contribution!

@Eddi-z
Copy link
Contributor

Eddi-z commented Jan 5, 2019

The diff attached here is useless, as it is deeply dependent on previous commits in that "development branch" and it is unclear at first glance what that branch is meant to do or how to isolate the change in question

@andythenorth
Copy link
Contributor

Based on Eddi's I am now closing this. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working component: NewGRF This issue is related to NewGRFs flyspray This issue is imported from FlySpray (https://bugs.openttd.org/) patch from FlySpray This issue is in fact a Patch, but imported from FlySrpay stale Stale issues
Projects
None yet
Development

No branches or pull requests

5 participants