In this example, we are using characters from the Mixamo Animation Pack, available for free on the Unreal Engine Marketplace.
In the Mixamo Animation Pack, all the characters inherit from a general character Blueprint. Working in your own project, or with a
C++ setup, you would need to adjust the following steps, but the primary concepts still apply.
Each character has their own value for a Dialogue Voice variable. Even if you don't localize your audio content, having a distinct voice per character
means that you can associate a given voice actor's recordings with that voice, so Zoe will always sound like Zoe.
- In the MixamoAnimPack folder in the Content Browser, double-click on MixamoCharacter_Master to open the Blueprint.
- Add a new variable to the Blueprint.
- Name the new variable DialogueVoice, then set its type to a DialogueVoice Reference.
- Compile and save your Blueprint.
Now, we need to create the Dialogue Voice assets to use for each of our three characters.
- Go back to the Content Browser, and create a new Dialogue Voice asset.
- Name the new asset QuestNPC, then double-click to open it.
- Referring to our design document, we know that the quest NPC's voice is Feminine and Singular. Use the drop-down menus to set the Gender and Plurality accordingly.
- Repeat the process two more times to create a Dialogue Voice asset for Adam that is Masculine and Singular, and a Dialogue Voice asset for Zoe that is Feminine and Singular.
- Save and close all your new Dialogue Voice assets.
Now that our Dialogue Voices have been created, we can associate them with our characters.
- Back in the Content Browser, in the Mixamo_SWAT folder, open the Mixamo_SWAT Blueprint.
- If your Blueprint is not a data-only Blueprint and the defaults are not already visible, click on the Class Defaults button in the Toolbar to open the Blueprint's default properties.
- Set Dialogue Voice in the Details panel to Quest NPC.
- Repeat the process to set the Mixamo_Adam Blueprint's Dialogue Voice to Adam, and to set the Mixamo_Zoe Blueprint's Dialogue Voice to Zoe.
To help identify your Dialogue Voice characters:
- Place your character in the world, then frame them in the viewport.
- Right-click on the Dialogue Voice asset in the Content Browser.
- Select Asset Actions > Capture Thumbnail.