sentences:  During the Gothic era, several castles had to be either built or reinforced, especially along the border with the Kingdom of Castille.Compared to previous castles, Gothic castles in Portugal tended to have more towers, often of circular or semi-circular plan (to increase resistance to projectiles), keep towers tended to be polygonal, and castle gates were often defended by a pair of flanking towers.A second, lower wall curtain (barbicans) were often built along the perimeter of the main walls to prevent war machines from approaching the castle.