1
0
Fork 0

(svn r1958) GenerateStationName() tidyup.

release/0.4.5
pasky 2005-03-08 00:26:30 +00:00
parent f2e45daf54
commit bcc9dcd210
1 changed files with 23 additions and 23 deletions

View File

@ -362,16 +362,16 @@ static bool GenerateStationName(Station *st, uint tile, int flag)
} }
/* Check lakeside */ /* Check lakeside */
if (HASBIT(free_names, M(STR_SV_STNAME_LAKESIDE)) && if (HASBIT(free_names, M(STR_SV_STNAME_LAKESIDE))
DistanceFromEdge(tile) < 20 && && DistanceFromEdge(tile) < 20
CountMapSquareAround(tile, MP_WATER, 0, 0) >= 5) { && CountMapSquareAround(tile, MP_WATER, 0, 0) >= 5) {
found = M(STR_SV_STNAME_LAKESIDE); found = M(STR_SV_STNAME_LAKESIDE);
goto done; goto done;
} }
/* Check woods */ /* Check woods */
if (HASBIT(free_names, M(STR_SV_STNAME_WOODS)) && ( if (HASBIT(free_names, M(STR_SV_STNAME_WOODS)) &&
CountMapSquareAround(tile, MP_TREES, 0, 255) >= 8 || (CountMapSquareAround(tile, MP_TREES, 0, 255) >= 8 ||
CountMapSquareAround(tile, MP_INDUSTRY, 0x10, 0x11) >= 2)) { CountMapSquareAround(tile, MP_INDUSTRY, 0x10, 0x11) >= 2)) {
found = (_opt.landscape==LT_DESERT) ? M(STR_SV_STNAME_FOREST) : M(STR_SV_STNAME_WOODS); found = (_opt.landscape==LT_DESERT) ? M(STR_SV_STNAME_FOREST) : M(STR_SV_STNAME_WOODS);
goto done; goto done;