File diff r12278:a95eb3806753 → r12279:1653fc3a5444
src/subsidy.cpp
Show inline comments
 
@@ -281,13 +281,13 @@ void SubsidyMonthlyLoop()
 
	}
 
no_add:;
 
	if (modified)
 
		InvalidateWindow(WC_SUBSIDIES_LIST, 0);
 
}
 

	
 
bool CheckSubsidised(const Station *from, const Station *to, CargoID cargo_type)
 
bool CheckSubsidised(const Station *from, const Station *to, CargoID cargo_type, CompanyID company)
 
{
 
	Subsidy *s;
 
	TileIndex xy;
 

	
 
	/* check if there is an already existing subsidy that applies to us */
 
	for (s = _subsidies; s != endof(_subsidies); s++) {
 
@@ -333,13 +333,13 @@ bool CheckSubsidised(const Station *from
 

	
 
			/* Add a news item */
 
			Pair reftype = SetupSubsidyDecodeParam(s, 0);
 
			InjectDParam(1);
 

	
 
			char *company_name = MallocT<char>(MAX_LENGTH_COMPANY_NAME_BYTES);
 
			SetDParam(0, _current_company);
 
			SetDParam(0, company);
 
			GetString(company_name, STR_COMPANY_NAME, company_name + MAX_LENGTH_COMPANY_NAME_BYTES - 1);
 

	
 
			SetDParamStr(0, company_name);
 
			AddNewsItem(
 
				STR_NEWS_SERVICE_SUBSIDY_AWARDED_HALF + _settings_game.difficulty.subsidy_multiplier,
 
				NS_SUBSIDIES,