mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2025-01-24 20:48:03 +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 )
|
||||
{
|
||||
Console.WriteLine( $"{a.Value}" );
|
||||
Console.WriteLine( $"{a.Identifier}" );
|
||||
Console.WriteLine( $" a.State: {a.State}" );
|
||||
Console.WriteLine( $" a.UnlockTime: {a.UnlockTime}" );
|
||||
Console.WriteLine( $" a.Name: {a.Name}" );
|
||||
Console.WriteLine( $" a.Description: {a.Description}" );
|
||||
Console.WriteLine( $" a.GlobalUnlockedPercentage: {a.GlobalUnlockedPercentage}" );
|
||||
|
||||
var icon = a.GetIcon();
|
||||
|
@ -8,7 +8,7 @@ namespace Steamworks.Data
|
||||
{
|
||||
public struct Achievement
|
||||
{
|
||||
public string Value;
|
||||
internal string Value;
|
||||
|
||||
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>
|
||||
/// Should hold the unlock time if State is true
|
||||
|
Loading…
x
Reference in New Issue
Block a user