Enable signals on bridges/tunnels to work with PBS.

This commit is contained in:
Jonathan G Rennison
2016-02-20 20:12:10 +00:00
parent 95a329a4b9
commit a25ac7a161
7 changed files with 63 additions and 11 deletions

View File

@@ -936,6 +936,10 @@ static void NPFFollowTrack(AyStar *aystar, OpenListNode *current)
break;
}
}
if (IsTileType(dst_tile, MP_TUNNELBRIDGE) && IsTunnelBridgeExit(dst_tile) && DiagDirToDiagTrackdir(GetTunnelBridgeDirection(dst_tile)) == dst_trackdir) {
/* Entering a signalled bridge/tunnel from the wrong side, equivalent to encountering a one-way signal from the wrong side */
break;
}
{
/* We've found ourselves a neighbour :-) */
AyStarNode *neighbour = &aystar->neighbours[i];