Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable Counter-Strike Source view model chirality in Mapbase #84

Merged

Conversation

1upD
Copy link

@1upD 1upD commented Dec 29, 2020

This pull request simply activates two preprocessors that previously had deactivated the code Counter-Strike uses to switch left handed viewmodels to right handed mode. This will allow weapons to be switched to left handed mode if desired.

Please note that in order to use left handed viewmodels, the following values will need to be added to each weapon script:

	"BuiltRightHanded"  "1"
	"AllowFlipping"  "1"

If these values are set, then a player or mapper may change the chirality of the player's hands with this ConVar:

cl_righthand 0 // left handed
cl_righthand 1 // right handed

Does this PR close any issues?

PR Checklist

  • My PR follows all guidelines in the CONTRIBUTING.md file
  • My PR targets a develop branch OR targets another branch with a specific goal in mind

@Blixibon Blixibon linked an issue Jan 23, 2021 that may be closed by this pull request
@Blixibon
Copy link
Member

Blixibon commented Jan 23, 2021

This PR seems to function as intended, although I want to point out that both AllowFlipping and BuiltRightHanded are enabled by default, so they don't need to be added to weapon scripts unless they should be set to 0.

Most viewmodels in HL2 seem to flip pretty well, although a few of them look pretty weird and inconsistent with their un-flipped counterparts. The AR2 is probably the worst offender. Grenades and other projectiles also still act as though they were thrown from the player's right hand.

I could use AllowFlipping "0" on some of HL2's weapon scripts to remedy the weirdness, although cl_righthand is a pretty niche feature for a HL2 context and I don't expect anyone who uses it with HL2 viewmodels to be bothered by it enough to warrant adding new weapon scripts for mods using Mapbase to account for.

With that in mind, I think this PR is ready

@Blixibon Blixibon merged commit eb2e8d5 into mapbase-source:develop Jan 23, 2021
VDeltaGabriel pushed a commit to Project-P2009/p2009_sdk that referenced this pull request Apr 27, 2023
…chirality

Enable Counter-Strike Source view model chirality in Mapbase
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[GAME] Support for Counter Strike: Source viewmodels
2 participants