src/industry_cmd.cpp
changeset 7203 39f68ddb39cc
parent 7199 e65a28455ee3
child 7205 0a6d45455ae5
--- a/src/industry_cmd.cpp	Sun Jul 08 18:40:15 2007 +0000
+++ b/src/industry_cmd.cpp	Sun Jul 08 18:41:34 2007 +0000
@@ -1549,7 +1549,14 @@
 			if (Random() <= indspec->prospecting_chance) {
 				for (int i = 0; i < 5000; i++) {
 					const IndustryTileTable *it = indspec->table[RandomRange(indspec->num_table)];
-					if (CreateNewIndustryHelper(RandomTile(), p1, flags, indspec, it) != NULL) break;
+					const Industry *ind = CreateNewIndustryHelper(RandomTile(), p1, flags, indspec, it);
+					if (ind != NULL) {
+						SetDParam(0, indspec->name);
+						SetDParam(1, ind->town->index);
+						AddNewsItem(indspec->new_industry_text,
+								NEWS_FLAGS(NM_THIN, NF_VIEWPORT | NF_TILE, NT_OPENCLOSE, 0), ind->xy, 0);
+						break;
+					}
 				}
 			}
 		}