The middle period of Silla came to an end with the assassination of Hyegong of Silla in 780, terminating the kingly line of succession of Muyeol of Silla, the architect of Silla's unification of the peninsula. Hyegong's demise was a bloody one, the culmination of an extended civil war involving most of the kingdom's high–ranking noble families. With Hyegong's death, during the remaining years of Silla, the king was reduced to little more than a figurehead as powerful aristocratic families became increasingly independent of central control.