i'm gonna go out on a whim and hope this helps because this is just my initial thought reading this:
Use an Area2D around the platform(s) you want to cling to, and use the space override to create a new gravity point for your character. Then make a signal for said Area2D node when you enter it to change the gravity point of your character. To make it a universal thing, you could also put the platforms into a group (i'd call it "MovingPlatforms" just for the sake of convenience), and make the signal call change the player's gravity origin for the group, rather than having to do it for each platform individually.
I hope that helps somewhat (；・∀ ・)