Th3Ya0vi / vdrift-ogre

Automatically exported from code.google.com/p/vdrift-ogre
0 stars 0 forks source link

Better car collision shape #125

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
The attached image does a pretty good job showing what the problem is.

We need a better collision shape for the car. Right now it consists of multiple 
spheres calculated from the bounding box, which is awful.

Suggestion: Make a very low-poly (less than 100 vertices) mesh for each car, 
and use BtOgre to turn it into a btConvexHullShape.

Original issue reported on code.google.com by scrawl...@gmail.com on 8 Dec 2011 at 2:55

GoogleCodeExporter commented 8 years ago

Original comment by scrawl...@gmail.com on 8 Dec 2011 at 2:55

GoogleCodeExporter commented 8 years ago
Another reason why this is important: Due to the rounded nature of spheres, 
crashing into a wall feels way too "bouncy", which severly affects gameplay.

Original comment by scrawl...@gmail.com on 8 Dec 2011 at 3:53

GoogleCodeExporter commented 8 years ago
This on screen is because road wall (gray) has no bullet triangles, only road 
has. This because car rarely hits road wall from outside and we want to save 
collision cpu time.
So the error is not that huge, but sure it is there.

This needs tests first, if convex will give better collision experience than 
sphereshape (spheres are smoother, convex could give sudden jumps (collision 
response) when sliding and then (in next frame) overlapping another road 
triangle).

Original comment by Cry...@gmail.com on 16 Dec 2011 at 6:49

GoogleCodeExporter commented 8 years ago
I agree - car wall collision is too bouncy. But both have restitution at 0.0, 
this is probably solver's or shape's collision fault.
Surely we could improve this auto spheres location by putting their positions 
to each .car file.
I think even that if we decreased all spheres radius and set it for each car 
and tweak it to match car mesh that would suffice. But this means lots of game 
starts and checking which requires a lot of time and is tedious.

Original comment by Cry...@gmail.com on 16 Dec 2011 at 6:54

GoogleCodeExporter commented 8 years ago

Original comment by Cry...@gmail.com on 4 Mar 2012 at 7:34

GoogleCodeExporter commented 8 years ago
At least 2 new params for front and rear length pos.
or just all spheres positions in .car

Original comment by Cry...@gmail.com on 17 Jun 2012 at 8:49

GoogleCodeExporter commented 8 years ago
Front and rear positions in .car, much faster to tweak witch car edit save and 
reload. Fixed for cars in sim_com branch.

Original comment by Cry...@gmail.com on 23 Nov 2012 at 4:18