diff options
author | frosch <frosch@openttd.org> | 2012-05-26 14:15:57 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2012-05-26 14:15:57 +0000 |
commit | a0be398da9f80ac316b2d8959ddf96345414dde2 (patch) | |
tree | 3c1e5780cc1f3c1209a5e7f0de71934fa088f47a /src/news_func.h | |
parent | 00b3ff80bbc76bc5546239cfcfa9a4c3591404a1 (diff) | |
download | openttd-a0be398da9f80ac316b2d8959ddf96345414dde2.tar.xz |
(svn r24283) -Codechange: Add AddTileNewsItem function to preemptively deduplicate code.
Diffstat (limited to 'src/news_func.h')
-rw-r--r-- | src/news_func.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/news_func.h b/src/news_func.h index e28f446a5..239e787b3 100644 --- a/src/news_func.h +++ b/src/news_func.h @@ -44,6 +44,11 @@ static inline void AddVehicleAdviceNewsItem(StringID string, VehicleID vehicle) AddNewsItem(string, NS_ADVICE, NR_VEHICLE, vehicle); } +static inline void AddTileNewsItem(StringID string, NewsSubtype subtype, TileIndex tile, void *free_data = NULL) +{ + AddNewsItem(string, subtype, NR_TILE, tile, NR_NONE, UINT32_MAX, free_data); +} + static inline void AddIndustryNewsItem(StringID string, NewsSubtype subtype, IndustryID industry) { AddNewsItem(string, subtype, NR_INDUSTRY, industry); |