Skip to content

Commit

Permalink
Remove Leaderboard Fetch when Getting Info
Browse files Browse the repository at this point in the history
The cause of the leaderboard spam was primarily this call where if there was an attempt to get leaderboard info and there wasn't already, there would be a fetch request. This is bad for many reasons: some games have hundreds of boards that will be fetched at startup, if there's simply no data to populate that board, this will just continue to fetch every time the dialog needs to update. To mitigate this, I simply don't load leaderboard information until there are events for that leaderboard - less information for the player, sadly, but heavily cuts down on the number of leaderboard fetches.
  • Loading branch information
LillyJadeKatrin committed Jul 18, 2024
1 parent cc3ff34 commit e7504d0
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions Source/Core/Core/AchievementManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -479,8 +479,6 @@ AchievementManager::GetLeaderboardInfo(AchievementManager::AchievementId leaderb
if (const auto leaderboard_iter = m_leaderboard_map.find(leaderboard_id);
leaderboard_iter != m_leaderboard_map.end())
{
if (leaderboard_iter->second.entries.size() == 0)
FetchBoardInfo(leaderboard_id);
return &leaderboard_iter->second;
}

Expand Down

0 comments on commit e7504d0

Please sign in to comment.