Changeset - r2072:93fbc12acd5b
[Not reviewed]
master
0 1 0
ludde - 19 years ago 2005-07-15 19:51:54
ludde@openttd.org
(svn r2582) Fix: Prevent generating unrealistically many Oil refineries on large maps. They are always placed next to the borderline, so the perimeter is used instead of area to scale the number of those industries.
1 file changed with 8 insertions and 2 deletions:
0 comments (0 inline, 0 general)
industry_cmd.c
Show inline comments
 
@@ -1647,8 +1647,14 @@ static const byte _numof_industry_table[
 

	
 
static void PlaceInitialIndustry(byte type, int amount)
 
{
 
	int num =
 
		ScaleByMapSize(_numof_industry_table[_opt.diff.number_industries][amount]);
 
	int num = _numof_industry_table[_opt.diff.number_industries][amount];
 

	
 
	if (type == IT_OIL_REFINERY || type == IT_OIL_RIG) {
 
		// These are always placed next to the coastline, so we scale by the perimeter instead.
 
		num = ScaleByMapSize1D(num);
 
	} else {
 
		num = ScaleByMapSize(num);
 
	}
 

	
 
	if (_opt.diff.number_industries != 0)
 
	{
0 comments (0 inline, 0 general)