summaryrefslogtreecommitdiffhomepage
path: root/main.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-10-04 18:49:16 +0200
committerStanislaw Halik <sthalik@misaki.pl>2022-10-04 18:49:16 +0200
commitb47d96ccd1ef1f424154511f7294ab969bd4f5ca (patch)
tree4af2aa8311d681d84d9057e47c5fe1bfe80f59f2 /main.cpp
parent3091227ae4eecf837dd2faecf572bbb3a08de9de (diff)
a
Diffstat (limited to 'main.cpp')
-rw-r--r--main.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.cpp b/main.cpp
index 8a23b549..fa312c6d 100644
--- a/main.cpp
+++ b/main.cpp
@@ -79,8 +79,8 @@ chunk app::make_test_chunk()
{
constexpr auto N = TILE_MAX_DIM;
chunk c;
- c.foreach_tile([&, this](tile& x, std::size_t k, local_coords) {
- const auto& atlas = floor1;
+ 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()) };
});
c[{N/2 + 1, N/2}].wall_north = { wall1, 0 };