diff options
| author | Stanislaw Halik <sthalik@misaki.pl> | 2023-09-27 07:49:37 +0200 |
|---|---|---|
| committer | Stanislaw Halik <sthalik@misaki.pl> | 2023-09-27 07:49:37 +0200 |
| commit | 39a87e2281176a57a2d9b00b6deeb0c46c702397 (patch) | |
| tree | 7208a8a8541ca53113db4bdc6b2f50379a331c68 /src | |
| parent | c2869b8f9d851b31ee215c73e4170fa42f37df1c (diff) | |
a
Diffstat (limited to 'src')
| -rw-r--r-- | src/path-search.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/path-search.cpp b/src/path-search.cpp index 0ec4a91d..bab6b094 100644 --- a/src/path-search.cpp +++ b/src/path-search.cpp @@ -243,8 +243,7 @@ void path_search::fill_cache_(world& w, chunk_coords_ coord, Vector2ub own_size, int8_t z = coord.z; auto off = Vector2i(x - cache.start.x(), y - cache.start.y()); - fm_debug_assert(off.x() >= 0 && off.y() >= 0); - fm_debug_assert(off.x() < cache.size.x() && off.y() < cache.size.y()); + fm_debug_assert(off >= Vector2i{} && off < cache.size); auto ch = chunk_coords_{(int16_t)x, (int16_t)y, z}; auto* c = w.at(ch); auto nb = w.neighbors(ch); |
