And is there any way to remove the ability to capture Demon and Magic castles until Mythgard is taken? If you capture a Magic castle and then Mythgard, the quests for capturing the Magic castle and finding the Shroud of Deadly Shadows can no longer be completed. So, either simply block these two towns until Mythgard is captured, or add a check to see if the quest conditions have been met after the town is captured (if that's possible).
And is there any way to remove the ability to capture Demon and Magic castles until Mythgard is taken? If you capture a Magic castle and then Mythgard, the quests for capturing the Magic castle and finding the Shroud of Deadly Shadows can no longer be completed. So, either simply block these two towns until Mythgard is captured, or add a check to see if the quest conditions have been met after the town is captured (if that's possible).