# How does it really happen ? (Collison question)

This topic is 5150 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

What is the perfect way for collision of a player with other objects in an FPS game ? Is the player body made up of small meshes , joined together, and then collision is checked against the AABBs ? Or is there more to it ? I would be grateful if someone could direct me to useful information/explain me how this happens (FPS collision stuff) ?

##### Share on other sites
you don't need to be super accurate when doing player-player or player/objects collisions (exept if you want to check a rocket more accurately). Games use a single AABB for each player and collide the players like that.

You can do limb collisions if you want too, but unnecessary. There are no perfect ways.

for fast moving objects, and rather singular objects (bullets, grenades, rockets), you can model them as a single particle, and essentially do a ray/player mesh collision. a moving box against a mesh is quite costly, so if you can approximate the object to a point the better.

##### Share on other sites
Thanks, but wouldn't using a single AABB for a player make it unstable i.e it would trip easily and climbing stairs and stuff would be difficult ?

##### Share on other sites
yes, you have to fudge it. Use some kind of step-up algorithm, which would check if the player can be placed, say, 30 cm above where it should be.

related docs,

http://www.gamasutra.com/features/20010324/melax_01.htm

http://www.fluidstudios.com/pub/FluidStudios/CollisionDetection/Fluid_Studios_Generic_Collision_Detection_for_Games_Using_Ellipsoids.pdf

the second one involves two passes, once without gravity, the other adding gravity. Also, note that it's using ellipsoids, so more forgiving when you encounter a step.

##### Share on other sites
Wow! Thanks, the second document answers all my questions.

##### Share on other sites
I remember from somewhere that most games use [nonrotated] capsule shapes for player collision detection. This means that they can step up steps and they can rotate around without getting stuck in walls. Similarly, you don't get stuck to other players if you're all capsules and you can just use distance measurements between centres of the players to determine if you're gonna need to go to sphere collision.

Hope this helps;

//end rant
CJM

1. 1
2. 2
Rutin
16
3. 3
4. 4
5. 5

• 13
• 26
• 10
• 11
• 9
• ### Forum Statistics

• Total Topics
633722
• Total Posts
3013547
×