Presets

Built-in effects that are registered when MotionFX loads. They are written entirely with the public primitives, so they also serve as examples for building your own.

MotionFX:Play(FX.Impact.Shake)
MotionFX:Play("Concussion", { Intensity = 0.7 })

Params

Every preset has a sound by default. Pass Params to adjust it:

ParamTypeDescription
Soundbooleanfalse plays the preset without sound.
SoundIdstringUses a different sound asset.
VolumenumberSound volume. Default 0.8.
DirectionVector3Explosion only. A camera-space push direction. Vector3.new(0, 0, 1) pushes the camera backwards.
MotionFX:Play(FX.Impact.Explosion, {
	Params = { Direction = Vector3.new(0, 0, 1), Volume = 1 },
})

Impact

PresetRetriggerLengthPrimitives
ShakeStack (max 4)≈ 0.52 sRotation, Position, Sound
EarthquakeRefresh6 sRotation, Position, Sound
ExplosionStack (max 3)≈ 1.6 sRotation, Position, FOV, Blur, Color, Sound
RecoilStack (max 3)≈ 0.27 sPosition, FOV, Rotation, Sound

Shake

A short, sharp jolt: high-frequency noise on rotation and position under a 0.02 s attack and 0.5 s release. Several shakes can stack.

local envelope = Drive.Envelope({ Attack = 0.02, Release = 0.5 })
Tracks = {
	{ Primitive = "Rotation", Driver = Drive.Modulate(Drive.Noise({ Frequency = 18, Amplitude = Vector3.new(1.2, 1.2, 2.5) }), envelope) },
	{ Primitive = "Position", Driver = Drive.Modulate(Drive.Noise({ Frequency = 22, Amplitude = Vector3.new(0.15, 0.15, 0) }), envelope) },
}

Earthquake

Slow, heavy rumbling that builds over 1.2 s, holds for 3 s and dies away over 1.8 s. Its sound fades out with the shaking. Playing it again restarts the quake.

Explosion

A violent shake plus an FOV punch (spring, kick 7), a blur flash to 14, and a brightened, desaturated colour flash. With Params.Direction, a positional spring also pushes the camera along that vector.

Recoil

A weapon kick. The camera moves back, the FOV punches, and the camera pitches up with a small random yaw on each shot. All three are stiff springs, so rapid fire stacks naturally.

Injury

PresetRetriggerLengthPrimitives
BloodRefresh≈ 2.35 sVignette ×2, Color, Rotation, Sound
ConcussionRefresh≈ 3.7 sBlur, FOV, Rotation, Color, Vignette, Sound
BrainDamageIgnore10 sRotation, FOV, Blur, Color ×2, Vignette ×2, Sound

Blood

A dark edge vignette with a deep red ring inside it, a red tint and a small roll. It flashes in over 0.05 s, holds for 0.9 s and fades over 1.4 s.

Concussion

A heavy blur (20) that clears over 3 s, a narrowing FOV spring, a slow drunken sway, washed-out colour and a vignette. Ear ringing fades in, starts 0.8 s into the audio, and fades out at the end.

BrainDamage

A sustained, disorienting state. It drifts violet → orange → blue, swings between washed-out and oversaturated, and has a breathing coloured ring inside a dark vignette, plus wandering rotation, FOV and blur. It fades in over 1.5 s and out over 2 s.

-- Lasts 10 s by default; override, stop early, or drive its strength
local handle = MotionFX:Play(FX.Injury.BrainDamage, { Duration = 30 })
handle:SetIntensity(0.4, 2)
handle:Stop()

Overriding a preset

Presets are ordinary registry entries. Replace one with your own definition:

MotionFX:Create("Shake", myShake, { Overwrite = true })