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

Weapon holding #217

Merged
merged 5 commits into from
Aug 17, 2023
Merged

Weapon holding #217

merged 5 commits into from
Aug 17, 2023

Conversation

Fueredoriku
Copy link
Contributor

@Fueredoriku Fueredoriku commented Aug 16, 2023

genericIKFinalFinal

@Fueredoriku Fueredoriku changed the base branch from main to dev August 16, 2023 00:17
- Generalized IK functionality
- All body augments updated with grip target
- IK tuned with offsets
- IK now functions as 2 bodies instead of 1
@Fueredoriku Fueredoriku linked an issue Aug 17, 2023 that may be closed by this pull request
@Fueredoriku Fueredoriku marked this pull request as ready for review August 17, 2023 00:17
Copy link
Contributor

@toberge toberge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Much better than floating guns, but the elbow joints don't seem to move in a sensible way, the arm flips when you aim downwards, and the gun clips through your shoulder:
image

The reload animation makes it look a little odd as well:
image

And solar + crosshat... what is he holding?
image

Same problem with dancer + shotgun:
image

Assets/Scripts/Gamestate/PlayerManager.cs Show resolved Hide resolved
Assets/Scripts/Utils/GenericTwoBodyIK.cs Show resolved Hide resolved
@Fueredoriku
Copy link
Contributor Author

I tweaked the hand bone to rotate better with the gunbodies. 😁👍
The rest of the visual quirks either require more computations than they are worth / some would require manually implementing constraints.

Most of this can be mitigated in the current system should future problems arise by further tuning provided offset values, existing animations, or even updating some of the gunbodies to have better scaling or dropping two-handed carrying if we decide we don't want arm clipping through body at all.

A fix altogether could be to have different models in first person compared to what others see, which would make for less extreme gun position distances relative to the player. This feature would also inherently solve a lot of the other aforementioned quirks, but we'll have to evaluate if such a feature should be prioritized later 😅

For now I'll merge this in!

@Fueredoriku Fueredoriku merged commit bd40072 into dev Aug 17, 2023
@Fueredoriku Fueredoriku deleted the feat/weapon-holding branch August 17, 2023 22:37
@Fueredoriku Fueredoriku self-assigned this Aug 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done 🎉
Development

Successfully merging this pull request may close these issues.

Fix aiming edgecase
2 participants