How-To: Showcase the Player's Character
Goal: display the player's actual character - equipped gear, materials, animation - on the loading screen. Your game provides the data (ICrimsonLoadingCharacterProvider), a director actor in a showcase scene applies it (ICrimsonLoadingCinematicInterface), and FCrimsonLoadingCharacterInfo carries it between them. The plugin knows nothing about your equipment system.
1. Understand the data you will fill
FCrimsonLoadingCharacterInfo holds two arrays. MeshComponents describes the character itself as one entry per mesh slot; AdditionalActors describes separate showcase actors (mount, pet, prop). Exactly one mesh entry must be the leader: in Unreal, modular characters animate by having one skeletal mesh component drive the skeleton while every other piece calls SetLeaderPoseComponent to follow it - so only the leader entry needs an AnimInstanceClass.
FCrimsonLoadingMeshComponent field | Meaning |
|---|---|
SlotName | Logical slot (Body, Helm, Chest, Weapon_R, ...) - the director maps it to a component |
Mesh | The USkeletalMesh; null means the slot is empty and the director hides it |
Materials | Per-element overrides; empty = mesh defaults |
AnimInstanceClass | Anim Blueprint class - set on the leader only |
bIsLeader | True on exactly one entry (the base body) |
RelativeTransform | Offset from the stand root; identity for normally aligned meshes |
FCrimsonLoadingActorEntry adds ActorTypeTag (e.g. CrimsonShowcase.Actor.Mount - your own tag convention), an optional AttachSocketName (set it to parent the actor to the leader mesh, leave None for free placement), plus the same mesh/material/anim fields.
2. Implement the provider on your pawn or a component
The manager queries, in order: the local PlayerController, then the Pawn, then each Pawn component - first implementor whose result has a valid leader wins. An equipment/appearance component is usually the right home, because it already knows what is equipped. Only the first local player is queried (split-screen players are ignored).
Images/CrimsonLoadingScreen/howto-provider-bp.pngMesh unconnected (null) for empty slots.Get Local Player Character Info (pure node / GetLocalPlayerCharacterInfo()) from a test key while playing: the returned MeshComponents array contains your entries with one leader.3. Build the showcase director
The director is an actor in your showcase scene with pre-placed SkeletalMeshComponents, one per slot. It implements ICrimsonLoadingCinematicInterface: OnLoadingScreenStarted hands it the character info to apply; OnLoadingScreenEnded tells it to stop. The manager notifies every actor in the current world that implements the interface.
Images/CrimsonLoadingScreen/howto-director-bp.pngOnLoadingScreenStarted is sent to actors in the world that is current when the screen opens. A director in a seamless-travel transition map loads later - it never receives the call. Fix: in the director's BeginPlay, pull the snapshot yourself via the manager's Get Cached Character Info and apply it if the screen is showing (Get Loading Screen Display Status).See also
- How-To: Live Render Target Preview - pipe the showcase scene into the loading screen widget.
- Concept: The Cinematic Preview Pipeline - cached vs live info, query order, timing.
- How-To: React to Loading Screen Events - the non-actor way to receive the character info.