src/industry_cmd.cpp
changeset 6305 185ebf766d4e
parent 6283 f9d97d412b0f
child 6307 a6c8aaaf3195
--- a/src/industry_cmd.cpp	Tue Mar 13 21:31:09 2007 +0000
+++ b/src/industry_cmd.cpp	Wed Mar 14 02:52:50 2007 +0000
@@ -233,7 +233,7 @@
 	ind = GetIndustryByTile(ti->tile);
 
 	/* Retrieve pointer to the draw industry tile struct */
-	dits = &_industry_draw_tile_data[gfx << 2 | (_industry_section_draw_animation_state[gfx] ?
+	dits = &_industry_draw_tile_data[gfx << 2 | (GetIndustryTileSpec(gfx)->anim_state ?
 			GetIndustryAnimationState(ti->tile) & 3 :
 			GetIndustryConstructionStage(ti->tile))];
 
@@ -357,9 +357,9 @@
 		am = MoveGoodsToStation(i->xy, i->width, i->height, i->produced_cargo[0], cw);
 		i->last_mo_transported[0] += am;
 		if (am != 0) {
-			uint newgfx = _industry_produce_section[GetIndustryGfx(tile)];
+			uint newgfx = GetIndustryTileSpec(GetIndustryGfx(tile))->anim_production;
 
-			if (newgfx != 0xFF) {
+			if (newgfx != INDUTILE_NOAMIN) {
 				ResetIndustryConstructionStage(tile);
 				SetIndustryCompleted(tile, true);
 				SetIndustryGfx(tile, newgfx);
@@ -645,8 +645,8 @@
 
 	TransportIndustryGoods(tile);
 
-	newgfx = _industry_section_animation_next[GetIndustryGfx(tile)];
-	if (newgfx != 255) {
+	newgfx = GetIndustryTileSpec(GetIndustryGfx(tile))->anim_next;
+	if (newgfx != INDUTILE_NOAMIN) {
 		ResetIndustryConstructionStage(tile);
 		SetIndustryGfx(tile, newgfx);
 		MarkTileDirtyByTile(tile);