# Melee Clips

**Melee Clips** are the essential part of the **Melee** module. You can think them as animation clips in steroids, where you can not only define what animation will be played, but also what effects this animation has, when these happen and how this affects the character and enemies behavior.

![(Melee Clip overview)](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2wwqd4Q3Iu6d20YqeS%2F-M2wzVqMR2W0gUXoP-Kw%2Fmelee-clip.png?alt=media\&token=e62849e7-959a-4350-9730-bc72a847d661)

There are 4 sections and a configuration timeline:

* **Animation:** Everything related to how this animation clip is played
* **Motion:** How the animation affects the character position
* **Effects:** What sound and particle effects will play
* **Combat:** How this clip affects combat

### Animation Section

This section defines what animation will be played, and whether it's going to use an avatar mask or not.

![](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2x0BFPAwYyxPMsYlk5%2F-M2x2-ujYaTKx91Azv6S%2Fmelee-clip-animation.png?alt=media\&token=8c199b41-2a5d-4823-8813-4aa221b8a702)

The **Transition In** and **Transition Out** fields define the amount of blending between the current character animation and the one defined in this Melee Clip. Unless you go for an ultra-stylized game, these values should have a magnitude of around 0.1 and 0.4 seconds.

### Motion Section

This section complements the previous one. It allows to define how the character moves during the playback of the animation by defining the delta increment of position.

Game Creator doesn't support root motion. However, if you use an animation using root motion, you can extract the delta motion and use it in the Melee Clip.

![](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2x2Wkg4JZ6fUO_Gvl6%2F-M2x6LganS0EbSHGedoC%2Fmelee-clip-motion.png?alt=media\&token=6b2b8f09-3263-49c7-a505-b8bcd8873635)

The **Movement Multiplier** field is a coefficient used to increase the scale of all motion proportionally.

**Gravity influence** defines how gravity will affect the character when playing this animation clip. A gravity influence of 1 will make the character react normally to gravity, while a value of 0 will make the character ignore the gravity.

{% hint style="info" %}
A Gravity Influence value of zero is usually used when creating attacks that combine land and air attacks. For example, launching an enemy on the air and following it up.
{% endhint %}

### Effects Section

This section allows to define which sound effects will be played when the Melee Clip is used as well as how much *rigidbodies* will be pushed (in case the Melee Clip is an attack and collides with a rigidbody).

![](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2x2Wkg4JZ6fUO_Gvl6%2F-M2x7U_jlZ8uOyBDzbul%2Fmelee-clip-effects.png?alt=media\&token=57bf0dc3-0958-4739-9bac-e21801a82e8a)

The **Hit Pause** toggle allows to create hit pause effects (also known ad freeze-frames). These are cinematic effects that increase the bombastic feeling of the impact of an attack.

![](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2x7zE-wcrP69kdnAFi%2F-M2xByM4qdqWPgsvMM1w%2FLarge%20GIF%20\(656x332\).gif?alt=media\&token=e9fdd1b3-99c8-4ff6-898b-ed94c4ab5db7)

**Hit Pause Amount** is the time scale in which the game will be set and the **Hit Pause Amount** is the amount of real time seconds this effect will last for.

### Combat Section

This section is quite important and tweaking its parameters will completely change the experience of the game.

![](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2x2Wkg4JZ6fUO_Gvl6%2F-M2x7X2--gsFHt_fWDJS%2Fmelee-clip-combat.png?alt=media\&token=9d9c6034-4914-42c7-8128-4db95f97d690)

The **Is Attack** toggle defines whether this **Melee Clip** is considered an attack or not. This will enable or disable the timeline below and will hide and show options related to attacks.

**Is Blockable** defines whether this attack can be blocked by opponents. If an attack is not blockable, then it will bypass and hit any enemy, even if these are in a blocking stance.

**Defense Damage** and **Poise Damage** define how much this attack will chip from the hit opponent or opponents.

{% hint style="info" %}
If the opponent is blocking, it will only subtract Defense damage. On the other hand, if the opponent wasn't blocking, it will decrease its poise by Poise damage amount.
{% endhint %}

**Interruptible** field tells whether if this **Melee Clip** can be interrupted when being played or not. By default it should always be set to *Interruptible*. However, in some situations, it may be interesting leaving it as *Uninterruptible*. For example, an enemy attack that takes a good chunk of time to load and creates a devastating area of effect damage should probably be set to uninterruptible. This will prevent the boss from cancelling the attack when receiving damage from the player.

**Vulnerability** field allows to define whether opponent attacks affect the character or not. By default it's set to Vulnerable. However, there may be cases where you want an animation clip to make the character completely invulnerable for a few seconds. For example, when dashing through the battlefield or changing phases if it's a boss battle.

**Posture** field can be set to either ***Steady*** or ***Stagger***. Steady posture means that the character can input commands and the character will respond normally. Stagger means that the input from the player/AI system will be ignored while this **Melee Clip** is being played. This is mostly used when a character receives damage, it plays a small animation clip reacting to the hit, in which the character is incapacitated for a few seconds.

### Attack Timeline

If marking the **Is Attack** toggle, a timeline with a legend will appear at the bottom of the **Melee Clip** asset.

![(Scrub the Timeline to preview the animation)](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2xcJDERXmcQu0YXANo%2F-M2xdZba0Tv4UmE0roYh%2Fmelee-clip-timeline.png?alt=media\&token=72b4f8c3-63e9-46dd-9820-94c693bca7d2)

This **Timeline** can be scrubbed with the cursor and the character selected in the scene view with play the animation.

{% hint style="warning" %}
If you can't scrub because it appears a message saying "Drop a scene Character onto the Preview Window", drag a Game Creator from the Hierarchy onto the small window below the Melee Asset, as seen in the GIF below.
{% endhint %}

![(Drop a scene Character onto the preview window to scrub the animation)](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2xcJDERXmcQu0YXANo%2F-M2xeqi4M7sIL86l8b7U%2FLarge%20GIF%20\(988x658\).gif?alt=media\&token=928f0e96-4730-4832-8f98-8b265d4830a0)

Once you have this set up, you can start defining the animation attack phases. Any attack is divided into three phases: **Anticipation**, **Activation** and **Recovery**.

![](https://2174264233-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAqwYovmUPn5V6CMeID%2F-M2xf32s90Zcg0HzeokM%2F-M2xm_6A_Catskzj7veJ%2Fmelee-sekiro-phases.gif?alt=media\&token=b45a0fb7-25bd-4f0d-8006-140895f3fdb5)

#### Anticipation

Also known as wind-up or start-up. In this phase, the character prepares to attack. As a general rule of thumb, the more powerful the attack, the greater this phase should be.

#### Activation

This is where the hit happens. Any enemy colliding with the Blade Component will be hit. Also, during this phase, the trail renderer (if any) in the Blade Component will be enabled and disabled at the end of the phase.

{% hint style="success" %}
It is important to note that this phase should be at least two frames long in order to properly detect any objects passing through the weapon.
{% endhint %}

#### Recovery

This phase is where the character should try to stop the momentum from the attack. As a general rule, the more powerful the attack, the greater the momentum, and thus, the recovery phase should scale proportionally.

{% hint style="info" %}
When concatenating two attacks in a combo (let's say *AttackA* and *AttackB*), the recovery phase of *AttackA* will be skipped and *AttackB* will start as soon as the activation phase of *AttackA* finishes.&#x20;

This is intentional. Combos are meant to be combination of attacks that take advantage of the momentum of the previous attack to start the new one.
{% endhint %}
