Efficiently check if player's Camera CFrame?

I’m making an FPS game, and here’s how it works:

Sends server camera CFrame for raycasting → server checks if the camera pos is within a box attached to head → if is within the pos checks are pass and is used for raycasting

However, when the player moves around like (walks, jumps) the checks do not get passed. So, how do I easily verify the camera CFrame?

(the box is welded, not scripted to attach)

Is this for an anticheat? If so, I would not worry about that too much. I also don’t think this is the best way of checking for something like this, as there are two main options:

  1. The server script checks the box position, which would depend too much on the players lag.
    Player fires event → Latency while player moves → Server recieves event → Box position moved imbetween firing the event and recieving it.

  2. The local script sends the box position as a second parameter, which would remove lag as a factor, but would be easily circumnavigable from an exploiter. The exploiter would be able to hook the remote event and change the box position parameter to be valid.

Neither options work consistently enough to be worth it. Thankfully exploits are not massive issues right now, which makes our lives much easier.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.