2
0
mirror of https://github.com/Laupetin/OpenAssetTools.git synced 2026-01-25 09:23:03 +00:00

chore: adjust asset name method based on asset to not require constructor

This commit is contained in:
Jan Laupetin
2025-12-18 14:00:59 +00:00
parent 1aa4cd9127
commit 7bf7bf93de
5 changed files with 17 additions and 10 deletions

View File

@@ -15,7 +15,7 @@ protected:
{
static_assert(std::is_base_of_v<IAssetBase, AssetType>);
const auto result = m_visitor.Visit_Dependency(AssetType::EnumEntry, AssetNameAccessor<AssetType>()(*asset));
const auto result = m_visitor.Visit_Dependency(AssetType::EnumEntry, AssetName<AssetType>(*asset));
if (result.has_value())
asset = static_cast<std::add_pointer_t<typename AssetType::Type>>(result->m_ptr);
}