From c9360ffe04725abf6e4f1b97d67731981508749f Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Thu, 11 Jan 2024 04:03:08 +0100 Subject: fix msvc build --- src/chunk-walls.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/chunk-walls.cpp b/src/chunk-walls.cpp index 59042a11..6918248c 100644 --- a/src/chunk-walls.cpp +++ b/src/chunk-walls.cpp @@ -308,7 +308,11 @@ GL::Mesh chunk::make_wall_mesh() ranges::sort(ranges::zip_view(vertexes.prefix(N), ArrayView{_walls->mesh_indexes.data(), N}), - [&A = _walls->atlases](const auto& a, const auto& b) { return A[a.second] < A[b.second]; }); + [&A = _walls->atlases](const auto& a, const auto& b) { + const auto& [av, ai] = a; + const auto& [bv, bi] = b; + return A[ai] < A[bi]; + }); auto vertex_view = std::as_const(vertexes).prefix(N); auto index_view = make_indexes(N); -- cgit v1.2.3