I had a brief thought earlier today "it would be neat to make a game where the gravity kept changing, like you would walk along a straight path that curves up and over in a loop-de-loop" and out of boredom I decided to look into how this would be done in Unreal Engine and Godot.
In Unreal Engine it looks like they've hardcoded the X and Y values for gravity direction, and you can only change the Z, i.e. the strength of gravity. the built-in gravity will always be one direction. It's an FPS game engine y'know. So you have to re-invent gravity yourself. One way is to calculate the direction towards the center of an object (maybe a small planet) and then apply a force in that direction.
Godot is just like lol here is an Area3D volume one of its parameters is gravity_direction it takes X, Y and Z now stop bothering me I'm on the phone yeah sorry babe it was my younger sibling I have to watch them
