Re: Kinematic Collision

Juan Linietsky <[email protected]>
Newsgroups gmane.games.devel.algorithms
Message-ID <[email protected]>
What you are describing is usually the standard way of handling a character
through a level, or at least what it used to be standard up to a few years
ago. I'm not sure if i'm solving your problem, but at least i'll try to
share some experience:

Nowadays, physics engines can handle this in 2 different ways

1) The way you propose, plus usually a "solver" check if your character
ended up embedded (may always happen.. ) so it ends up unembedded. This
results in very "correct" character motion, but with poor interaction with
other dynamic objects.
2) Under a physics engine, you can treat your character as a rigid body with
infinite inertial tensor (0 inverted) so it can't rotate (stays straight all
the time, and just solve the contacts as you would solve any rigid body
(applying force and remving friction while it walks, etc). This works pretty
well except for a few side effects i'll commend below.

The second way has some extra problems to solve:

a) Characters or other objects can go through floors if moving too fast,
this can be solved by using CCD, raycasting from the support in the
direction it's moving, or use binary steps with the swept motion volume to
the point first intersecting.
b) Characters can slide slowly in ramps (not stay still).. there are many
small ways to fix this, the one i like the most is disabling gravity on our
character if you are not moving your character for a while and it stays n
floor, or you can just reenable friction when your character is still (you
are not trying to move it).
c) Characters may bounce when falling from too high or at high speed, this
can be fixed either hacking the solver,or using the raycast mentioned in (a)
to preapply an impulse that decreases the impact velocity. Also, i noticed
techniques such as split/accumulated impulses described by erin catto help
this scenario.


Cheers!

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july

_______________________________________________
GDAlgorithms-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gdalgorithms-list
Archives:
http://sourceforge.net/mailarchive/forum.php?forum_name=gdalgorithms-list
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.