Should I just handle damage client side in my scenario?

Hello, so I’ve created this mechanic where lasers bounce of walls and head in the direction of the neareast player and players can also interact with these lasers, the lasers are created on both the server side and then the client side, they are anchored and I run custom physics simulation on both simulatenously, but I’m wondering since a humanoid’s health is replicated to the server, in the client physics simulation when a laser is close enough to a player, could I just deal the damage on the client side?

The way I like to think about it is how could an exploiter manipulate the system for the worst case result, and whether or not it will effect the fairness of the game. If you were to do hit detection on the clients side, assuming that the client sensing if it’ll be hit is themselves, an exploiter could easily disable or otherwise spoof the script and make it so they do not take damage.

If you are talking about having other players detect when a person gets hit however, this may cause latency issues as everyone is slightly out of sync with one another. You still also face the same issue that an exploiter could fake a laser here, causing somebody else to take damage.

1 Like