 The entire complex was surrounded by a moat twenty meters wide, which was saved by two drawbridges on the east and north flanks.The Aljafería remained without substantial changes until 1705, in which due to the War of Spanish Succession it was lodging of two companies of French troops that took to a regrowth of the parapets of the low wall of the pit effected by the military engineer Dezveheforz.But the decisive transformation as quartering took place in 1772 at the initiative of Charles III of Spain, in which all the facades were remodeled to the way in which the western one is presently, and that the interior spaces were used as dependencies for the soldiers and officers who were staying in the building.