summaryrefslogtreecommitdiffhomepage
path: root/src/scenery.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/scenery.hpp')
-rw-r--r--src/scenery.hpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/scenery.hpp b/src/scenery.hpp
index 4e362070..731b999b 100644
--- a/src/scenery.hpp
+++ b/src/scenery.hpp
@@ -4,16 +4,19 @@
namespace floormat {
-struct anim_atlas;
+enum class rotation : std::uint16_t {
+ N, NE, E, SE, S, SW, W, NW,
+ COUNT,
+};
struct scenery final
{
- enum class rotation : std::uint16_t {
- N, NE, E, SE, S, SW, W, NW,
- };
+ using frame_t = std::uint16_t;
- rotation r : 3 = rotation::N;
- std::uint16_t frame : 13 = 0;
+ frame_t frame : 13 = 0;
+ rotation r : 3 = rotation::N;
};
+static_assert(sizeof(scenery) == sizeof(std::uint16_t));
+
} // namespace floormat