diff options
author | glx22 <glx@openttd.org> | 2021-05-12 16:45:28 +0200 |
---|---|---|
committer | Loïc Guilloux <glx22@users.noreply.github.com> | 2021-05-13 00:13:54 +0200 |
commit | 38c97e14926f4bc538c20b24f8a3decdef1668f9 (patch) | |
tree | 2138fa9979f463c5b946653c23313fbb977be652 /src/script/api/script_industry.cpp | |
parent | 5bd81448539b63519d70ba85d4833e446f0597fe (diff) | |
download | openttd-38c97e14926f4bc538c20b24f8a3decdef1668f9.tar.xz |
Codechange: Replace TILE_AREA_LOOP with range-based for loops
Diffstat (limited to 'src/script/api/script_industry.cpp')
-rw-r--r-- | src/script/api/script_industry.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/script/api/script_industry.cpp b/src/script/api/script_industry.cpp index 0a5ca98d3..6f54fda14 100644 --- a/src/script/api/script_industry.cpp +++ b/src/script/api/script_industry.cpp @@ -186,7 +186,7 @@ if (!HasHeliport(industry_id)) return INVALID_TILE; const Industry *ind = ::Industry::Get(industry_id); - TILE_AREA_LOOP(tile_cur, ind->location) { + for (TileIndex tile_cur : ind->location) { if (IsTileType(tile_cur, MP_STATION) && IsOilRig(tile_cur)) { return tile_cur; } @@ -208,7 +208,7 @@ if (!HasDock(industry_id)) return INVALID_TILE; const Industry *ind = ::Industry::Get(industry_id); - TILE_AREA_LOOP(tile_cur, ind->location) { + for (TileIndex tile_cur : ind->location) { if (IsTileType(tile_cur, MP_STATION) && IsOilRig(tile_cur)) { return tile_cur; } |