Bug #2298 » 0080-fair_map_island_new-Fix-set-but-unused-warning-on-nd.patch
| server/generator/mapgen.c | ||
|---|---|---|
|
struct fair_tile *pend;
|
||
|
int n = ((river_pct * size * MAP_NUM_CARDINAL_DIRS
|
||
|
* MAP_NUM_CARDINAL_DIRS) / 200);
|
||
|
int length_max = 3, length, l;
|
||
|
int length_max = 3, l;
|
||
|
enum direction8 dir;
|
||
|
int extra_idx;
|
||
|
int dirs_num;
|
||
| ... | ... | |
|
/* Check a river in one direction. */
|
||
|
pend = nullptr;
|
||
|
length = -1;
|
||
|
#if !defined(FREECIV_NDEBUG) || defined(FREECIV_DEBUG)
|
||
|
int length = -1;
|
||
|
#endif
|
||
|
dir = direction8_invalid();
|
||
|
dirs_num = 0;
|
||
|
for (j = 0; j < MAP_NUM_VALID_DIRS; j++) {
|
||
| ... | ... | |
|
if (finished && fc_rand(++dirs_num) == 0) {
|
||
|
dir = MAP_VALID_DIRS[j];
|
||
|
pend = pftile2;
|
||
|
#if !defined(FREECIV_NDEBUG) || defined(FREECIV_DEBUG)
|
||
|
length = l;
|
||
|
#endif
|
||
|
}
|
||
|
}
|
||
|
if (pend == nullptr) {
|
||
| ... | ... | |
|
length);
|
||
|
for (;;) {
|
||
|
BV_SET(pftile->extras, extra_idx);
|
||
|
#if !defined(FREECIV_NDEBUG) || defined(FREECIV_DEBUG)
|
||
|
length--;
|
||
|
#endif
|
||
|
if (pftile == pend) {
|
||
|
fc_assert(length == 0);
|
||
|
break;
|
||