Jump to content

  • Log In with Google      Sign In   
  • Create Account


Types of Character Controllers?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
5 replies to this topic

#1 Nemox   Members   -  Reputation: 119

Like
0Likes
Like

Posted 02 December 2012 - 09:53 PM

So I've made a ton of attempts at creating my ideal character controller, and I've got something at least functional. But it's messy and feels rather heavy-handed in many cases. But rather than go into detail about all my trial and error, I'd like to learn as a blank slate about what other people do.

What types of character controllers are out there? What shape are they, and how many raycasts do they rely upon? How flexible are they and what pitfalls do they have?
Are there some good rigidbody designs, or do most require manual interaction with physics?

Is the standard capsule collider a poor choice, or is it workable? UDK's looks interesting but I haven't figured out how to start analyzing it yet.


Your input would be most appreciated.


ADDENDUM: I suppose what I'm most lost on is how to best determine what the normal of the ground is a character is standing on. There can be many influences, but how to know what to choose?

Edited by Nemox, 03 December 2012 - 10:45 AM.


Sponsor:

#2 Steve_Segreto   Crossbones+   -  Reputation: 1460

Like
0Likes
Like

Posted 03 December 2012 - 11:30 PM

Check out the PhysX character controller, I think its one of the cooler ones :)

Many other physics engines also have kinematic character controllers, which are just user-defined shapes that move programmatically rather than according to the laws of physics.

When I was messing with one, I used two raycasts to avoid some corner cases where the physics system would jitter uncontrollably. I would ray cast from the top and center of the kinematic bounding volume.

There is also the possibility of using a rigidbody for a character, but i've heard it takes some tweaking to get it right.

#3 Nemox   Members   -  Reputation: 119

Like
0Likes
Like

Posted 05 December 2012 - 07:39 AM

I have been using a rigidbody with capsule collider to relative success, but to know what ground a character is standing on, I've had to rely on keeping statistics on every surface the character is colliding with, then I'd create a composite normal out of all ground-angled normals.

It works relatively well, but it feels heavy and messy, and still has its own pitfalls. Yet I see other games which seem much more simplistic when I play with them, and I want to achieve similar levels of elegance.

#4 Krohm   Crossbones+   -  Reputation: 2916

Like
0Likes
Like

Posted 10 December 2012 - 02:16 AM

Following this topic.

I have been experimenting with my character controller for a while and I'm still very unsatisfied. I have many issues.
  • It needs to fall down coherently with standard dynamic objects. (done)
  • It must have a much more fine-grained, script-controlled degree of collision filters (done)
  • It must behave accordingly to game-specific state. (done)
  • It must "not get stuck" (almost there).
For the time being, I'm using full sweeps for arbitrary convex shapes. Raycasting does not appear sufficiently robust for my generic controller. I still wonder how a capsule controller can be a generally good solution.
Character controllers as in Bullet does not appear much of a use to me. Don't get me wrong, they're still better than nothing. I keep reading about the PhysX controller, I should probably have to look at it soon.

In the meanwhile, if we can mash up something here, I'd be glad to all of you.

Edited by Krohm, 10 December 2012 - 02:16 AM.


#5 Ravnock   Members   -  Reputation: 286

Like
0Likes
Like

Posted 10 December 2012 - 05:17 AM

Nemox do you use a mesh for the physics and another for the render?

#6 Steve_Segreto   Crossbones+   -  Reputation: 1460

Like
0Likes
Like

Posted 10 December 2012 - 01:53 PM

If your character controller is getting stuck in acute corners or other geometry above the (x,z) plane, you can use a few simple raycasts (from the hip and head of the controller). These extra raycasts supersede entering the swept sphere (ellipsoid) collision detection/response algorithm and can also prevent jittering.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS