Rotating character when walking

Hi currently making a game in which the player can walk on the walls and ceiling, i am having my character wall walk by setting movement mode to flying when colliding with a wall and then rotating the sprite to put the feet at the bottom, my challenge however arises when trying to flip my sprite when walking up and down walls, how do rotators work, because just rotating the character 180 on the z axis doesnt seem to work.
Attached is how im rotating my actor when they collide with the walls floor and roof