Class UserDataServiceExtensions
public static class UserDataServiceExtensions
- Inheritance
-
UserDataServiceExtensions
- Inherited Members
Methods
GetUsernamesAsync(IUserDataService, IEnumerable<ulong>, CancellationToken)
Get multiple players' stored username data in bulk. Not necessarily returned in the same order as it was inputted.
public static Task<PlayerNames[]> GetUsernamesAsync(this IUserDataService dataService, IEnumerable<ulong> steamIds, CancellationToken token = default)
Parameters
dataServiceIUserDataServicesteamIdsIEnumerable<ulong>tokenCancellationToken
Returns
- Task<PlayerNames[]>
SearchPlayersAsync(IUserDataService, string, PlayerNameType, bool, int, CancellationToken)
Search all players that have ever joined by their usernames, and add them to a collection as they're found.
public static Task<List<PlayerNames>> SearchPlayersAsync(this IUserDataService dataService, string input, PlayerNameType prioritizedName, bool byLastJoined, int limit = -1, CancellationToken token = default)
Parameters
dataServiceIUserDataServiceinputstringprioritizedNamePlayerNameTypeThe type of name to prioritize.
byLastJoinedboolIf they should be ordered by the last time they joined. Exact matches will still be prioritized.
limitinttokenCancellationToken
Returns
- Task<List<PlayerNames>>
All matches in order of relevance.