Summary
In this chapter, we learned why the client-side hit detection is very easy to hack. We saw how some games require the player to lead their targets to account for lag. We then learned how we can alleviate this by rewinding potential targets before performing hit detection, so that players can aim directly at their target as expected.
With this technique, in combination with the methods for server-side movement code discussed in the last chapter, you have the tools you need for nearly hack-proof multiplayer games which will boost your overall player experience.