Compartilhar via


XblAchievementsManagerGetAchievement

Gets the current local state of an achievement for a local player with a specific achievement ID.

Syntax

HRESULT XblAchievementsManagerGetAchievement(  
         uint64_t xboxUserId,  
         const char* achievementId,  
         XblAchievementsManagerResultHandle* achievementResult  
)  

Parameters

xboxUserId   _In_
Type: uint64_t

The Xbox User ID of the player.

achievementId   _In_
Type: char*

The UTF-8 encoded unique identifier of the Achievement as defined by Dev Center.

achievementResult   _Outptr_result_maybenull_
Type: XblAchievementsManagerResultHandle*

The handle to the result of AchievementsManager API calls. This handle is used by other APIs to get the achievement objects matching the API that was called. The handle must be closed using XblAchievementsManagerResultCloseHandle when the result is no longer needed.

Return value

Type: HRESULT

HRESULT return code for this API operation.

Requirements

Header: achievements_manager_c.h

Library: Microsoft.Xbox.Services.14x.GDK.C.lib

See also

achievements_manager_c