This question was asked a lot in scripting support before. They mostly have this as the answer:
Client:
- smooth
- more accurate
- performant, removes weight from the server
- vulnerable to hackers
Server Sided
- Inaccurate sometimes with positioning and hit detection
- exploit protection
-
Does “accurate” only apply to fighting npc? Its client → server → client, so client hitboxes should be accurate for the attacker. But it’s attacker’s ping + opponent’s ping for the person getting hit. Does that mean players could get hit after dodging, and the game becomes unplayable if the attacker is lagging? How do big battlegrounds/fighting games do it?
-
Should hitboxes be handled on the Client or Server in my PVP/PVE game? - #2 by KJry_s
Distance check on the server sounds like hitbox detection (or player distance) on the server. If you do it on the server why also do it on the client?
The reason Im posting this instead of bumping another thread is becuase I’m not asking generally. I’m doing a looping Overlap Params on the server. The overlap params is correct & works regularly, but messes up & attacks multiple times when the attacker is moving & doing m1 combat. I think its becuase of the time it takes for remote events to send because theres no issues with the overlap params.
I did overlap params because it’s the fastest, but does looping it defeat the puropose of performance? Should I do the hitbox on the client or do regular raycasts in the shape of a box on the server.
(I tried the raycast hitbox module theres a delay between the moving attachments & the following rays hitting & doing damage)