mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2025-01-26 05:28:07 +03:00
Achievement.Name/Description
This commit is contained in:
parent
7e02ad736d
commit
ebc1336da3
@ -16,9 +16,11 @@ namespace Steamworks
|
|||||||
{
|
{
|
||||||
foreach ( var a in SteamUserStats.Achievements )
|
foreach ( var a in SteamUserStats.Achievements )
|
||||||
{
|
{
|
||||||
Console.WriteLine( $"{a.Value}" );
|
Console.WriteLine( $"{a.Identifier}" );
|
||||||
Console.WriteLine( $" a.State: {a.State}" );
|
Console.WriteLine( $" a.State: {a.State}" );
|
||||||
Console.WriteLine( $" a.UnlockTime: {a.UnlockTime}" );
|
Console.WriteLine( $" a.UnlockTime: {a.UnlockTime}" );
|
||||||
|
Console.WriteLine( $" a.Name: {a.Name}" );
|
||||||
|
Console.WriteLine( $" a.Description: {a.Description}" );
|
||||||
Console.WriteLine( $" a.GlobalUnlockedPercentage: {a.GlobalUnlockedPercentage}" );
|
Console.WriteLine( $" a.GlobalUnlockedPercentage: {a.GlobalUnlockedPercentage}" );
|
||||||
|
|
||||||
var icon = a.GetIcon();
|
var icon = a.GetIcon();
|
||||||
|
@ -8,7 +8,7 @@ namespace Steamworks.Data
|
|||||||
{
|
{
|
||||||
public struct Achievement
|
public struct Achievement
|
||||||
{
|
{
|
||||||
public string Value;
|
internal string Value;
|
||||||
|
|
||||||
public Achievement( string name )
|
public Achievement( string name )
|
||||||
{
|
{
|
||||||
@ -30,6 +30,12 @@ namespace Steamworks.Data
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public string Identifier => Value;
|
||||||
|
|
||||||
|
public string Name => SteamUserStats.Internal.GetAchievementDisplayAttribute( Value, "name" );
|
||||||
|
|
||||||
|
public string Description => SteamUserStats.Internal.GetAchievementDisplayAttribute( Value, "desc" );
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Should hold the unlock time if State is true
|
/// Should hold the unlock time if State is true
|
||||||
|
Loading…
x
Reference in New Issue
Block a user