Answer
George II Rakoczy, the ruler of Transylvania, joined forces with Sweden and Russia to invade Polish territory during the reign of John Casimir. This invasion was part of a wider conflict known as the Second Northern War, which involved several European powers vying for control and influence in the Baltic region.