# Character Configuration

There are a few differences from native unreal in how we set up the character that the player uses.

## How we Define the Character

### The Main Classes

We use a `Pawn` and `PlayerController`, same as native Unreal, but also define a `MorpheusPawnActor`, which handles the replication. For more details on this, see [Introduction to Morpheus Networking](/platform-documentation/creation/unreal-development/getting-started/networking/networking.md).

Like in native Unreal, these can be controlled via the `GameMode`.

The core Unreal classes, like `Pawn` and `PlayerController` do behave slightly differently when using Morpheus networking. For more details, see [Introduction to Morpheus Networking](/platform-documentation/creation/unreal-development/getting-started/networking/networking.md#changes-to-core-unreal-classes).

### Your Avatar

Instead of using regular static meshes for your character, we use an interoperable avatar system. For details of how this is used, see [Creating a new character](/platform-documentation/creation/unreal-development/getting-started/creating-your-own-character.md#updating-your-character-avatar)

### Your "Render Target"

To handle large scale, we don't use "full actors" (i.e. `Pawn`s) per Morpheus Actor in the world. Instead, we dynamically switch between full actors, and "the crowd" (a high performance way of representing distant actors - see [Crowd Rendering](/platform-documentation/creation/unreal-development/features-and-tutorials/the-animated-crowd.md)) based on the distance the character is away from you. For more details, see [Creating a new character](/platform-documentation/creation/unreal-development/getting-started/creating-your-own-character.md).

By default, the "full actor" used, both for yourself and for nearby other players, is the `DefaultPawnClass` defined in your `GameMode`. In release v40 onwards, your "crowd" is configured automatically for you. These can be controlled in your Morpheus Actor class. For more details on how to do this, see [Creating a new character](/platform-documentation/creation/unreal-development/getting-started/creating-your-own-character.md#updating-your-character-avatar)

<figure><img src="/files/l5GfF8ix3RdcB2eMegIS" alt=""><figcaption><p>From your Morpheus Actor class, you are able to configure your default avatar Url, and your render target. For most player characters, all you will need to set is "Use Default Pawn as Render Target Actor", and "Crowd Enabled", and it will configure things as expected.</p></figcaption></figure>

### Pawn Sets

{% hint style="info" %}
NOTE: From release v40 onwards, using Pawn Sets to configure your render targets is no longer needed - you can instead configure your character for most use cases directly from the Morpheus Actor. For more details on how to do this, see [Creating a new character](/platform-documentation/creation/unreal-development/getting-started/creating-your-own-character.md)
{% endhint %}

In basic cases, you will only need to modify your `Pawn` in the `GameMode` to control which class is used to represent player characters. However, there are some cases where you will need further configuration, which is controlled in the "Pawn Set". This controls all possible render targets used for the Morpheus Actor, including in the animated crowd, and what class is used on other clients.

The main fields to consider:

* `OverrideAuthPawnClass` - if one is provided, this will change the pawn used when using the given pawn set, when you are the auth client. Otherwise the `DefaultPawnClass` in the game mode will be used.
* `LodGroup` `Bucket` - explained in more detail in [Morpheus Render Targets](/platform-documentation/creation/unreal-development/getting-started/networking/morpheus-render-targets.md#lod-group-buckets), this allows you to specify that the given MorpheusActor is "higher priority" than others, and so should e.g. use the LOD0 Actor over other "lower priority" clients, even if they are closer.

  <figure><img src="/files/VB1qyGgQfaFnowBndhow" alt=""><figcaption></figcaption></figure>
* `LOD Levels` - this ties in to MSquared's rendering system, and how it supports >1000 player events. A limited number of nearby characters are represented as complete characters (Actor render targets), and ones in the distance are represented by the animated crowd. (For more details, see [Crowd Rendering](/platform-documentation/creation/unreal-development/features-and-tutorials/the-animated-crowd.md))
  * For now, the only recommended class to change would be the LOD 0 `Override Actor Class` - this will control what actor is used to represent the nearby other players (if left as `None`, it will also use the `DefaultPawnClass` from the game mode).

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

#### How to specify the Pawn Set

The pawn set can be controlled in the following places:

* The default pawn set can be controlled via `Project Settings - Engine - M2 Engine Default Pawn Set - Default Pawn Set`
  * By default, the pawn set used is `DA_Pawns`, which has no overrides present, meaning that the LOD0 character used will be that defined in your game mode.\\
  * From Release v36 onwards, the default pawn set can be obtained via the `GetDefaultPawnSet` helper function
  * NOTE: This requires that your character implementation applies the pawn set somewhere. This will be done for you in the example assets, but would not be the case if you started from the `M2M_CharacterBase` code class
* Manually setting the pawn set, via the `ApplyPawnSet` helper.

  * NOTE: This is done for the local machine. If you want the pawn set to be updated on all clients, you will need to call this on all clients.

  <figure><img src="/files/LSoUKR0sajTWhYGhqY73" alt=""><figcaption><p>The example character sets the pawn set to be the default pawn set on begin play.</p></figcaption></figure>

## Gameplay Changes/Additional Functionality (Deprecated)

{% hint style="warning" %}
NOTE: The following gameplay related divergences are only present in our deprecated content. From release v39 onwards, you can ignore this section entirely.
{% endhint %}

Our default character and controller have some gameplay related additions:

### Gait Speed

Instead of defining a single `MaxWalkSpeed` which controls the grounded move speed, we split the speed into three modes: `Walk`, `Jog` and `Sprint`. This gives us easy out-the-box movement speed control, e.g. starting in `Jog`, but pressing `Shift` to enter `Sprint` mode, or pressing `Ctrl` to enter `Walk` mode.

This is controlled via the `J_CharacterMovementComponent`, on the BP Character.

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

If you are using the deprecated roles table, you can customize the speed per role, by adding `Gait Speeds` to the `RoleConfigurationOverrides`. If no override is provided, it will use the default in the `J_CharacterMovementComponent`.

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

### Jump Count

Like with native Unreal, the jump count can be controlled via the `Jump Max Count` field on the character (e.g. setting it to 2 will allow you to double-jump, setting it to 0 will disable jumping).

We also add the `Character.JumpMaxCount` live config value. This defaults to `-1`, but if set to a value >= 0, it will override the value in the character, allowing for live enabling/modifying the number of jumps.


---

# 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://docs.otherside.xyz/platform-documentation/creation/unreal-development/getting-started/differences-in-unreal-development-workflow/msquared-character-configuration.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.
