mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-12 18:40:29 +00:00
Codechange: Don't use a magic number for the number of DiagDirections
This commit is contained in:
parent
2dad9263d7
commit
4181d3c1ff
@ -249,7 +249,7 @@ static TownDrawTileProc * const _town_draw_tile_procs[1] = {
|
||||
*/
|
||||
static inline DiagDirection RandomDiagDir()
|
||||
{
|
||||
return (DiagDirection)(3 & Random());
|
||||
return (DiagDirection)(RandomRange(DIAGDIR_END));
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user