diff options
author | tron <tron@openttd.org> | 2005-11-04 16:12:48 +0000 |
---|---|---|
committer | tron <tron@openttd.org> | 2005-11-04 16:12:48 +0000 |
commit | d42b7649a43d82407a6a2aae4d2fb86b32556831 (patch) | |
tree | 7ad462b13eee9c90e84d78fc40b4dc1fc86cd81a /industry_cmd.c | |
parent | a21762980d70b1639fc4ab7a5cdc6c5d5379b937 (diff) | |
download | openttd-d42b7649a43d82407a6a2aae4d2fb86b32556831.tar.xz |
(svn r3135) Use symbolic names in the tables, which hold the information about accepted goods of industry tiles, instead of magic numbers
Diffstat (limited to 'industry_cmd.c')
-rw-r--r-- | industry_cmd.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/industry_cmd.c b/industry_cmd.c index 66ab18eb1..b0f818984 100644 --- a/industry_cmd.c +++ b/industry_cmd.c @@ -411,16 +411,16 @@ static uint GetSlopeTileh_Industry(const TileInfo* ti) static void GetAcceptedCargo_Industry(TileIndex tile, AcceptedCargo ac) { int m5 = _m[tile].m5; - int a; + CargoID a; a = _industry_map5_accepts_1[m5]; - if (a >= 0) ac[a] = (a == 0) ? 1 : 8; + if (a != CT_INVALID) ac[a] = (a == 0) ? 1 : 8; a = _industry_map5_accepts_2[m5]; - if (a >= 0) ac[a] = 8; + if (a != CT_INVALID) ac[a] = 8; a = _industry_map5_accepts_3[m5]; - if (a >= 0) ac[a] = 8; + if (a != CT_INVALID) ac[a] = 8; } static void GetTileDesc_Industry(TileIndex tile, TileDesc *td) |