The Ultimate Character Controller is integrated with UMA allowing your character to be created dynamically while being controlled by the Ultimate Character Controller. Version 2.8 or later of UMA should be used for this integration.

There are two different options for using the Ultimate Character Controller with UMA. The first option uses UMA’s Bone Builder tool which creates all of the bones necessary at edit time so you can then use the Character Manager like any other character. The second method adds all of the Ultimate Character Controller components after UMA has created the character. This option is more advanced and is recommended for those with programming experience as you will likely need to do some scripting in order to get the most out of it.

Bone Builder

UMA’s Bone Builder tool creates all of the bones necessary for your character at edit time which allows you to use the Ultimate Character Controller editors like normal. To the Ultimate Character Controller it doesn’t even know that UMA was used and no integration components are required.

  1. Drag your UMA Dynamic Character Avatar prefab into your scene.
  2. Open the UMA Bone Builder under the UMA Toolbar.
  3. Select the UMA Dynamic Character Avatar in your scene as the UMA GameObject.
  4. Select the Generate Bones button. UMA Should create all of the bones required for the character.
  5. Build your character like normal through the Character and Item Managers.
  6. Select the UMADynamicCharacterAvatar GameObject and inspect the Dynamic Character Avatar GameObject. Ensure the Additional Utility Recipes array is empty under the Dynamic Character Avatar component.
  7. Set the Default Animation Controller under the Race Animation Controllers dropdown to the animator controller that has been added to your character. It will be the same Animator Controller used by the Character Manager, such as Demo or ThirdPersonControllerDemo. This Animator Controller is located within the Opsive/UltimateCharacterController/Demo/Animator/Characters folder.
  8. UMA doesn’t like transforms that have the same name. You’ll want to rename the “Items” GameObject to a unique value such as “RightItems” or “LeftItems” to ensure UMA doesn’t throw any errors.
  9. Your UMA character is now ready to be used.

Runtime Creation

The UMA Character Builder component can add the Ultimate Character Controller components after UMA has created the character at runtime. This method does not require the bones to be added ahead of time using Bone Builder. This option is meant for more advanced uses that have experience with both UMA and the Ultimate Character Controller as there will likely be some scripting required to customize your character.

  1. Drag your UMA Dynamic Character Avatar prefab into your scene.
  2. Select the UMADynamicCharacterAvatar GameObject and inspect the Dynamic Character Avatar GameObject. Ensure the Additional Utility Recipes array is empty under the Dynamic Character Avatar component.
  3. Set the Default Animation Controller under the Race Animation Controllers dropdown to the animator controller that has been added to your character. It will be the same Animator Controller used by the Character Manager, such as Demo or ThirdPersonControllerDemo. This Animator Controller is located within the Opsive/UltimateCharacterController/Demo/Animator/Characters folder.
  4. Add the UMA Character Builder component to your UMA Dynamic Character Avatar. This component will add all of the Ultimate Character Controller objects and execute after UMA has created the character. If you’d like to execute any code after the character has been created you can do so by adding your code to the Character Created event.
    The options within the UMA Character Builder are similar to the options within the Character Manager. There are a few key differences:

    • First/Third Person Movement Type is specified by class name. For example, “Opsive.UltimateCharacterController.FirstPersonController.Character.MovementTypes.Combat” points to the Combat Movement Type for the first person perspective.
    • First Person Hidden Object Names uses the transform name to determine which objects should be hidden while in a first person view. In the screenshot the Head GameObject will be hidden. The names are relative to the character’s base Transform.
    • First Person Base Objects optionally specify any First Person Base Objects that should be dynamically generated by UMA and added to the added to the character. See step 6 for more details.
    • Assign Camera specifies if the camera should be assigned after the character has been created.
  5. Optionally add the UMA Ability Builder or UMA Item Pickup components to the same GameObject as the UMA Character Builder was added to.  These components will likely need to be expanded to completely customize your character and will require scripting experience.
  6. If you’d like to use a UMA created character for your first person arms you can do so by specifying the UMA character that you’d like to use within the First Person Base Objects array of the UMA Character Builder. This requires another UMA Dynamic Character Avatar to be placed in the scene with the UMA First Person Base Object component added to it:
    This UMA character can be a generic object so you can use a generic set of arms with the main character model. A great video which shows how to do this is located here. The UMA First Person Base Object component contains the following parameters:

    • Local Position/Rotation specifies the local position and rotation that the UMA First Person Base Object should spawn underneath the character’s First Person Base Objects Transform.
    • Item Slot Locations specifies the child Transform path that Item Slot component should be added to.
    • Animator Controller refers to the Animator Controller that should be added to the GameObject.
  7. When Unity enters play mode the character will now first be created by UMA and then able to be controlled by the Ultimate Character Controller.

Downloads

Ultimate Character Controller
First Person Controller
Third Person Controller
UFPS: Ultimate First Person Shooter
UTPS: Ultimate Third Person Shooter
UFPM: Ultimate First Person Melee
UFPM: Ultimate Third Person Melee