diff --git a/Navmesher/esx_reader.hpp b/Navmesher/esx_reader.hpp index 245848a..f845dc0 100644 --- a/Navmesher/esx_reader.hpp +++ b/Navmesher/esx_reader.hpp @@ -160,6 +160,13 @@ private: [[nodiscard]] Header read_header(std::istream &in); +// Convert a compatible C string to a FourCC (e.g. "LITR") +static consteval FourCC fourcc_from_cstr(const char(&a)[5]) noexcept +{ + char temp[4] = { a[0], a[1], a[2], a[3] }; + return std::bit_cast(temp); +} + } #endif // ESX_READER_HPP diff --git a/Navmesher/esx_reader_lut.cpp b/Navmesher/esx_reader_lut.cpp index 1b84bdc..60dcd08 100644 --- a/Navmesher/esx_reader_lut.cpp +++ b/Navmesher/esx_reader_lut.cpp @@ -15,13 +15,6 @@ static constexpr std::pair group_type_name_map_buil {GroupType::CellTemporaryChildren , "Cell Temporary Children" }, }; -// Convert a compatible C string to a FourCC (e.g. "LITR") -static consteval FourCC fourcc_from_cstr(const char(&a)[5]) noexcept -{ - char temp[4] = { a[0], a[1], a[2], a[3] }; - return std::bit_cast(temp); -} - static constexpr std::pair record_type_fourcc_map_builtin[] { {RecordType::AACT, fourcc_from_cstr("AACT")}, {RecordType::ACHR, fourcc_from_cstr("ACHR")},