Create new leaderboards with attribute 'Descending'

This commit is contained in:
Linus Probert 2019-02-20 20:18:52 +01:00
parent 2775780d5b
commit d1efa8450d
2 changed files with 5 additions and 2 deletions

View File

@ -443,6 +443,8 @@ static void
startArcadeGame(void *unused)
{
arcadeGame = true;
quickGame = false;
weeklyGame = false;
goToCharacterMenu(unused);
}
@ -1052,7 +1054,8 @@ register_scores(void)
(int32_t*) &details, 1);
}
if (weeklyGame) {
steam_register_weekly_score((int) gPlayer->gold, (int32_t*) &details, 1);
steam_register_weekly_score((int) gPlayer->gold,
(int32_t*) &details, 1);
}
if (arcadeGame) {
steam_register_arcade_score((int)gPlayer->gold,

View File

@ -127,7 +127,7 @@ c_SteamUserStats_FindOrCreateLeaderboard(const char *name)
if (!m_Initiated || !m_CallbackHandler)
return;
SteamAPICall_t hSteamAPICall = SteamUserStats()->FindOrCreateLeaderboard(name, k_ELeaderboardSortMethodAscending, k_ELeaderboardDisplayTypeNumeric);
SteamAPICall_t hSteamAPICall = SteamUserStats()->FindOrCreateLeaderboard(name, k_ELeaderboardSortMethodDescending, k_ELeaderboardDisplayTypeNumeric);
m_CallbackHandler->m_FindLeaderboardCallResult.Set(hSteamAPICall, m_CallbackHandler, &CallbackHandler::OnFindLeaderboard);
}