Complex sentence: Cockburn had vowed to destroy any town which showed resistance; when the admiral saw an American flag flying over Havre de Grace and shots were fired from the town, he planned his attack.
Split into simpler sentences: Cockburn had vowed to destroy any town which showed resistance. When the admiral saw an American flag flying over Havre de Grace and shots were fired from the town, he planned his attack.