1
0
Fork 0

Codechange: remove magic number

pull/12712/head
Susan 2024-05-25 23:07:43 +01:00 committed by Susan
parent 23f8519624
commit 573b55cf9f
1 changed files with 2 additions and 1 deletions

View File

@ -57,6 +57,7 @@ uint8_t _trees_tick_ctr;
static const uint16_t DEFAULT_TREE_STEPS = 1000; ///< Default number of attempts for placing trees.
static const uint16_t DEFAULT_RAINFOREST_TREE_STEPS = 15000; ///< Default number of attempts for placing extra trees at rainforest in tropic.
static const uint16_t EDITOR_TREE_DIV = 5; ///< Game editor tree generation divisor factor.
static const uint16_t FOREST_THRESHOLD = 6; ///< Minimum amount of trees required to be considered a forest.
/**
* Tests if a tile can be converted to MP_TREES
@ -105,7 +106,7 @@ static bool IsNearbyForest(TileIndex tile)
}
}
return (planted_tile_count >= 6);
return (planted_tile_count >= FOREST_THRESHOLD);
}
/**