diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2022-10-18 09:53:43 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2022-10-18 09:53:43 +0200 |
commit | 13b1ada087bb1feba5e96f7bfe722dcaeea7071f (patch) | |
tree | 4893eef09c24db39a97d59026c21eae47f6cb5f6 | |
parent | 2c698881d7fc515984d50c5c39239b48718258bc (diff) |
a
-rw-r--r-- | main/update.cpp | 2 | ||||
-rw-r--r-- | src/world.cpp | 1 |
2 files changed, 1 insertions, 2 deletions
diff --git a/main/update.cpp b/main/update.cpp index 9a65e182..4346f7af 100644 --- a/main/update.cpp +++ b/main/update.cpp @@ -6,7 +6,7 @@ void app::make_test_chunk(chunk& c) { constexpr auto N = TILE_MAX_DIM; for (auto [x, k, pt] : c) { - const auto& atlas = pt.x == N/2 || pt.y == N/2 ? floor2 : floor1; + const auto& atlas = pt.x != pt.y && (pt.x == N/2 || pt.y == N/2) ? floor2 : floor1; x.ground_image = { atlas, (std::uint8_t)(k % atlas->num_tiles().product()) }; } constexpr auto K = N/2; diff --git a/src/world.cpp b/src/world.cpp index 8337bfba..4e47f912 100644 --- a/src/world.cpp +++ b/src/world.cpp @@ -30,7 +30,6 @@ std::shared_ptr<chunk> world::operator[](chunk_coords c) noexcept return ret; } - std::tuple<std::shared_ptr<chunk>, tile&> world::operator[](global_coords pt) noexcept { auto c = operator[](pt.chunk()); |