How to tell if something HITS a charactercontroller?

So it seems character controllers will ONLY do collision detection if they are moving, and they will only detect in the direction they are moving.

alt text

You can see it works fine when I run into the object, but when the controller is idle, it does no collisions at all. As shown, I would like it to collide+be pushed by objects when not running directly at them.

How can I make it always check for collisions? Thanks!

Yes, this is a known thing … lots of older discussions (why it works this way, ways to fix) if you search “unity charcontroller collision” and things of that nature.

The basic issue is that charControllers are not rigidbodies, so the system does not push them around. The way they slide off of things when they move is actually specially added to their own move command. Interaction with moving objects is usually hand-done (moving platforms, grab a swinging rope… .)

Can switch to a rigidbody on the player. Lots of work. Do this only if many things will be knocking the player around in “realistic” ways.

Depending on the problem, using OnCollisionEnter/Stay on the player and on the objects hitting the player can help. Since the player’s fake capsule collider does count as a collider. Try it and see when they fire. Then you have to math-out the proper way to shove-move the player.