Codechange: use the constructor for CompanyNewsItem to fill the data instead of a separate function
This commit is contained in:
@@ -3231,8 +3231,7 @@ static CommandCost TownActionBuyRights(Town *t, DoCommandFlag flags)
|
||||
SetWindowClassesDirty(WC_STATION_VIEW);
|
||||
|
||||
/* Spawn news message */
|
||||
CompanyNewsInformation *cni = new CompanyNewsInformation();
|
||||
cni->FillData(Company::Get(_current_company));
|
||||
CompanyNewsInformation *cni = new CompanyNewsInformation(Company::Get(_current_company));
|
||||
SetDParam(0, STR_NEWS_EXCLUSIVE_RIGHTS_TITLE);
|
||||
SetDParam(1, STR_NEWS_EXCLUSIVE_RIGHTS_DESCRIPTION);
|
||||
SetDParam(2, t->index);
|
||||
|
Reference in New Issue
Block a user