Edit

Share via


AchievementService.UpdateAchievementAsync Method

Definition

Overloads

UpdateAchievementAsync(String, String, UInt32)

Allow achievement progress to be updated and achievements to be unlocked. This API will work even when offline. On PC and Xbox One, updates will be posted by the system when connection is re-established even if the title isn't running.

UpdateAchievementAsync(String, UInt32, String, String, UInt32)

Allow achievement progress to be updated and achievements to be unlocked. This API will work even when offline. On PC and Xbox One, updates will be posted by the system when connection is re-established even if the title isn't running.

UpdateAchievementAsync(String, String, UInt32)

Allow achievement progress to be updated and achievements to be unlocked. This API will work even when offline. On PC and Xbox One, updates will be posted by the system when connection is re-established even if the title isn't running.

[Windows.Foundation.Metadata.Overload("UpdateAchievementAsync2")]
public Windows.Foundation.IAsyncAction UpdateAchievementAsync (string xboxUserId, string achievementId, uint percentComplete);
abstract member UpdateAchievementAsync : string * string * uint32 -> Windows.Foundation.IAsyncAction
override this.UpdateAchievementAsync : string * string * uint32 -> Windows.Foundation.IAsyncAction
Public Function UpdateAchievementAsync (xboxUserId As String, achievementId As String, percentComplete As UInteger) As IAsyncAction

Parameters

xboxUserId
String

The Xbox User ID of the player.

achievementId
String

The achievement ID as defined by XDP or Dev Center.

percentComplete
UInt32

The completion percentage of the achievement to indicate progress. Valid values are from 1 to 100. Set to 100 to unlock the achievement. Progress will be set by the server to the highest value sent

Returns

Windows.Foundation.IAsyncAction

Implements

Microsoft.Xbox.Services.Achievements.__IAchievementServicePublicNonVirtuals.UpdateAchievementAsync(System.String,System.String,System.UInt32)
Attributes
Windows.Foundation.Metadata.OverloadAttribute

Remarks

Returns a task<T> object that represents the state of the asynchronous operation.

This method calls V2 POST /users/xuid({xuid})/achievements/{scid}/update

Applies to

UpdateAchievementAsync(String, UInt32, String, String, UInt32)

Allow achievement progress to be updated and achievements to be unlocked. This API will work even when offline. On PC and Xbox One, updates will be posted by the system when connection is re-established even if the title isn't running.

[Windows.Foundation.Metadata.Overload("UpdateAchievementAsync1")]
public Windows.Foundation.IAsyncAction UpdateAchievementAsync (string xboxUserId, uint titleId, string serviceConfigurationId, string achievementId, uint percentComplete);
abstract member UpdateAchievementAsync : string * uint32 * string * string * uint32 -> Windows.Foundation.IAsyncAction
override this.UpdateAchievementAsync : string * uint32 * string * string * uint32 -> Windows.Foundation.IAsyncAction
Public Function UpdateAchievementAsync (xboxUserId As String, titleId As UInteger, serviceConfigurationId As String, achievementId As String, percentComplete As UInteger) As IAsyncAction

Parameters

xboxUserId
String

The Xbox User ID of the player.

titleId
UInt32

The title ID.

serviceConfigurationId
String

The service configuration ID (SCID) for the title.

achievementId
String

The achievement ID as defined by XDP or Dev Center.

percentComplete
UInt32

The completion percentage of the achievement to indicate progress. Valid values are from 1 to 100. Set to 100 to unlock the achievement. Progress will be set by the server to the highest value sent

Returns

Windows.Foundation.IAsyncAction

Implements

Microsoft.Xbox.Services.Achievements.__IAchievementServicePublicNonVirtuals.UpdateAchievementAsync(System.String,System.UInt32,System.String,System.String,System.UInt32)
Attributes
Windows.Foundation.Metadata.OverloadAttribute

Remarks

Returns a task<T> object that represents the state of the asynchronous operation.

This method calls V2 POST /users/xuid({xuid})/achievements/{scid}/update

Applies to