show * for custom growth speed, show grow counter >= 16000

This commit is contained in:
Pavel Stupnikov
2016-02-24 19:32:27 +03:00
parent 541c95fa9e
commit e7cd523975
2 changed files with 8 additions and 7 deletions

View File

@@ -1326,10 +1326,12 @@ static void DrawExtraTownInfo (const Rect &r, uint &y, Town *town, uint line, bo
else grow_rate = TownTicksToDays((town->growth_rate & ~TOWN_GROW_RATE_CUSTOM) + 1);
SetDParam(0, grow_rate);
SetDParam(1, town->grow_counter < 16000 ? TownTicksToDays(town->grow_counter + 1) : -1);
SetDParam(2, town->time_until_rebuild);
SetDParam(3, HasBit(town->flags, TOWN_IS_GROWING) ? 1 : 0);
SetDParam(4, town->fund_buildings_months);
SetDParam(1, town->growth_rate & TOWN_GROW_RATE_CUSTOM ? STR_TOWN_VIEW_GROWTH_RATE_CUSTOM : STR_EMPTY);
// SetDParam(2, town->grow_counter < 16000 ? TownTicksToDays(town->grow_counter + 1) : -1);
SetDParam(2, TownTicksToDays(town->grow_counter + 1));
SetDParam(3, town->time_until_rebuild);
SetDParam(4, HasBit(town->flags, TOWN_IS_GROWING) ? 1 : 0);
SetDParam(5, town->fund_buildings_months);
DrawString(r.left + WD_FRAMERECT_LEFT, r.right - WD_FRAMERECT_LEFT, y += line, STR_TOWN_VIEW_GROWTH);
if (show_house_states_info) {
@@ -1693,5 +1695,3 @@ static WindowDesc _cb_town_desc(
void ShowCBTownWindow(uint town) {
AllocateWindowDescFront<CBTownWindow>(&_cb_town_desc, town);
}