diff options
author | rubidium <rubidium@openttd.org> | 2007-02-13 10:26:53 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2007-02-13 10:26:53 +0000 |
commit | eb5648f38206e98b03aa3ca5783faafdde390884 (patch) | |
tree | a8d30d13565c6ebb15b7a0857e33c317d033e666 /src/rail_cmd.cpp | |
parent | 3f74dbe5c075610637ec10a0b077a0a8710fd610 (diff) | |
download | openttd-eb5648f38206e98b03aa3ca5783faafdde390884.tar.xz |
(svn r8698) -Codechange: enumify the returns of VehicleEnterTile
Diffstat (limited to 'src/rail_cmd.cpp')
-rw-r--r-- | src/rail_cmd.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/rail_cmd.cpp b/src/rail_cmd.cpp index 04deae559..bb8ba81a8 100644 --- a/src/rail_cmd.cpp +++ b/src/rail_cmd.cpp @@ -1946,7 +1946,7 @@ static uint32 VehicleEnter_Track(Vehicle *v, TileIndex tile, int x, int y) int length; // this routine applies only to trains in depot tiles - if (v->type != VEH_Train || !IsTileDepotType(tile, TRANSPORT_RAIL)) return 0; + if (v->type != VEH_Train || !IsTileDepotType(tile, TRANSPORT_RAIL)) return VETSB_CONTINUE; /* depot direction */ dir = GetRailDepotDirection(tile); @@ -1965,7 +1965,7 @@ static uint32 VehicleEnter_Track(Vehicle *v, TileIndex tile, int x, int y) if (_fractcoords_behind[dir] == fract_coord) { /* make sure a train is not entering the tile from behind */ - return 8; + return VETSB_CANNOT_ENTER; } else if (_fractcoords_enter[dir] == fract_coord) { if (DiagDirToDir(ReverseDiagDir(dir)) == v->direction) { /* enter the depot */ @@ -1976,7 +1976,7 @@ static uint32 VehicleEnter_Track(Vehicle *v, TileIndex tile, int x, int y) v->tile = tile; InvalidateWindowData(WC_VEHICLE_DEPOT, v->tile); - return 4; + return VETSB_ENTERED_WORMHOLE; } } else if (fract_coord_leave == fract_coord) { if (DiagDirToDir(dir) == v->direction) { @@ -1988,7 +1988,7 @@ static uint32 VehicleEnter_Track(Vehicle *v, TileIndex tile, int x, int y) } } - return 0; + return VETSB_CONTINUE; } |