Quick Start

Get one attack warping onto a target. Four steps: a montage window, a profile, a component, and one node.

Prerequisites
A character derived from ACharacter with a Gameplay Ability that plays an attack montage, and a montage whose Enable Root Motion is ticked. Something must supply a target: the plugin asks the avatar for an ICrimsonWarpTargetProvider. If nothing on your pawn implements it, pass a target explicitly - see How-To: Get the Building Blocks.

1. Add the warp window to your montage

Open the attack montage. Drag a Motion Warping notify state onto the notify track, covering only the frames where the character actually travels. Set its Root Motion Modifier to Skew Warp, and type a Warp Target Name - AttackTarget is a good default. You will type this exact name once more, on the profile.

The Motion Warping notify state over the travelling frames, with Skew Warp and a warp target name set.
End the window before the blend out
The engine truncates the final warp update while a montage blends out, so a window that runs into the blend out stops slightly short. The asset validator warns when it sees this.
Verify
Right-click the montage in the Content Browser and choose Validate Asset. It should pass with no errors. If it reports has essentially no authored root motion, your notify is over frames where the character does not move - drag it onto the travelling frames.

2. Create a warp profile

In the Content Browser, create a Data Asset and pick CrimsonWarpProfile as its class. Set Warp Target Name to the exact string you typed on the notify. Leave everything else at its default - the defaults are a working melee lunge.

Verify
The profile saves with no validation errors. A Warp Target Name of None is an error, because nothing could ever address the window.

3. Add the component to your character

Open the character Blueprint and add a Crimson Motion Warping component. It finds the engine's UMotionWarpingComponent on your character, or creates and registers one if there is none - you do not need to add both.

Verify
Play in editor. The Output Log shows no LogCrimsonMotionWarping errors. If it says the owner is not an ACharacter, the component is on the wrong actor.

4. Resolve the warp in the ability

In the attack ability, run Crimson Warp To Target before playing the montage, and drive the montage from its On Resolved pin. The node decides where the character should land; it does not play anything itself.

Event ActivateAbility -> Crimson Warp To Target (Profile = your profile asset, Montage = your attack montage) -> On Resolved -> Play Montage and Wait (Montage In = the same montage).

Wire On Failed to whatever should happen when there is nothing to warp toward. Playing the montage anyway is a perfectly good answer - the attack simply swings where the character is already facing.

Verify
Play in editor, acquire a target, and attack. The character closes the gap and stops at striking distance instead of ending up inside the enemy. Attack from far away and it travels only as far as the animation allows, then stops short.

Now run Play As Client with 2 players and Run Dedicated Server, and attack on a client. The character must not rubber-band, and the other client must see the same movement. A listen server will not exercise this - the host is both authority and locally controlled, so it never takes the interesting path.

See also

  • How-To: Get the Building Blocks - supplying targets, and every prerequisite the other pages assume
  • How-To: Diagnose a Warp - when the first attack does not do what you expect
  • Concept: How Reach Is Derived - what the defaults actually mean