(svn r9870) -Codechange: Silence two compiler warnings and give proper type to the "type" member of industry struct

This commit is contained in:
belugas
2007-05-18 17:55:07 +00:00
parent ba24c34f85
commit 49570edfe9
3 changed files with 6 additions and 5 deletions

View File

@@ -63,8 +63,8 @@ IndustryType GetIndustryType(TileIndex tile)
{
assert(IsTileType(tile, MP_INDUSTRY));
const Industry *ind = GetIndustry(GetIndustryIndex(tile));
return IsValidIndustry(ind) ? ind->type : IT_INVALID;
const Industry *ind = GetIndustryByTile(tile);
return IsValidIndustry(ind) ? ind->type : (IndustryType)IT_INVALID;
}
/**