(svn r14608) -Fix (r9315): Return the current year as construction year for unfinished houses.
authorfrosch
Sat, 22 Nov 2008 19:49:17 +0000
changeset 10357 b29c33461124
parent 10356 2ec5dcfd8554
child 10358 e18487e907f4
(svn r14608) -Fix (r9315): Return the current year as construction year for unfinished houses.
src/town_map.h
--- a/src/town_map.h	Sat Nov 22 18:44:26 2008 +0000
+++ b/src/town_map.h	Sat Nov 22 19:49:17 2008 +0000
@@ -7,6 +7,7 @@
 
 #include "town.h"
 #include "date_type.h"
+#include "date_func.h"
 #include "tile_map.h"
 
 /**
@@ -285,7 +286,7 @@
 static inline Year GetHouseConstructionYear(TileIndex t)
 {
 	assert(IsTileType(t, MP_HOUSE));
-	return IsHouseCompleted(t) ? _m[t].m5 + GetHouseSpecs(GetHouseType(t))->min_year : 0;
+	return IsHouseCompleted(t) ? _m[t].m5 + GetHouseSpecs(GetHouseType(t))->min_year : _cur_year;
 }
 
 /**