Skip to content

B1AnimNotify_FootSteps

File: BlueClient2/Source/BlueClient/Animation/AnimNotifies/B1AnimNotify_FootSteps.h / .cpp Base Class: UAnimNotify

Purpose

Plays footstep audio at the notify frame by detecting the physical material of the floor beneath the foot socket and matching it with the character's current shoe outsole type.

How to Add in the Editor

  1. Open an Animation Montage or Animation Sequence.
  2. Right-click on the Notify trackAdd NotifyB1AnimNotify_FootSteps.
  3. Set PrintSocketName to the foot socket (e.g., foot_l or foot_r) in the Details panel.

Editor Properties

Property Type Default Description
PrintSocketName FName Socket on the foot bone used as the trace origin
OptionalSoundId FName (empty) Override sound ID; if empty, the sound is auto-selected from the material/outsole lookup table
TraceChannel ECollisionChannel ECC_GameTraceChannel10 Collision channel for the ground line trace
TraceStartZOffset float 100.0 Z offset above the socket where the trace begins
TraceEndZOffset float -150.0 Z offset below the socket where the trace ends
VolumeMultiplier float 1.0 Volume scale applied to the spawned audio
PitchMultiplier float 1.0 Pitch scale applied to the spawned audio
bFollow bool false If true, the audio component moves with the character

Behavior

  1. Performs a line trace downward from the foot socket position.
  2. Reads the UPhysicalMaterial from the hit surface.
  3. Determines the shoe outsole type from UB1AppearanceComponent on the character.
  4. Looks up the matching FB1FootStepsAudioTableRow using material + outsole combination.
  5. Loads and spawns the audio via UB1AudioManager (2D or attached depending on bFollow).
  6. Sets the MoveVelocity parameter on the audio component to match character speed.