William is lucky that the branch of the royal family that the current royals descend from is not the James II descendants. James was the Duke of York before he became king. New York state and NYC is named after him, and as Duke he was the head of the largest slave company that ever existed in the British/colonial American world.
William’s mother Diana supposedly is descended from James II via an illegitimate line of ancestors.