Skip to content

Commit

Permalink
https://docs.microsoft.com/en-us/gaming/playfab/release-notes/#240913
Browse files Browse the repository at this point in the history
  • Loading branch information
PlayFab SDK Team authored and PlayFab SDK Team committed Sep 16, 2024
2 parents 1baed83 + 895ce1d commit ec4f10f
Show file tree
Hide file tree
Showing 27 changed files with 235 additions and 171 deletions.
6 changes: 4 additions & 2 deletions PlayFabSDK/source/PlayFabAdminModels.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4621,7 +4621,8 @@ public enum LoginIdentityProvider
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class LogStatement
Expand Down Expand Up @@ -8161,7 +8162,8 @@ public enum UserOrigination
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class UserOriginationSegmentFilter
Expand Down
3 changes: 2 additions & 1 deletion PlayFabSDK/source/PlayFabAuthenticationModels.cs
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,8 @@ public enum LoginIdentityProvider
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

/// <summary>
Expand Down
6 changes: 4 additions & 2 deletions PlayFabSDK/source/PlayFabClientModels.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4141,7 +4141,8 @@ public enum LoginIdentityProvider
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class LoginResult : PlayFabLoginResultCommon
Expand Down Expand Up @@ -7727,7 +7728,8 @@ public enum UserOrigination
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class UserPrivateAccountInfo
Expand Down
3 changes: 2 additions & 1 deletion PlayFabSDK/source/PlayFabCloudScriptModels.cs
Original file line number Diff line number Diff line change
Expand Up @@ -748,7 +748,8 @@ public enum LoginIdentityProvider
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class LogStatement
Expand Down
27 changes: 27 additions & 0 deletions PlayFabSDK/source/PlayFabProfilesAPI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,33 @@ public static async Task<PlayFabResult<GetTitlePlayersFromProviderIDsResponse>>
return new PlayFabResult<GetTitlePlayersFromProviderIDsResponse> { Result = result, CustomData = customData };
}

/// <summary>
/// Update the display name of the entity
/// </summary>
public static async Task<PlayFabResult<SetDisplayNameResponse>> SetDisplayNameAsync(SetDisplayNameRequest request, object customData = null, Dictionary<string, string> extraHeaders = null)
{
await new PlayFabUtil.SynchronizationContextRemover();

var requestContext = request?.AuthenticationContext ?? PlayFabSettings.staticPlayer;
var requestSettings = PlayFabSettings.staticSettings;
if (requestContext.EntityToken == null) throw new PlayFabException(PlayFabExceptionCode.EntityTokenNotSet, "Must call Client Login or GetEntityToken before calling this method");


var httpResult = await PlayFabHttp.DoPost("/Profile/SetDisplayName", request, "X-EntityToken", requestContext.EntityToken, extraHeaders);
if (httpResult is PlayFabError)
{
var error = (PlayFabError)httpResult;
PlayFabSettings.GlobalErrorHandler?.Invoke(error);
return new PlayFabResult<SetDisplayNameResponse> { Error = error, CustomData = customData };
}

var resultRawJson = (string)httpResult;
var resultData = PluginManager.GetPlugin<ISerializerPlugin>(PluginContract.PlayFab_Serializer).DeserializeObject<PlayFabJsonSuccess<SetDisplayNameResponse>>(resultRawJson);
var result = resultData.data;

return new PlayFabResult<SetDisplayNameResponse> { Result = result, CustomData = customData };
}

/// <summary>
/// Sets the global title access policy
/// </summary>
Expand Down
26 changes: 26 additions & 0 deletions PlayFabSDK/source/PlayFabProfilesInstanceAPI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,32 @@ public async Task<PlayFabResult<GetTitlePlayersFromProviderIDsResponse>> GetTitl
return new PlayFabResult<GetTitlePlayersFromProviderIDsResponse> { Result = result, CustomData = customData };
}

/// <summary>
/// Update the display name of the entity
/// </summary>
public async Task<PlayFabResult<SetDisplayNameResponse>> SetDisplayNameAsync(SetDisplayNameRequest request, object customData = null, Dictionary<string, string> extraHeaders = null)
{
await new PlayFabUtil.SynchronizationContextRemover();

var requestContext = request?.AuthenticationContext ?? authenticationContext;
var requestSettings = apiSettings ?? PlayFabSettings.staticSettings;
if (requestContext.EntityToken == null) throw new PlayFabException(PlayFabExceptionCode.EntityTokenNotSet, "Must call Client Login or GetEntityToken before calling this method");

var httpResult = await PlayFabHttp.DoPost("/Profile/SetDisplayName", request, "X-EntityToken", requestContext.EntityToken, extraHeaders, requestSettings);
if (httpResult is PlayFabError)
{
var error = (PlayFabError)httpResult;
PlayFabSettings.GlobalErrorHandler?.Invoke(error);
return new PlayFabResult<SetDisplayNameResponse> { Error = error, CustomData = customData };
}

var resultRawJson = (string)httpResult;
var resultData = PluginManager.GetPlugin<ISerializerPlugin>(PluginContract.PlayFab_Serializer).DeserializeObject<PlayFabJsonSuccess<SetDisplayNameResponse>>(resultRawJson);
var result = resultData.data;

return new PlayFabResult<SetDisplayNameResponse> { Result = result, CustomData = customData };
}

/// <summary>
/// Sets the global title access policy
/// </summary>
Expand Down
42 changes: 42 additions & 0 deletions PlayFabSDK/source/PlayFabProfilesModels.cs
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,48 @@ public enum OperationTypes
None
}

/// <summary>
/// Given an entity profile, will update its display name to the one passed in if the profile's version is equal to the
/// specified value
/// </summary>
public class SetDisplayNameRequest : PlayFabRequestCommon
{
/// <summary>
/// The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.).
/// </summary>
public Dictionary<string,string> CustomTags ;

/// <summary>
/// The new value to be set on Entity Profile's display name
/// </summary>
public string DisplayName ;

/// <summary>
/// The optional entity to perform this action on. Defaults to the currently logged in entity.
/// </summary>
public EntityKey Entity ;

/// <summary>
/// The expected version of a profile to perform this update on
/// </summary>
public int? ExpectedVersion ;

}

public class SetDisplayNameResponse : PlayFabResultCommon
{
/// <summary>
/// The type of operation that occured on the profile's display name
/// </summary>
public OperationTypes? OperationResult ;

/// <summary>
/// The updated version of the profile after the display name update
/// </summary>
public int? VersionNumber ;

}

/// <summary>
/// This will set the access policy statements on the given entity profile. This is not additive, any existing statements
/// will be replaced with the statements in this request.
Expand Down
27 changes: 0 additions & 27 deletions PlayFabSDK/source/PlayFabProgressionAPI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -358,33 +358,6 @@ public static async Task<PlayFabResult<GetStatisticDefinitionResponse>> GetStati
return new PlayFabResult<GetStatisticDefinitionResponse> { Result = result, CustomData = customData };
}

/// <summary>
/// Get all current statistic definitions information
/// </summary>
public static async Task<PlayFabResult<GetStatisticDefinitionsResponse>> GetStatisticDefinitionsAsync(GetStatisticDefinitionsRequest request, object customData = null, Dictionary<string, string> extraHeaders = null)
{
await new PlayFabUtil.SynchronizationContextRemover();

var requestContext = request?.AuthenticationContext ?? PlayFabSettings.staticPlayer;
var requestSettings = PlayFabSettings.staticSettings;
if (requestContext.EntityToken == null) throw new PlayFabException(PlayFabExceptionCode.EntityTokenNotSet, "Must call Client Login or GetEntityToken before calling this method");


var httpResult = await PlayFabHttp.DoPost("/Statistic/GetStatisticDefinitions", request, "X-EntityToken", requestContext.EntityToken, extraHeaders);
if (httpResult is PlayFabError)
{
var error = (PlayFabError)httpResult;
PlayFabSettings.GlobalErrorHandler?.Invoke(error);
return new PlayFabResult<GetStatisticDefinitionsResponse> { Error = error, CustomData = customData };
}

var resultRawJson = (string)httpResult;
var resultData = PluginManager.GetPlugin<ISerializerPlugin>(PluginContract.PlayFab_Serializer).DeserializeObject<PlayFabJsonSuccess<GetStatisticDefinitionsResponse>>(resultRawJson);
var result = resultData.data;

return new PlayFabResult<GetStatisticDefinitionsResponse> { Result = result, CustomData = customData };
}

/// <summary>
/// Gets statistics for the specified entity.
/// </summary>
Expand Down
26 changes: 0 additions & 26 deletions PlayFabSDK/source/PlayFabProgressionInstanceAPI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -364,32 +364,6 @@ public async Task<PlayFabResult<GetStatisticDefinitionResponse>> GetStatisticDef
return new PlayFabResult<GetStatisticDefinitionResponse> { Result = result, CustomData = customData };
}

/// <summary>
/// Get all current statistic definitions information
/// </summary>
public async Task<PlayFabResult<GetStatisticDefinitionsResponse>> GetStatisticDefinitionsAsync(GetStatisticDefinitionsRequest request, object customData = null, Dictionary<string, string> extraHeaders = null)
{
await new PlayFabUtil.SynchronizationContextRemover();

var requestContext = request?.AuthenticationContext ?? authenticationContext;
var requestSettings = apiSettings ?? PlayFabSettings.staticSettings;
if (requestContext.EntityToken == null) throw new PlayFabException(PlayFabExceptionCode.EntityTokenNotSet, "Must call Client Login or GetEntityToken before calling this method");

var httpResult = await PlayFabHttp.DoPost("/Statistic/GetStatisticDefinitions", request, "X-EntityToken", requestContext.EntityToken, extraHeaders, requestSettings);
if (httpResult is PlayFabError)
{
var error = (PlayFabError)httpResult;
PlayFabSettings.GlobalErrorHandler?.Invoke(error);
return new PlayFabResult<GetStatisticDefinitionsResponse> { Error = error, CustomData = customData };
}

var resultRawJson = (string)httpResult;
var resultData = PluginManager.GetPlugin<ISerializerPlugin>(PluginContract.PlayFab_Serializer).DeserializeObject<PlayFabJsonSuccess<GetStatisticDefinitionsResponse>>(resultRawJson);
var result = resultData.data;

return new PlayFabResult<GetStatisticDefinitionsResponse> { Result = result, CustomData = customData };
}

/// <summary>
/// Gets statistics for the specified entity.
/// </summary>
Expand Down
18 changes: 0 additions & 18 deletions PlayFabSDK/source/PlayFabProgressionModels.cs
Original file line number Diff line number Diff line change
Expand Up @@ -518,24 +518,6 @@ public class GetStatisticDefinitionResponse : PlayFabResultCommon

}

public class GetStatisticDefinitionsRequest : PlayFabRequestCommon
{
/// <summary>
/// The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.).
/// </summary>
public Dictionary<string,string> CustomTags ;

}

public class GetStatisticDefinitionsResponse : PlayFabResultCommon
{
/// <summary>
/// List of statistic definitions for the title.
/// </summary>
public List<StatisticDefinition> StatisticDefinitions ;

}

public class GetStatisticsForEntitiesRequest : PlayFabRequestCommon
{
/// <summary>
Expand Down
4 changes: 2 additions & 2 deletions PlayFabSDK/source/PlayFabSDK.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<FileAlignment>512</FileAlignment>

<PackageId>PlayFabAllSDK</PackageId>
<Version>1.188.240830</Version>
<Version>1.189.240913</Version>
<Title>PlayFab CSharp Sdk</Title>
<Authors>Microsoft</Authors>
<Owners>Microsoft</Owners>
Expand All @@ -21,7 +21,7 @@
<Company>PlayFab</Company>
<Product>PlayFabSDK</Product>
<PackageTags>PlayFab, Baas, Paas, JSON, REST, HTTP, SSL, API, cloud, liveops, game, gamedev, native</PackageTags>
<PackageReleaseNotes>https://docs.microsoft.com/gaming/playfab/release-notes#240830</PackageReleaseNotes>
<PackageReleaseNotes>https://docs.microsoft.com/gaming/playfab/release-notes#240913</PackageReleaseNotes>
<NeutralLanguage>en</NeutralLanguage>
<AssemblyVersion>1</AssemblyVersion>
<FileVersion>1</FileVersion>
Expand Down
6 changes: 4 additions & 2 deletions PlayFabSDK/source/PlayFabServerModels.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4775,7 +4775,8 @@ public enum LoginIdentityProvider
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

/// <summary>
Expand Down Expand Up @@ -7684,7 +7685,8 @@ public enum UserOrigination
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class UserPrivateAccountInfo
Expand Down
6 changes: 3 additions & 3 deletions PlayFabSDK/source/PlayFabSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ namespace PlayFab
{
public class PlayFabSettings
{
public const string SdkVersion = "1.188.240830";
public const string BuildIdentifier = "adobuild_csharpsdk_115";
public const string SdkVersionString = "CSharpSDK-1.188.240830";
public const string SdkVersion = "1.189.240913";
public const string BuildIdentifier = "adobuild_csharpsdk_117";
public const string SdkVersionString = "CSharpSDK-1.189.240913";
/// <summary> This is only for customers running a private cluster. Generally you shouldn't touch this </summary>
public static string DefaultProductionEnvironmentUrl = "playfabapi.com";

Expand Down
6 changes: 3 additions & 3 deletions Plugins/CloudScript/source/PlayFabCloudScriptPlugin.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<FileAlignment>512</FileAlignment>

<PackageId>PlayFabCloudScriptPlugin</PackageId>
<Version>1.188.240830-alpha</Version>
<Version>1.189.240913-alpha</Version>
<Title>PlayFab CSharp CloudScript Plugin</Title>
<Authors>Microsoft</Authors>
<Owners>Microsoft</Owners>
Expand All @@ -21,7 +21,7 @@
<Product>PlayFabCloudScriptPlugin</Product>
<Copyright>Copyright 2024</Copyright>
<PackageTags>PlayFab, Baas, Paas, JSON, REST, HTTP, SSL, API, cloud, liveops, game, gamedev, native</PackageTags>
<PackageReleaseNotes>https://docs.microsoft.com/gaming/playfab/release-notes#240830</PackageReleaseNotes>
<PackageReleaseNotes>https://docs.microsoft.com/gaming/playfab/release-notes#240913</PackageReleaseNotes>
<NeutralLanguage>en</NeutralLanguage>
<AssemblyVersion>1</AssemblyVersion>
<FileVersion>1</FileVersion>
Expand All @@ -45,7 +45,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="PlayFabAllSDK" Version="1.188.240830" />
<PackageReference Include="PlayFabAllSDK" Version="1.189.240913" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -4621,7 +4621,8 @@ public enum LoginIdentityProvider
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class LogStatement
Expand Down Expand Up @@ -8161,7 +8162,8 @@ public enum UserOrigination
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class UserOriginationSegmentFilter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,8 @@ public enum LoginIdentityProvider
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4141,7 +4141,8 @@ public enum LoginIdentityProvider
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class LoginResult : PlayFabLoginResultCommon
Expand Down Expand Up @@ -7727,7 +7728,8 @@ public enum UserOrigination
Apple,
NintendoSwitchAccount,
GooglePlayGames,
XboxMobileStore
XboxMobileStore,
King
}

public class UserPrivateAccountInfo
Expand Down
Loading

0 comments on commit ec4f10f

Please sign in to comment.