First person body melee attacks glitch because of left leg hitbox ?

Cheo

Active member
Hello, I'm afraid there is an issue with the first person body melee system : I was getting some incorrect result with a custom character (his fists often collided with the target but had no impact effect) so I used the Nolan character from the demo scene to make some tests and by adding a debug line to the melee weapon script I realized that his left leg hitbox was responsible for apparently all impacts, and most notably when placed on top of a giant crate prefab it became obvious that even when looking above it was somehow possible to damage the crate at the character's feet !
Could you please make a similar test and confirm whether you have the same problem ? Thanks in advance !
 
I can't reproduce this in the demo scene. There's no difference in collider side with the left leg either, so not sure what you're seeing there. What are you logging? And what do the colliders look like?
 
Hi, thanks for your answer, I created a new project to be sure and took a quick video to show you the issue :


Here's the simple debug line I added to the HitCollider void from the MeleeWeapon script :
Debug.Log(" hitbox : " + hitbox.Transform.name + ", hitGameObject : " + hitGameObject.name + ", hitCollider : " + hitCollider.transform.name);

May I ask you to try again what I did in this video ? I would be really surprised to be the only one with this issue :0
One last thing : the right leg collider has an object identifier of 24 - but adding the same to the 3 others changed nothing, there doesn't seem to be anything off about them.

Capture d’écran (406).png

Capture d’écran (407).png

Hope this was helpful !
 
That was helpful. This is because of the Minimum Y Offset on the First Person Melee component. If you change that to .3 it will fix the issue. I'll change it for the demo scene as well.
 
Top