ReadyPlayerMeAvatarLoader

The AvatarLoader class is used for loading and downloading avatar models and configuring the output.

ReadyPlayerMeAvatarLoader loads the avatar from the provided url and stores it in local storage. Used by ReadyPlayerMeActorComponent.

Public Functions

Function
Returns
Description

LoadAvatar( const FString& UrlShortcode, class UReadyPlayerMeAvatarConfig* AvatarConfig,USkeleton* TargetSkeleton, const FglTFRuntimeSkeletalMeshConfig& SkeletalMeshConfig, const FAvatarLoadCompleted& OnLoadCompleted, const FAvatarLoadFailed& OnLoadFailed);

void

Downloads the avatar asset from the UrlShortcodeand saves it in local storage.

CancelAvatarLoad();

void

Immediately cancels avatar loading. When the garbage collector is removing the AvatarLoader, avatar loading gets automatically cancelled.

LoadAvatar() Parameters

Parameter
Description

const FString& UrlShortcode

Avatar url or shortcode.

UReadyPlayerMeAvatarConfig* AvatarConfig

Config for loading avatar with custom configuration.

USkeleton* TargetSkeleton

Chose the skeleton that will be used for the loaded avatar. If not set, the default skeleton will be used.

const FglTFRuntimeSkeletalMeshConfig& SkeletalMeshConfig

glTFRuntime skeletal mesh config that will be used for loading the avatar.

Important: This property should be changed only for very special cases as changing this property might break the avatar.

const FAvatarLoadCompleted& OnLoadCompleted

Success callback. Called when the avatar asset is downloaded.

const FAvatarLoadFailed& OnLoadFailed

Failure callback. If the avatar fails to load, the failure callback will be called.

Last updated

#168: React Guides

Change request updated