summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbelugas <belugas@openttd.org>2007-05-30 02:08:18 +0000
committerbelugas <belugas@openttd.org>2007-05-30 02:08:18 +0000
commitc3f8c581576dacfed6420390711a6dddb35cad8e (patch)
treea711c93d07a7369596405f41e1ddda86c87af7bd
parent0a3ebbbc224b0f8af0b8ee89db8a80fe68bee5d4 (diff)
downloadopenttd-c3f8c581576dacfed6420390711a6dddb35cad8e.tar.xz
(svn r9984) -Codechange: Remove an obsolete structure and a now meaningless enum, in favor of the "real thing"
-rw-r--r--src/industry_cmd.cpp4
-rw-r--r--src/industry_map.h7
-rw-r--r--src/table/industry_land.h2
3 files changed, 3 insertions, 10 deletions
diff --git a/src/industry_cmd.cpp b/src/industry_cmd.cpp
index 2cf72a1fd..5077f4b96 100644
--- a/src/industry_cmd.cpp
+++ b/src/industry_cmd.cpp
@@ -108,12 +108,12 @@ const IndustrySpec *GetIndustrySpec(IndustryType thistype)
* This will ensure at once : proper access and
* not allowing modifications of it.
* @param gfx of industrytile (which is the index in _industry_specs)
- * @pre gfx < NUM_INDUSTRY_GFXES
+ * @pre gfx < INVALID_INDUSTRYTILE
* @return a pointer to the corresponding industrytile spec
**/
const IndustryTileSpec *GetIndustryTileSpec(IndustryGfx gfx)
{
- assert(gfx < NUM_INDUSTRY_GFXES);
+ assert(gfx < INVALID_INDUSTRYTILE);
return &_industry_tile_specs[gfx];
}
diff --git a/src/industry_map.h b/src/industry_map.h
index dd3cf1b11..86a62bdbf 100644
--- a/src/industry_map.h
+++ b/src/industry_map.h
@@ -48,7 +48,6 @@ enum {
GFX_BUBBLE_CATCHER = 162,
GFX_TOFFEE_QUARY = 165,
GFX_SUGAR_MINE_SIEVE = 174,
- NUM_INDUSTRY_GFXES = 175,
};
/**
@@ -201,12 +200,6 @@ static inline void ResetIndustryConstructionStage(TileIndex tile)
_m[tile].m1 = 0;
}
-/** Structure used to make a mapping from industry gfx to industry type */
-struct IndustryTypeSolver {
- IndustryGfx MinGfx; ///< The first gfx index for the industry type
- IndustryGfx MaxGfx; ///< The last gfx index for the industry type
-};
-
/**
* Get the animation loop number
* @param tile the tile to get the animation loop number of
diff --git a/src/table/industry_land.h b/src/table/industry_land.h
index 61ce5e0d8..cbab09c43 100644
--- a/src/table/industry_land.h
+++ b/src/table/industry_land.h
@@ -42,7 +42,7 @@ struct DrawIndustryCoordinates {
#define M(s1, p1, s2, p2, sx, sy, w, h, dz, p) { { s1, p1 }, { s2, p2 }, sx, sy, w - 1, h - 1, dz, p }
/** Structure for industry tiles drawing */
-static const DrawBuildingsTileStruct _industry_draw_tile_data[NUM_INDUSTRY_GFXES * 4] = {
+static const DrawBuildingsTileStruct _industry_draw_tile_data[NEW_INDUSTRYTILEOFFSET * 4] = {
M( 0xf54, PAL_NONE, 0x7db, PAL_NONE, 7, 0, 9, 9, 10, 0),
M( 0xf54, PAL_NONE, 0x7dc, PAL_NONE, 7, 0, 9, 9, 30, 0),
M( 0xf54, PAL_NONE, 0x7dd, PAL_NONE, 7, 0, 9, 9, 30, 0),