In 1482 he played an important role in the conquest of the fortress of Alhama de Granada, belonging to the Moorish Kingdom of Granada, and in 1483 in repelling the attacks of king Boabdil on Lucena, a town in the province of Cordoba, held by the Kingdom of Castile.