In godot the characterbody2D node type can handle slopes well. Increasing the value of floor_snap_length determines how strongly a grounded player will be prevented from walking into the air on slopes.
Cool, I didn't know that! Unity is much worse at handling slopes. However, the stairs to the attic are impossible to jump on, while the ones to the basement work just fine.