Changeset - r7733:285865abadc4
[Not reviewed]
master
0 1 0
belugas - 17 years ago 2007-10-15 18:36:20
belugas@openttd.org
(svn r11268) -Fix[FS#1336]: Call IsSlopeRefused whenever it is required. Looks like there was one spot missing. Thanks frosch
1 file changed with 1 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/industry_cmd.cpp
Show inline comments
 
@@ -1182,12 +1182,13 @@ static const Town *CheckMultipleIndustry
 

	
 
	return t;
 
}
 

	
 
bool IsSlopeRefused(Slope current, Slope refused)
 
{
 
	if (IsSteepSlope(current)) return true;
 
	if (current != SLOPE_FLAT) {
 
		if (refused & SLOPE_STEEP) return true;
 

	
 
		Slope t = ComplementSlope(current);
 

	
 
		if (refused & 1 && (t & SLOPE_NW)) return false;
 
@@ -1239,13 +1240,12 @@ static bool CheckIfIndustryTilesAreFree(
 
				} else {
 
					Slope tileh;
 

	
 
					if (IsClearWaterTile(cur_tile)) return false;
 

	
 
					tileh = GetTileSlope(cur_tile, NULL);
 
					if (IsSteepSlope(tileh)) return false;
 

	
 
					refused_slope |= IsSlopeRefused(tileh, its->slopes_refused);
 
				}
 
			}
 

	
 
			if (ind_behav & INDUSTRYBEH_ONLY_INTOWN) {
0 comments (0 inline, 0 general)