István Thököly was accused of participating in the leading aristocrats' conspiracy against the Habsburg monarch, Leopold I, in 1670. Being concerned about his son's safety, he ordered Emeric to return to Késmárk. They soon moved to Árva Castle (now Orava Castle in Slovakia), which stood near the border of Hungary and Poland. The king's troops laid siege to the fortress and István Thököly died during the siege on 4 December. According to one version of the story of the siege, Emeric escaped from the fortress through a tunnel after his father died and fled first to Poland, then to Transylvania. Other sources say that his father had sent Emeric to Likava Castle before the siege of Árva began, and he fled to Transylvania after learning of his father's death.