# Retargeting Marketplace Characters

In this tutorial we are going to explain how to retarget / adjust a character purchased from the Unreal Engine Marketplace to function with Motion.

<mark style="color:blue;">Motion makes use of the UE5 Metarig as demonstrated and used in the Lyra Sample Game. All changes you will find in the Lyra sample game also apply to Motion.</mark>

<mark style="color:orange;">At this point, we recommend using a seperate branch in your VCS or making a backup before continuing.</mark>

### Retargeting a UE4 Character

In this scenario we will cover retargeting a UE4 character from the marketplace to work with Motion. We will use the [Gothic Knight](https://unrealengine.com/marketplace/en-US/product/gothic-knight) asset as example character, as it has not been updated to UE5 at the time of writing.

#### Create Animation Blueprint for Mesh

To get started, create an animation blueprint for the skeletal mesh you intend to use by right-clicking, and selecting `Create -> Anim Blueprint`.

<figure><img src="/files/8yvv6RAsuXSkF517FbZA" alt=""><figcaption></figcaption></figure>

In this case it's called `SK_GothicKnight_Skeleton_AnimBlueprint`. Open the Animation Blueprint by double-clicking it.

#### Add Animation Blueprint Logic

Unlike Retargeting in Unreal Engine 4, retargeting the skeletal mesh to use the UE5 skeleton is not neccessary. Instead, we instruct the animation blueprint to copy the pose of it's parent mesh using a `IK Retargeter`.

<mark style="color:blue;">The IK Retargeter used here are also included in the Third Person Starter Pack that ships with Unreal Engine 5.</mark>

In the AnimGraph of the Animation Blueprint, create a new `Retarget Pose From Mesh` node and connect it to the Output Pose.

<figure><img src="/files/KKC2iSRrxfdShfIFiJws" alt=""><figcaption></figcaption></figure>

Click the newly created node and go to the Details tab. There, select `RTG_UE5Manny_UE4Manny` in the `IKRetargeter Asset` dropdown.

<figure><img src="/files/veW1Hy7PVrjWldaWIu3Q" alt=""><figcaption></figcaption></figure>

That's it! You successfully created the retargeting animation blueprint for your character mesh. Now, let's add it to Motion.

#### Adding your Mesh to the Motion Character

Open your `BP_MotionCharacter` and head over to the Components tab.

Select the `FullBody` skeletal mesh and, on the details tab, change the skeletal mesh to your new mesh.

Then, change the `Anim Class` property above to be the animation blueprint you created earlier in this tutorial.

<figure><img src="/files/HD6eMhOgFPEPGRDLzDDZ" alt=""><figcaption></figcaption></figure>

Repeat the same process for the `Headless` skeletal mesh.

#### Result

Starting a Play-in-Editor session should now result in your new character being shown, with the mannequin being invisible and all animations being applied to the new mesh.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://motion.docs.regensturm.com/tutorials/retargeting-marketplace-characters.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
