How to Limit View/Rotation on my player character?

example, im doing the same thing, though im having issues with my pitch clamping at the moment :