From cc7d22803c50c1df9fc22e3ac91efd428bd5090d Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Thu, 1 Dec 2022 14:35:55 +0100 Subject: tile: remove '_image' stuffix from tile_proto accessors --- src/tile.cpp | 16 ++++++++-------- src/tile.hpp | 8 ++++---- 2 files changed, 12 insertions(+), 12 deletions(-) (limited to 'src') diff --git a/src/tile.cpp b/src/tile.cpp index 56ac5746..b9ed5ab6 100644 --- a/src/tile.cpp +++ b/src/tile.cpp @@ -30,16 +30,16 @@ pass_mode_ref::operator pass_mode() const noexcept } bool operator==(const tile_proto& a, const tile_proto& b) noexcept { - return a.ground_image() == b.ground_image() && - a.wall_north_image() == b.wall_north_image() && - a.wall_west_image() == b.wall_west_image() && - a.scenery_image() == b.scenery_image(); + return a.ground() == b.ground() && + a.wall_north() == b.wall_north() && + a.wall_west() == b.wall_west() && + a.scenery() == b.scenery(); }; -tile_image_proto tile_proto::ground_image() const noexcept { return { ground_atlas, ground_variant }; } -tile_image_proto tile_proto::wall_north_image() const noexcept { return { wall_north_atlas, wall_north_variant }; } -tile_image_proto tile_proto::wall_west_image() const noexcept { return { wall_west_atlas, wall_west_variant }; } -scenery_proto tile_proto::scenery_image() const noexcept { return { scenery_atlas, scenery_frame }; } +tile_image_proto tile_proto::ground() const noexcept { return { ground_atlas, ground_variant }; } +tile_image_proto tile_proto::wall_north() const noexcept { return { wall_north_atlas, wall_north_variant }; } +tile_image_proto tile_proto::wall_west() const noexcept { return { wall_west_atlas, wall_west_variant }; } +scenery_proto tile_proto::scenery() const noexcept { return { scenery_atlas, scenery_frame }; } tile_ref::tile_ref(struct chunk& c, std::uint8_t i) noexcept : _chunk{&c}, i{i} {} diff --git a/src/tile.hpp b/src/tile.hpp index dc635da6..23b50161 100644 --- a/src/tile.hpp +++ b/src/tile.hpp @@ -30,10 +30,10 @@ struct tile_proto final scenery scenery_frame; enum pass_mode pass_mode = pass_mode::pass_shoot_through; - tile_image_proto ground_image() const noexcept; - tile_image_proto wall_north_image() const noexcept; - tile_image_proto wall_west_image() const noexcept; - scenery_proto scenery_image() const noexcept; + tile_image_proto ground() const noexcept; + tile_image_proto wall_north() const noexcept; + tile_image_proto wall_west() const noexcept; + scenery_proto scenery() const noexcept; friend bool operator==(const tile_proto& a, const tile_proto& b) noexcept; }; -- cgit v1.2.3