# Have forces affect character controller

**URL:** https://discussions.unity.com/t/have-forces-affect-character-controller/397150
**Category:** Physics
**Created:** [August 27, 2009, 8:37pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150 "2009-08-27T20:37:42Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![Discord](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/discord/32/568561_2.png) [@Discord](https://discussions.unity.com/u/Discord)
#### Post date: [August 27, 2009, 8:37pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/1 "2009-08-27T20:37:42Z")

</div>

I’ve looked through the forums, and there are a number of threads that go over how to have a character controller push a box around. But I want a box to push the player around. As in: You are walking straight across a platform in the sky. A number of boxes are moving back and forth and if they push you off the platform, you lose.

I’ve tried putting rigidbodys on the boxes and setting them to isKinematic, I’ve tried moving them through their transform, I’ve tried moving them using AddForce, and nothing affects the character controller? Anyone know how I should do it?

---

<div class="post-metadata">

### Author: ![jmunozar](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/jmunozar/32/44194_2.png) [@jmunozar](https://discussions.unity.com/u/jmunozar)
#### Post date: [August 27, 2009, 8:44pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/2 "2009-08-27T20:44:53Z")

</div>

Hello,

If you are going to move a character controller what you can do is to use the CharacterController.Move()

so what you can do is to detect the collision with the box, and then call the CharacterController.move function and apply it to the character 🙂

I dont know another way to move the character controller ☹

Hope it helps you! 😉

---

<div class="post-metadata">

### Author: ![Discord](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/discord/32/568561_2.png) [@Discord](https://discussions.unity.com/u/Discord)
#### Post date: [August 27, 2009, 9:37pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/3 "2009-08-27T21:37:46Z")

</div>

I would do that but the character controller doesn’t call the regular OnCollisionEnter() function. Which is very inconvenient.

---

<div class="post-metadata">

### Author: ![jmunozar](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/jmunozar/32/44194_2.png) [@jmunozar](https://discussions.unity.com/u/jmunozar)
#### Post date: [August 27, 2009, 9:56pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/4 "2009-08-27T21:56:36Z")

</div>

I was talking using OnCollisionEnter on the boxes :P,

but if you want to use them from the Character Controller, then you could use

> **[Unity - Scripting API:...](https://docs.unity3d.com/ScriptReference/CharacterController.OnControllerColliderHit.html)**

🙂

---

<div class="post-metadata">

### Author: ![Discord](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/discord/32/568561_2.png) [@Discord](https://discussions.unity.com/u/Discord)
#### Post date: [August 27, 2009, 10:25pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/5 "2009-08-27T22:25:08Z")

</div>

Oh, I meant using it on the boxes as well. I believe it doesn’t register OnCollisionEnter(), only OnTriggerEnter(), but I could be wrong. I may be able to use either one.

---

<div class="post-metadata">

### Author: ![Discord](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/discord/32/568561_2.png) [@Discord](https://discussions.unity.com/u/Discord)
#### Post date: [August 28, 2009, 9:16pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/6 "2009-08-28T21:16:46Z")

</div>

Ok, I’m still can’t get this to work? Any more suggestions?

---

<div class="post-metadata">

### Author: ![flaminghairball](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/flaminghairball/32/427040_2.png) [@flaminghairball](https://discussions.unity.com/u/flaminghairball)
#### Post date: [August 28, 2009, 9:54pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/7 "2009-08-28T21:54:42Z")

</div>

Have you looked into using the Rigidbody FPS script on the wiki?

---

<div class="post-metadata">

### Author: ![Discord](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/discord/32/568561_2.png) [@Discord](https://discussions.unity.com/u/Discord)
#### Post date: [August 29, 2009, 5:39pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/8 "2009-08-29T17:39:47Z")

</div>

Yes I have. I was originally using the rigidbody fps walker actually, but there is a problem with it. You can go up straight vertical walls by running towards the wall and holding the jump button. which is a problem for the game I’m working on.

---

<div class="post-metadata">

### Author: ![Discord](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/discord/32/568561_2.png) [@Discord](https://discussions.unity.com/u/Discord)
#### Post date: [August 31, 2009, 4:55pm UTC](https://discussions.unity.com/t/have-forces-affect-character-controller/397150/9 "2009-08-31T16:55:04Z")

</div>

One last bump before I just go back to using the rigidbody fps walker.
