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

DiagonalTileIterator bug #4395

Closed
DorpsGek opened this issue Jan 9, 2011 · 3 comments
Closed

DiagonalTileIterator bug #4395

DorpsGek opened this issue Jan 9, 2011 · 3 comments
Labels
flyspray This issue is imported from FlySpray (https://bugs.openttd.org/)

Comments

@DorpsGek
Copy link
Member

DorpsGek commented Jan 9, 2011

xi opened the ticket and wrote:

DiagonalTileIterator access one tile more then once -> cost estimate with shift + CTRL shows bad costs (2x - 3x more)

Reported version: 1.1.0-beta2
Operating system: All


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

DorpsGek commented Jan 9, 2011

Rubidium wrote:

Some tiles are really iterated over twice.


This comment was imported from FlySpray: https://bugs.openttd.org/task/4395#comment9439

@DorpsGek
Copy link
Member Author

DorpsGek commented Jan 9, 2011

fonsinchen wrote:

This should fix it. The problem is that the lines defined by coordinate b in the rotated system "overlap". Every second rotated coordinate a points to a tile that's also in the previous line. By starting at the right place and always adding 2 instead of 1 to the a coordinates this can be fixed.

Attachments


This comment was imported from FlySpray: https://bugs.openttd.org/task/4395#comment9440

@DorpsGek
Copy link
Member Author

DorpsGek commented Jan 9, 2011

Rubidium closed the ticket.

Reason for closing: Fixed

In r21747. Thanks for the fix fonsinchen.


This comment was imported from FlySpray: https://bugs.openttd.org/task/4395

@DorpsGek DorpsGek closed this as completed Jan 9, 2011
@DorpsGek DorpsGek added Core flyspray This issue is imported from FlySpray (https://bugs.openttd.org/) labels Apr 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
flyspray This issue is imported from FlySpray (https://bugs.openttd.org/)
Projects
None yet
Development

No branches or pull requests

1 participant