Fixed overflow bug in register setting methods causing value assigns to not be wrapped around and overflow