- Home /
Possible to create axis centered gravity?
I suppose that little question may be confusing, so let me explain.
Most video game physics takes for granted that you are on the surface of a planet, or something similar, so gravity every where on the map has the same vector.
But I want to make a simulation of a space craft, based on realistic technology. In space, obviously there is no gravity, so on a space craft it must be simulated if you want any. My space craft in particular makes use of centripetal forces, where the personnel area of the craft is a spinning drum, and people walk around the curved surface of the drum.
The effect I need, in short, is that gravity "flows" outward from an axis of rotation. So say the z-axis is the axis of rotation, everything would try to fly away perpendicular to it.
Is this possible?
Example, this spacecraft from the movie "Mission to Mars": https://www.youtube.com/watch?v=a8V6jTW3xTQ
Answer by HammockHead · Dec 13, 2012 at 02:22 AM
you could disable gravity, then use ray cast to determine the direction the center of gravity is relative to your object then add force in that direction
Your answer
![](https://koobas.hobune.stream/wayback/20220613085341im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
simple game spinner 0 Answers
How to rotate a ship based on gravity around a planet? 1 Answer
How can i rotate tyhorugh local axis? 1 Answer
Spinning a sphere, like a globe. 1 Answer