Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
Fix: [AI/GS] AreWaterTilesConnected wasn't handling aqueducts properly #8074
There are 2 bugs being fixed. I have attached a scenario and an AI that must run with each other.
Bug 1: As an example, tiles 1700 and 1764 are connected, but AreWaterTilesConnected reports that they're not. There are others similar tiles that fall into the same bug.
This PR attempts to fix those cases while still maintaining the results the same for the other test cases. I'm sure I didn't handle all the possible cases, but I hope the fixes don't break anything.
This bug is missing a root cause analysis.
The real issue seems to be, that the direction passed to GetTileTrackStatus needs an additional GetReverseDiagDir, since GetTileTrackStatus expects an exitdir, while to_other_tile seems to be an enterdir.