Skip to content
Version 2.32.0
↓ Get the launcher

IPlayerProfile.RequestAvatarUrl method

Resolve the profile avatar image URL for a character/role id (the same id a received chat message carries as its sender id). Fire-and-forget: the request is issued on the game’s Social proxy and onResult is invoked exactly once on the main (Unity) thread with the full https://…png URL, or null when the player has no custom photo or the request failed. Never throws. The service returns only the URL — the caller owns downloading, caching and turning it into a texture.

public void RequestAvatarUrl(long charId, Action<string?> onResult)
parameter description
charId The player’s character/role id.
onResult Main-thread callback receiving the avatar URL, or null on no-photo / failure.