Over time, as codes of law sought to control violence within groups, so did philosophers, clerics, and statesmen seek to regulate the  destructive power of war. The concept of a "just war" emerged, suggesting that war is justified only when it meets certain preconditions: if it is waged as a last resort or in self-defense; if the force used is proportional, and if, whenever possible, civilians are spared from violence.