Stance Control (px_stance) | Crouch, prone, action mode management

px_stance


What does it do?

This is the only stance control script you’ll ever need. Offering all of the below functionality:

  • Crawling/prone on front and back-side
  • Crouching
  • Sneaking
  • Disables action mode (that annoying “combat” stance when you just shot a gun)
  • Crawling/prone on front while aiming (experimental, does not network across clients)
  • Ragdoll player randomly on jump spam :snail:
  • Keymapping, features full control customization
  • Smooth animations and transition between stance states

No snails were injured in the making :hushed:.

I originally planned to release this resource a while back, however, I was held back due to other commitments. This resource incorporates an optimized and refactored version of my NoGrip release, for which the original topic may be found here.

Why re-invent the wheel?

A few reasons. Previously released iterations don’t conform to updated development practices, don’t provide configuration files, (subjectively) aren’t optimised well, and use legacy code. Yuck. :disguised_face:


Video Preview

The video preview demonstrates all functionality, configuration options and locale support.

:camera: Direct Link: Phynix Project | Stance Control on YouTube


Purchase

:shopping_cart: Direct Link: Stance Control on the Phynix Project Webstore

For any issues with the resource or your purchase, please leave a comment below. You may also send me a direct message on the Cfx.re forums.

:ballot_box_with_check: This resource conforms to all recommended development practices for FiveM. We have ensured that it is lightweight and implements functionality for native keybindings.

Code is accessible No
Subscription-based No
Lines (approximately) 400 (client) + 30 (config) + 7 (locale)
Requirements None
Support Yes (comments or DM)
Languages Lua, JSON

Installation

No prior coding knowledge is required. The resource comes with a full configuration file giving complete freedom over specific actions. Supports multiple languages through locale files. To install:

  1. Drag and drop the extracted px_stance folder into your resources directory.

  2. Add the line ensure px_stance to the bottom of your server.cfg file.

  3. Start your server and enjoy your new resource.

Specifically, you can find configuration options in px_stance/config.lua. You can either create your own locale within px_stance/locale, or edit the existing locale en_US_.lang to change language. That’s pretty neat. :safety_pin:

Dependencies

No additional resources are required, this script is fully standalone. :eggplant: .


Changelog

Version Date Notes
1.0.0 19/05/2023 Initial Release
1.1.0 24/05/2023 Fixed niche issue with keybindings not recognised as a command for some servers.

Please post any questions below. Be nice :slightly_smiling_face: . Enjoy!

3 Likes

Hi,

Just to clear up any of your “doubt” - my showcase video was released a year ago. As I’ve mentioned in my post:

This is my work and my work only, the resource was converted from my custom framework a year ago when the repository for the trailer you linked did not exist on GitHub.

My release works completely differently from the already existing version, is arguably better performance-wise and incorporates additional features which are not available in the public release you mentioned. Please do some digging before making unfounded accusations.

Hey, before saying it’s optimized, can you show me the resmon while in use of the prone / crouch / jumping / idle ?
Also you’re talking about additional features that can be found on other resources for FREE…

I would love to see the resmon while running the animations

As requested, please find the “resmon” values below. Keep in mind that comparing the duration of processor scheduling slices, in this case, is entirely relative to the processing power/ALU of your CPU. The value may vary or fluctuate and should not be used as an absolute comparison figure for performance.

This is why asking for “resmon” values makes little to no comparison between resources on different computers or operating systems.

Screenshots of "resmon" values




It’s spamming invalid command

That’s just one of the

He mentioned :blush:.

Hi,

Thanks for reaching out about your problem.

This is likely to be a compatibility issue with your chat resource. The RegisterKeyMapping native requires a corresponding command to be registered via RegisterCommand for the event-driven action to fire. It is intended functionality for key bindings to fire a back-end command when pressed.

This follows FiveM’s usage example for the RegisterKeyMapping native and isn’t necessarily caused by this resource, but rather what your chat interprets as a valid chat command. More information on the native can be found here: RegisterKeyMapping - FiveM Natives @ Cfx.re Docs.

If you could provide the chat resource you use, I would be happy to help you diagnose the problem within it (assuming it isn’t protected by Escrow). I’ve also sent you a direct message on how you can contact me directly regarding this.

Thanks. :slightly_smiling_face:

I have recently uploaded an updated version (1.1.0) of the resource which includes additional fixes to prevent problems with the previously reported “invalid command” notification.

You can find the updated version in your Cfx.re Keymaster account under “Granted Assets”. To update, simply replace the existing files and restart your server.

The current version of your resource can be found in the fxmanifest.lua file.

What is the remon on the script please

Hi,

I’ve already provided screenshots in response to a similar question. Just click the triangle to show/collapse screenshots for the post below.