Skip to content

Installation ​

Requirements ​

  • A recent FiveM server artifact (Lua 5.4, state bags).
  • OneSync (set onesync on). Without it, other players don't see stances and prone fire correctly. The server prints a warning at start when OneSync is off, and /ccs_check reports it.

Nothing else is required. There is no database, and the NUI in html/ is plain HTML/CSS/JS with vendored fonts, so there is nothing to build.

Optional integrations ​

Everything below is detected at start with GetResourceState, and every call into it is wrapped in pcall. Start these resources before np_crouch-crawl-shoot.

Kind Resources What it adds
Framework es_extended, qbx_core, qb-core Dead, downed and cuffed checks, character logout. Nothing else
Inventory np_inventory Drawn weapon and its item name, jam state, reload from ammo items, durability for scripted shots. See Compatibility → np_inventory
HUD np_hud Stance chip, key prompts and notifications instead of the built-in pill, strip and GTA feed
Walk style np_menu The quick menu's walk style comes back after crouching
Busy UIs np_phone, np_character, np_tattoos, np_payments, np_helicam, np_menu No stance change while their UI or camera is open. np_phone can't be opened while deployed
Drugs np_drugs The overdose state blocks stances
Legacy scripts written for crouch_crawl Answered through the compatibility aliases. Don't run crouch_crawl itself next to this resource

np_crouch-crawl-shoot needs no change in any of them. np_inventory, np_hud and np_menu got small additions for it (jam and reload exports, the stance chip, the walk style export). Use versions that include them; older versions still work, without those features.

Steps ​

  1. Put the resource in resources/ as np_crouch-crawl-shoot. Other resources call its exports by that name (exports['np_crouch-crawl-shoot']:GetStance()).
  2. Add it to server.cfg after its optional integrations:
    cfg
    set onesync on
    
    ensure es_extended            # or qbx_core / qb-core, optional
    ensure np_inventory           # optional
    ensure np_hud                 # optional
    ensure np_menu                # optional
    ensure np_phone               # optional
    ensure np_crouch-crawl-shoot
  3. Open config.lua. The defaults are a working setup. Things you may want to change first:
    • Config.Locale: 'en' or 'de'.
    • Config.Keys: the default keys (LCONTROL crouch, Z prone). See Controls.
    • Config.Prone.weaponClasses: which weapon classes may fire prone.
    • Config.CanUseStance: your own veto, e.g. no prone in certain zones.
  4. Before going live, run the in-game test kit with two clients.

Start order

The framework is detected once, when the resource starts, so start it first. np_hud, np_inventory and np_phone are re-checked when they start or stop, so a restart of one of them is picked up. If np_hud starts later, the built-in stance pill hides once np_hud is detected.

On start the client prints what it found to F8:

[np_ccs] framework esx
[np_ccs] integration np_hud         active: stance chip via state bags, key prompts, notifications
[np_ccs] integration np_inventory   active: drawn weapon, ammo, jam state, reload

and the server prints the version and the OneSync mode.

Turning parts off ​

Want Set
No crouch (keep GTA's stealth walk) Config.Crouch.enabled = false, or keep crouch on another key and Config.Crouch.replaceStealth = false
No prone at all Config.Prone.enabled = false
Prone, but no prone fire Config.Prone.weaponClasses = {}
Don't use np_hud / np_inventory although they run Config.UseNpHud = false / Config.UseNpInventory = false
No NPC stealth changes Config.Stealth.enabled = false
No crouch_crawl aliases Config.Compat.crouchCrawlAlias = false (and legacyEvents, legacyStateBags)

Troubleshooting ​

Symptom Fix
LCONTROL / Z do nothing Another resource uses the key, or the player rebound it. Check Settings → Key Bindings → FiveM → Stance. A notification tells you when a stance is refused (water, vehicle, slope, blocked, busy UI).
"Close the menu first." A UI from the busy list is open (inventory, phone camera, character menu, np_menu, payments, helicam), or the character is not loaded yet.
Aiming while prone does nothing The drawn weapon's class is not allowed in Config.Prone.weaponClasses, or you are lying on the back. Check the class with Config.Debug = true.
"No prone aim pose available on this client" No candidate of the active pose pack resolved. Run /ccs_check and fix Config.Poses.
Others see the player standing while prone OneSync is off, or the animation candidates don't resolve on their client. Run /ccs_check on both clients.
Both crouch_crawl and this resource react to the keys Stop one of them. The client prints a warning when both run.
Server log shows rejected prone shot See Prone fire & sync → Server validation for the reasons. A few rate or origin rejects under lag are normal.