Merge pull request #310 from laurirasanen/master

Add SteamFriends.GetFromSource
This commit is contained in:
Garry Newman 2019-09-19 14:41:12 +01:00 committed by GitHub
commit 06169693d0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -136,6 +136,14 @@ public static IEnumerable<Friend> GetPlayedWith()
}
}
public static IEnumerable<Friend> GetFromSource( SteamId steamid )
{
for ( int i = 0; i < Internal.GetFriendCountFromSource( steamid ); i++ )
{
yield return new Friend( Internal.GetFriendFromSourceByIndex( steamid, i ) );
}
}
/// <summary>
/// The dialog to open. Valid options are:
/// "friends",