Sliding working up hill when its not supposed to

That’s the return value of the function, but where is the math that affects the characters velocity?

Edit: to elaborate a bit, the bp function you posted returns a vector that is pointing ‘down’ perpendicular to the surface up normal with its magnitude scaled depending on the angle. So if its not working I would assume the issue is where the return value affects the characters velocity.