In 1582, at the Battle of Yamazaki, Akechi Mitsuhide, who had killed Oda Nobunaga, was defeated by Hashiba Hideyoshi (later Toyotomi Hideyoshi). Driven back by Hideyoshi's victory, Mitsuhide took refuge briefly at Shoryuji Castle before dying while trying to flee toward Sakamoto Castle. Hideyoshi's triumph made this castle the stage for Mitsuhide's final days.