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

Bullet raycasting against ped's body parts #46

Closed
in0finite opened this issue Oct 12, 2019 · 3 comments
Closed

Bullet raycasting against ped's body parts #46

in0finite opened this issue Oct 12, 2019 · 3 comments
Labels
feature New feature priority:high This issue is of high priority weapons

Comments

@in0finite
Copy link
Owner

in0finite commented Oct 12, 2019

Bullet raycasting should not be done against CharacterController (capsule collider), but against ped's mesh. The problem is that there is no way to raycast against skinned mesh. The best solution seems to be attaching colliders to each body part, and raycasting against them. This creates additional problems. Should these colliders be the same for all peds ? Or should they be generated at runtime based on ped's model (which adds performance costs) ?

This is needed for:

  • Detecting which part of body was hit (so that damage can be applied accordingly).
  • Precise shooting - capsule collider doesn't match ped's body.
  • Damaging ped while he is in vehicle - currently, there is no way to kill ped while he is in vehicle. In original game, you can shoot ped at the head while he is sitting, and you can shoot him while he is doing drive-by (?).

This issue is related to #34, which also needs colliders attached to each body part.

@in0finite in0finite added feature New feature weapons labels Oct 12, 2019
@slapin
Copy link

slapin commented Oct 12, 2019 via email

@in0finite
Copy link
Owner Author

Yes, he does. That's why I referenced other issue. Still, it's not clear if it can be done at runtime, and how much time it takes.

@in0finite in0finite changed the title Precise bullet raycasting Bullet raycasting against ped's body parts May 3, 2020
@in0finite in0finite added the priority:high This issue is of high priority label May 4, 2020
@in0finite
Copy link
Owner Author

Done as of commit 8365939.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature priority:high This issue is of high priority weapons
Projects
None yet
Development

No branches or pull requests

2 participants