Changeset - r9049:e4d201d5e90d
[Not reviewed]
master
0 1 0
belugas - 17 years ago 2008-04-24 18:30:41
belugas@openttd.org
(svn r12875) -Codechange: Use defined const instead of cast magic
1 file changed with 6 insertions and 6 deletions:
0 comments (0 inline, 0 general)
src/station_cmd.cpp
Show inline comments
 
@@ -982,7 +982,7 @@ CommandCost CmdBuildRailroadStation(Tile
 
		if (flags & DC_EXEC) {
 
			st = new Station();
 

	
 
			st->town = ClosestTownFromTile(tile_org, (uint)-1);
 
			st->town = ClosestTownFromTile(tile_org, UINT_MAX);
 
			GenerateStationName(st, tile_org, STATIONNAMING_RAIL);
 

	
 
			if (IsValidPlayer(_current_player)) {
 
@@ -1406,7 +1406,7 @@ CommandCost CmdBuildRoadStop(TileIndex t
 
		if (flags & DC_EXEC) {
 
			st = new Station();
 

	
 
			st->town = ClosestTownFromTile(tile, (uint)-1);
 
			st->town = ClosestTownFromTile(tile, UINT_MAX);
 
			GenerateStationName(st, tile, STATIONNAMING_ROAD);
 

	
 
			if (IsValidPlayer(_current_player)) {
 
@@ -1541,7 +1541,7 @@ CommandCost CmdRemoveRoadStop(TileIndex 
 
		/* Rebuild the drive throuhg road stop. As a road stop can only be
 
		 * removed by the owner of the roadstop, _current_player is the
 
		 * owner of the road stop. */
 
		MakeRoadNormal(tile, road_bits, rts, is_towns_road ? ClosestTownFromTile(tile, (uint)-1)->index : 0,
 
		MakeRoadNormal(tile, road_bits, rts, is_towns_road ? ClosestTownFromTile(tile, UINT_MAX)->index : 0,
 
				is_towns_road ? OWNER_TOWN : _current_player, _current_player, _current_player);
 
	}
 

	
 
@@ -1831,7 +1831,7 @@ CommandCost CmdBuildBuoy(TileIndex tile,
 
	if (flags & DC_EXEC) {
 
		Station *st = new Station();
 

	
 
		st->town = ClosestTownFromTile(tile, (uint)-1);
 
		st->town = ClosestTownFromTile(tile, UINT_MAX);
 
		GenerateStationName(st, tile, STATIONNAMING_BUOY);
 

	
 
		if (IsValidPlayer(_current_player)) {
 
@@ -1991,7 +1991,7 @@ CommandCost CmdBuildDock(TileIndex tile,
 
		if (flags & DC_EXEC) {
 
			st = new Station();
 

	
 
			st->town = ClosestTownFromTile(tile, (uint)-1);
 
			st->town = ClosestTownFromTile(tile, UINT_MAX);
 
			GenerateStationName(st, tile, STATIONNAMING_DOCK);
 

	
 
			if (IsValidPlayer(_current_player)) {
 
@@ -2830,7 +2830,7 @@ void BuildOilRig(TileIndex tile)
 
		return;
 
	}
 

	
 
	st->town = ClosestTownFromTile(tile, (uint)-1);
 
	st->town = ClosestTownFromTile(tile, UINT_MAX);
 
	st->sign.width_1 = 0;
 

	
 
	GenerateStationName(st, tile, STATIONNAMING_OILRIG);
0 comments (0 inline, 0 general)