diff --git a/profiler/src/profiler/TracyAchievements.cpp b/profiler/src/profiler/TracyAchievements.cpp index fe2758ee..b70965b9 100644 --- a/profiler/src/profiler/TracyAchievements.cpp +++ b/profiler/src/profiler/TracyAchievements.cpp @@ -136,6 +136,13 @@ data::AchievementCategory** AchievementsMgr::GetCategories() const return data::AchievementCategories; } +data::AchievementCategory* AchievementsMgr::GetCategoryForAchievement( const char* id ) const +{ + auto it = m_map.find( id ); + assert( it != m_map.end() ); + return it->second.category; +} + data::AchievementItem* AchievementsMgr::GetNextQueue() { if( m_queue.empty() ) return nullptr; diff --git a/profiler/src/profiler/TracyAchievements.hpp b/profiler/src/profiler/TracyAchievements.hpp index fd1102e4..70200188 100644 --- a/profiler/src/profiler/TracyAchievements.hpp +++ b/profiler/src/profiler/TracyAchievements.hpp @@ -61,6 +61,7 @@ public: void Achieve( const char* id ); data::AchievementCategory** GetCategories() const; + data::AchievementCategory* GetCategoryForAchievement( const char* id ) const; data::AchievementItem* GetNextQueue(); void PopQueue();