GOG GALAXY SDK Documentation
IUserStatsAndAchievementsRetrieveListener Class Referenceabstract

Listener for the event of retrieving statistics and achievements of a specified user, possibly our own. More...

#include <IStats.h>

Inheritance diagram for IUserStatsAndAchievementsRetrieveListener:
[legend]

Public Types

enum  FailureReason { FAILURE_REASON_UNDEFINED , FAILURE_REASON_CONNECTION_FAILURE }
 The reason of a failure in retrieving statistics and achievements. More...
 

Public Member Functions

virtual void OnUserStatsAndAchievementsRetrieveSuccess (GalaxyID userID)=0
 Notification for the event of success in retrieving statistics and achievements for a specified user. More...
 
virtual void OnUserStatsAndAchievementsRetrieveFailure (GalaxyID userID, FailureReason failureReason)=0
 Notification for the event of a failure in retrieving statistics and achievements for a specified user. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from GalaxyTypeAwareListener< USER_STATS_AND_ACHIEVEMENTS_RETRIEVE >
static ListenerType GetListenerType ()
 Returns the type of the listener. More...
 

Detailed Description

Listener for the event of retrieving statistics and achievements of a specified user, possibly our own.

Member Enumeration Documentation

◆ FailureReason

The reason of a failure in retrieving statistics and achievements.

Enumerator
FAILURE_REASON_UNDEFINED 

Unspecified error.

FAILURE_REASON_CONNECTION_FAILURE 

Unable to communicate with backend services.

Member Function Documentation

◆ OnUserStatsAndAchievementsRetrieveFailure()

virtual void OnUserStatsAndAchievementsRetrieveFailure ( GalaxyID  userID,
FailureReason  failureReason 
)
pure virtual

Notification for the event of a failure in retrieving statistics and achievements for a specified user.

Parameters
[in]userIDThe ID of the user.
[in]failureReasonThe cause of the failure.

◆ OnUserStatsAndAchievementsRetrieveSuccess()

virtual void OnUserStatsAndAchievementsRetrieveSuccess ( GalaxyID  userID)
pure virtual

Notification for the event of success in retrieving statistics and achievements for a specified user.

To read statistics call IStats::GetStatInt() or IStats::GetStatFloat(), depending on the type of the statistic to read.

To read achievements call IStats::GetAchievement().

Parameters
[in]userIDThe ID of the user.