decoupled horz recoil, non-linear inertia movement, additions to lua_help_ex.script#417
Merged
themrdemonized merged 4 commits intothemrdemonized:horz-recoilfrom Feb 5, 2026
Conversation
- affects offset movement when looking around - affects weapon tilt when walking sideways - added cvar to toggle it, disabled by default - added cvar to lua_help_ex.script
- added cvar to control horz recoil behavior, disabled by default - added cvar to lua_help_ex.script
e1bf1ca
into
themrdemonized:horz-recoil
17 of 18 checks passed
Owner
|
Thanks, i'll add the options myself |
Contributor
Author
|
@themrdemonized alright. :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
1. Decoupled Horizontal Recoil
Usually horz recoil offset angle is coupled with and therefore dependent on vert recoil offset angle. This causes horz recoil to be practically zero when starting to shoot and slowly increasing with higher vert offset angle. This approach removes this dependency, horz recoil has full effect on first shot. Attention: unlike vert recoil, horz recoil does NOT increase with amout of bullets fire. The magnitude of the offset is random with each shot.
This approach makes more sense imo and also makes gunplay a little more challenging. Can be toggled with the cvar 'g_decouple_horz_recoil', disabled by default. Should this get an option in modded exes settings, e.g. in General/Aim? If yes then I'll add it to the PR.
2. Non-linear Inertia
Currently inertia movement uses linear functions to calculate any offsets which makes movement look quiet robotic. This adds non-linear offset calculation functions for offset return movement (after changing view direction) and weapon tilt back movement (after walking sideways) to make the movement feel/look more organic, difference is subtle though. Can be toggled with the cvar 'g_use_non_linear_inertia', disabled by default.
3. Additions to lua_help_ex.script
Added new color exports that I forgot to add in my last PR. Also added the cvars from 1. and 2.