summaryrefslogtreecommitdiffhomepage
path: root/main/main.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-10-06 09:35:48 +0200
committerStanislaw Halik <sthalik@misaki.pl>2022-10-06 09:35:53 +0200
commit595c113b88dc1e81802b4b1381122f25c0eece74 (patch)
treef91d46b9f50c79a9f12b89923937a5f49bbc9bf3 /main/main.cpp
parent9575f4b78d17ef14f5908708cc4b8b047de70a7d (diff)
a
Diffstat (limited to 'main/main.cpp')
-rw-r--r--main/main.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/main/main.cpp b/main/main.cpp
index 4acdd471..9dc5ce4e 100644
--- a/main/main.cpp
+++ b/main/main.cpp
@@ -75,7 +75,7 @@ chunk app::make_test_chunk()
chunk c;
c.foreach_tile([&, this](tile& x, std::size_t k, local_coords pt) {
const auto& atlas = pt.x > N/2 && pt.y >= N/2 ? floor2 : floor1;
- x.ground_image = { atlas, (std::uint8_t)(k % atlas->size()) };
+ x.ground_image = { atlas, (std::uint8_t)(k % atlas->num_tiles().product()) };
});
constexpr auto K = N/2;
c[{K, K }].wall_north = { wall1, 0 };