- Home /
How do you change the direction of gravity?
I'm looking to make a multiplayer game where each player has they own gravity. For instance; player 1 walks on the floor, while player 2 walks on the ceiling. but I just can't seem to find out how to change the direction of gravity for any particular character. Any help is appreciated.
Answer by Jeff-Kesselman · May 11, 2014 at 10:23 PM
What you need to do is disable the world gravity.
Instead, you have a gravity Vector3 in a script for each object. In the FixedUpdate callback you add that Vector as force to your rigid body
Your answer
![](https://koobas.hobune.stream/wayback/20220613144821im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
The faster my character goes the longer he jumps. 1 Answer
How to make telephone wires 1 Answer
Edit this script so that on the second jump change the gravity to 5 2 Answers
How can I make a game object move in parabolic motion as if it were under gravity? 2 Answers
Change direction of gravity for a specific instance of a prefab 1 Answer