diff options
author | tron <tron@openttd.org> | 2006-03-05 12:34:55 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2006-03-05 12:34:55 +0000 |
commit | 586388c9f17a39b4d3a7e7706fe6b40191a922b4 (patch) | |
tree | 113bde0444e78799f198050654eba4d96e28702e /npf.c | |
parent | f007ad282c60cc1b2529b44c3e0b4c1bdab3d685 (diff) | |
download | openttd-586388c9f17a39b4d3a7e7706fe6b40191a922b4.tar.xz |
(svn r3767) Move all direction related enums and functions to a separate header
Diffstat (limited to 'npf.c')
-rw-r--r-- | npf.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -162,11 +162,11 @@ static uint NPFTunnelCost(AyStarNode* current) { DiagDirection exitdir = TrackdirToExitdir((Trackdir)current->direction); TileIndex tile = current->tile; - if ((DiagDirection)GB(_m[tile].m5, 0, 2) == ReverseDiagdir(exitdir)) { + if ((DiagDirection)GB(_m[tile].m5, 0, 2) == ReverseDiagDir(exitdir)) { /* We just popped out if this tunnel, since were * facing the tunnel exit */ FindLengthOfTunnelResult flotr; - flotr = FindLengthOfTunnel(tile, ReverseDiagdir(exitdir)); + flotr = FindLengthOfTunnel(tile, ReverseDiagDir(exitdir)); return flotr.length * NPF_TILE_LENGTH; //TODO: Penalty for tunnels? } else { @@ -543,7 +543,7 @@ static void NPFFollowTrack(AyStar* aystar, OpenListNode* current) * otherwise (only for trains, since only with trains you can * (sometimes) reach tiles after reversing that you couldn't reach * without reversing. */ - if (src_trackdir == DiagdirToDiagTrackdir(ReverseDiagdir(exitdir)) && type == TRANSPORT_RAIL) { + if (src_trackdir == DiagdirToDiagTrackdir(ReverseDiagDir(exitdir)) && type == TRANSPORT_RAIL) { /* We are headed inwards. We can only reverse here, so we'll not * consider this direction, but jump ahead to the reverse direction. * It would be nicer to return one neighbour here (the reverse @@ -596,7 +596,7 @@ static void NPFFollowTrack(AyStar* aystar, OpenListNode* current) * orientation. They are only "inwards", since we are reaching this tile * from some other tile. This prevents vehicles driving into depots from * the back */ - ts = TrackdirToTrackdirBits(DiagdirToDiagTrackdir(ReverseDiagdir(exitdir))); + ts = TrackdirToTrackdirBits(DiagdirToDiagTrackdir(ReverseDiagDir(exitdir))); } else { ts = GetTileTrackStatus(dst_tile, type); } |