The Theory Behind First-Person Hitboxes

Choosing the right hitbox is key to making a great shooter. Here’s the difference between them and why they matter

Ayran Olckers
Level Up Coding
Published in
13 min readMar 13, 2020

--

Counter-Strike updated hitboxes

Almost all modern games simulate physics in some way. From the most basic collision in a roguelike to the complex calculations powering simulations like Kerbal Space Program, if you want to build a 3D game, you’ll need to make the world feel solid. This is why your game needs hitboxes — the industry term for the physicality of a virtual object.

Figure 1: Hitboxes for CS: GO players are built from several capsules to closely match the character model because the emphasis is on accuracy rather than speed of movement.

A hitbox is the representation of a shape that can’t overlap with other hitboxes. The world has a hitbox, each player has a hitbox, the scenery, the houses, almost everything you can see and ‘touch’ in a game has a hitbox. To give the player a sense of realism, they have to be stopped from walking straight through that object, and will often see a physical reaction when two objects connect — bouncing is a common effect of a collision between hitboxes.

--

--

🎮 Build Pipeline Engineer in game dev | Passionate about coding, gaming, D&D, and MTG. Crafting game magic behind the scenes. 🛠️🐉