well it has to be before input otherwise you get the rubberbanding when you set their position back
we’re doing it on input so we do know exactly where the player will be, ie if the play inputs forward we trace forward, if he moves left we trace left, you can multiply this by its velocity to check how far to trace
you can use a capsule trace to test the ‘ledge hole’ size
if you want to move along the ledge you can just alter the input vector. so if the player presses forward and its a ledge we can rotate that vector to left and he’ll move along the ledge BUT this would require another trace in case there is another ledge. id just block the input myself