How could I do artificial / centrifugal "ring" gravity?

I don’t particularly care how “real to life” it is, but I’m trying to create a space station / torus ring, and I’d like the player and other misc objects/actors to have gravity along essentially the inside of a ring (pictured example.) -Most point gravity plugins I’ve seen allow the player to walk on any/all surfaces, which I do not want; I want the player and actor objects to have gravity applied only to the floor, or a force (say an invisible mesh ring) just outside of the exterior of the station. -There may be multiple ways of doing this, and I’m not apposed to purchasing plugins if they generally give me what I need. There doesn’t seem to be a comprehensive tutorial or explanation of this desired effect, even though many have asked for it specifically.

I imagine if I was to do the nodes for this myself (and again, I’m acknowledging there may be a myriad of ways to go about this…) I’d assume it’d be easy to replicate in the same vein of Mario Galaxy; static objects with the applied effect control/dictate the player’s gravity direction via each face, but it is possible to have other faces in the static object (or other static objects) not to have this applied effect and won’t effect the player’s direction; like walls in a hallway. Other static objects obstructing the gravity object also do not affect the player’s gravity direction. -And perhaps the gravity object has a certain distance you can be from the face before it’s effect wears off. (Again something prevalent in Mario Galaxy beyond your typical “round” planets, and to me, seems perfectly doable.

-I feel like this should be easier to implement than it is to explain, but I can’t find many helpful tutorials or plugins that relate specifically to this issue, despite it being a very popular question.

To summarize, I’d like gravity (or a force that simulates gravity well enough) to be applied in specific directions, likely dictated by faces on a mesh with an applied effect (as that makes the most sense for ease / control,) specifically that inside of a ring (as pictured,) and that force applies even through other objects (without the effect, static or actor,) that may be obstructing the affected gravity dictating object. Being able to change the strength of the force and range in which you’re affected by the force would be awesome too.

Seems like such a useful tool, but to me it seems this hasn’t been explained thoroughly. I’d really appreciate it if someone could explain or point me in the right direction. (I have little no experience with the coding side of ue4, I’m more familiar with nodes. Pics would be very helpful.) Thanks in advance for any help you can provide. -I’m asking this question for the benefit of others to; has gone fairly unanswered. Thanks x 1000.

1 Like

If I didn’t misunderstand what you asked, here are some screenshot of how to make a simple artificial gravity field that pushes objects outwards. But this one is not based on real life physics and just a simple example.
You can also use a capsule collision instead of a sphere like I did, and objects that needs to be affected by this artificial gravity have to simulate physics and generate overlap events.

That would work for physics objects, but it’s just a tip of the iceberg.

First, you also want to disable gravity for the objects, since with gravity they won’t be equally affected by the force. Or they will still slide down if the circle is horizontal.

Second, you may just use a Radial Force. Thus you won’t have to use Tick and calculate vectors for each object on tick, which would be quite expensive if there are lots of objects. Plus, it won’t work for Characters, since they don’t generally simulate physics, whereas Radial Force can affect Characters. (But, if you want to decrease the ‘gravity’ closer to the center as it would be in real world, Radial Force won’t do, because it can only decrease force the farther you are from it.)

Third, you’ll probably have to change the Character’s look angle limits and every now and then, probably on Tick, and set the movement method to Flying, I guess. Otherwise you won’t be able to walk on the ‘ceiling’.

I guess there’s a lot more hidden rocks to it. You really have to get into it and address one issue at a time.

Yes these are true, this is obviously not the optimal way to make it but will still work.
As you also mentioned, Radial Force will not apply a falloff on the force depending on the distance. And we also want to multiply the mass of the affected object with the force so it is even more accurate to real life.

The best way to make an artificial gravity in Unreal is probably working with C++/Plugins or using some external tool, blueprints are not that suitable to make complex physics simulations in my opinion.

I have seen a Directional Gravity plugin on the marketplace recently