by the end of the 14th century, the castle bailey was primarily occupied by the local county administration. it was used extensively as a jail, with prisoners being kept in the various towers around the bailey. the old castle-guard system for securing the castle had changed into a system whereby the crown used rents from local royal lands to hire local guards for the castle. increasingly, royalty preferred to stay at the franciscan friary, between the castle and king's staith on the ouse, while their staff resided at st mary's abbey and st andrew's priory in the fishergate area.