Fixed rotation going out of bounds

Also changed everything to string instead of String