The Acts of Union occurred in 1706 and 1707 that created the UK - Scotland and England.
They will have to change the flag if Scotland goes.
If Scotland did become independent, would they be a republic or would they choose as king the person with the best genealogical claim to the throne? I think that would be one of the Wittelsbachs of Germany.