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

Feature: Reverse train at waypoint orders (jgr) #7362

Closed
wants to merge 3 commits into from

Conversation

@PeterN
Copy link
Member

PeterN commented Mar 10, 2019

This adds an order type to reverse trains at waypoints. This is, admittedly, somewhat frivolous (teaching pathfinders to do similar might be more useful.)

Cherry-picked from jgrpp with conflicts and savegame changes resolved by me.

JGRennison added 3 commits Oct 28, 2015
The train will reverse when its tail is within the waypoint tile.
This is useful for reversing on train en-route, without creating
dedicated reversing sidings or platforms.
@JGRennison
Copy link
Contributor

JGRennison commented Mar 10, 2019

teaching pathfinders to do similar might be more useful.

For what it's worth I've implemented something along these lines in JGRennison/OpenTTD-patches@cd41683, the pathfinder part was unexpectedly non-trivial (YAPF-only, I've not bothered with OPF/NPF).

@PeterN
Copy link
Member Author

PeterN commented Mar 10, 2019

Yeah, the pathfinders are definitely not prepared for finding paths with reversing.

@Eddi-z
Copy link
Contributor

Eddi-z commented Mar 10, 2019

IIRC the last time we tried teaching the pathfinder about reversing we got stuck with trains having a non-zero length, and thus some options from the end of the line not being available (because the reversed train head would be beyond those)

@stale
Copy link

stale bot commented Apr 10, 2019

This pull request has been automatically marked as stale because it has not had any activity in the last month.
Please feel free to give a status update now, ping for review, or re-open when it's ready.
It will be closed if no further activity occurs within 7 days.
Thank you for your contributions.

@stale stale bot added the stale label Apr 10, 2019
@stale stale bot closed this Apr 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.