summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpeter1138 <peter1138@openttd.org>2006-03-31 10:44:32 +0000
committerpeter1138 <peter1138@openttd.org>2006-03-31 10:44:32 +0000
commit43c86cf33f0dddaebf9487f6ed2faffad15f884f (patch)
treed6961a405c589663ee22688a65815e4e837a8b75
parenta6e1a1d3721750cfd20470190f49a338ba6e890c (diff)
downloadopenttd-43c86cf33f0dddaebf9487f6ed2faffad15f884f.tar.xz
(svn r4199) - Codechange: Use industry map accessors to get industry graphics type.
-rw-r--r--smallmap_gui.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/smallmap_gui.c b/smallmap_gui.c
index 181ab2ee3..4b6636dfe 100644
--- a/smallmap_gui.c
+++ b/smallmap_gui.c
@@ -4,6 +4,7 @@
#include "openttd.h"
#include "bridge_map.h"
#include "clear_map.h"
+#include "industry_map.h"
#include "functions.h"
#include "spritecache.h"
#include "station_map.h"
@@ -427,7 +428,7 @@ static inline uint32 GetSmallMapIndustriesPixels(TileIndex tile)
TileType t = GetEffectiveTileType(tile);
if (t == MP_INDUSTRY) {
- byte color = _industry_smallmap_colors[_m[tile].m5];
+ byte color = _industry_smallmap_colors[GetIndustryGfx(tile)];
return color + (color << 8) + (color << 16) + (color << 24);
}
@@ -489,7 +490,7 @@ static inline uint32 GetSmallMapVegetationPixels(TileIndex tile)
break;
case MP_INDUSTRY:
- bits = IS_BYTE_INSIDE(_m[tile].m5, 0x10, 0x12) ? MKCOLOR(0xD0D0D0D0) : MKCOLOR(0xB5B5B5B5);
+ bits = IS_BYTE_INSIDE(GetIndustryGfx(tile), 0x10, 0x12) ? MKCOLOR(0xD0D0D0D0) : MKCOLOR(0xB5B5B5B5);
break;
case MP_TREES: