Medieval war machines were engineering marvels that played vital roles in historical battles. The trebuchet, a sophisticated siege engine, used a lever arm and counterweight to convert potential energy into kinetic energy, launching projectiles with impressive force.