Combatintermediate9 min readupdated 11 Sept 2026

Camera shake and aim sway for FiveM weapons

The short answer

ShakeGameplayCam(name, intensity) starts a named shake such as HAND_SHAKE or DRUNK_SHAKE; SetGameplayCamShakeAmplitude changes its strength and StopGameplayCamShaking(true) ends it. Per-weapon firing shake comes from weapons.meta fields like RecoilShakeHash and RecoilShakeAmplitude. Use gentle, short shakes tied to gameplay (stamina, injuries) and let players aim through them.

Camera shake makes weapons feel heavy — or unbearable. A little hand sway after sprinting rewards careful play; too much makes players motion-sick. FiveM gives you two levers: the recoil shake defined per weapon in weapons.meta, and script-driven shakes through ShakeGameplayCam.

Camera shake and aim sway for FiveM weapons — illustrated with a FiveM-compatible minimap render

#Built-in shake names

ShakeFeel
HAND_SHAKESubtle handheld sway
DRUNK_SHAKESlow, heavy wobble
JOLT_SHAKEShort hit
VIBRATE_SHAKEFast vibration
ROAD_VIBRATION_SHAKEDriving rumble
SMALL_ / MEDIUM_ / LARGE_EXPLOSION_SHAKEExplosion impacts
SKY_DIVING_SHAKEFree-fall buffeting
FAMILY5_DRUG_TRIP_SHAKEStrong drug effect
DEATH_FAIL_IN_EFFECT_SHAKEDeath screen

#Aim sway after sprinting

client.lua — sway while aiming shortly after a sprint
local lastSprint = 0
local shaking = false

CreateThread(function()
    while true do
        local sleep = 250
        local ped = PlayerPedId()
        if IsPedSprinting(ped) then lastSprint = GetGameTimer() end

        local tired = GetGameTimer() - lastSprint < 4000
        local aiming = IsPlayerFreeAiming(PlayerId())

        if aiming and tired and not shaking then
            ShakeGameplayCam('HAND_SHAKE', 0.6)
            shaking = true
        elseif (not aiming or not tired) and shaking then
            StopGameplayCamShaking(true)
            shaking = false
        end

        if aiming then sleep = 100 end
        Wait(sleep)
    end
end)

Start the shake once and stop it once — calling ShakeGameplayCam every frame restarts it and looks jittery.

#Injury and effect shakes

  • Low health: HAND_SHAKE whose amplitude rises as health falls (SetGameplayCamShakeAmplitude).
  • Drunk or drugged: DRUNK_SHAKE with the matching timecycle modifier.
  • Nearby explosion: a short SMALL_EXPLOSION_SHAKE scaled by distance.

#Firing shake in weapons.meta

FieldControls
RecoilShakeHashThe camera shake played when firing in third person
RecoilShakeHashFirstPersonThe shake used in first person
RecoilShakeAmplitudeStrength of that shake
MinTimeBetweenRecoilShakesMinimum gap between shakes (ms)

Lowering RecoilShakeAmplitude gives a steadier view without changing where bullets go. Real recoil (the camera kick) is a script or pattern — see the recoil script guide — and spread is AccuracySpread. Field details are in weapons.meta explained.

#Removing shake

StopGameplayCamShaking(true) stops script shakes immediately. For firing shake, edit the weapon meta or stream a meta override. Offer players a calmer option if your server is shake-heavy — accessibility keeps people around.

Share this guideXRedditFacebook

Questions

How do I add camera shake in FiveM?
Call ShakeGameplayCam('HAND_SHAKE', 0.5) (or another shake name) and stop it with StopGameplayCamShaking(true).
How do I change the strength of a running shake?
Use SetGameplayCamShakeAmplitude(value) while it runs.
Where does weapon firing shake come from?
From weapons.meta: RecoilShakeHash, RecoilShakeHashFirstPerson and RecoilShakeAmplitude.
Is camera shake the same as recoil?
No. Shake wobbles the view; recoil moves the aim upward. They are configured separately.

Ready to pick a map?

Twelve themes on three base map styles, $8 each, instant download.

Relevant to what you just read