mirror of
https://github.com/Facepunch/Facepunch.Steamworks.git
synced 2025-01-12 14:48:02 +03:00
Added Friends.UpdateInformation( steamid )
This commit is contained in:
parent
01dbec678c
commit
657c04b399
@ -115,11 +115,22 @@ namespace Facepunch.Steamworks
|
|||||||
{
|
{
|
||||||
client = c;
|
client = c;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Try to get information about this user - which as name and avatar.
|
||||||
|
/// If returns true, we already have this user's information.
|
||||||
|
/// </summary>
|
||||||
|
public bool UpdateInformation( ulong steamid )
|
||||||
|
{
|
||||||
|
return !client.native.friends.RequestUserInformation( steamid, false );
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get this user's name
|
||||||
|
/// </summary>
|
||||||
public string GetName( ulong steamid )
|
public string GetName( ulong steamid )
|
||||||
{
|
{
|
||||||
client.native.friends.RequestUserInformation( steamid, true );
|
client.native.friends.RequestUserInformation( steamid, true );
|
||||||
|
|
||||||
return client.native.friends.GetFriendPersonaName( steamid );
|
return client.native.friends.GetFriendPersonaName( steamid );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user