If you look here:
Then you'll see that the position is actual an offset in global coordinate space.
Personally I only use
apply_impulse but I assume (also according to the old Godot 2.x related post above) that
add_force works in a similar fashion. (Sadly, the docs are sparse for
You get the global offset for a child object like this:
$MyChild.global_transform.origin - global_transform.origin (I omitted the
$"." to the second
global_transform adressing the "parent" itself as it is not needed here.)
Keep in mind that the force vector itself is in global space.
Here also some info about
add_force by kidscancode:
If you run into problems here then consider using
apply_impulse instead repeatedly from inside
_physics_process. Multiply the force by
delta so the multiple impulses add up to the force over a second. The advantage is that these impulses can be adjusted in position and direction every physics frame.
I also tried to post some info here. (It contains some text about
apply_impulse but not