This repository was archived by the owner on Sep 21, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 16
ModIO.ModManager.GetUserAvatar
Jackson Wood edited this page Mar 25, 2019
·
2 revisions
ModManager.GetUserAvatar
public static void GetUserAvatar(int userId, AvatarImageLocator avatarLocator, UserAvatarSize size, Action<Texture2D> onSuccess, Action<WebRequestError> onError);
| Name | Description |
|---|---|
| userId | User identifier for the user avatar |
| avatarLocator | Server data for the user avatar |
| size | Image size of the avatar |
| onSuccess | Action to execute if the request succeeds |
| onError | Action to execute if the request returns an error |
Fetches and caches a User Avatar (if not already cached).
As with all similar ModManager functions, this checks the cache for the user avatar, and if not found, fetches it from the server and stores it in the cache. As such, there is the potential for the data returned by this function to be obsolete.
See also: ModIO.DownloadClient.DownloadUserAvatar, ModIO.CacheClient.LoadUserAvatar