Mining, landmining or undermining is a way of attacking a walled city, fortress or castle during a siege. It has been used since before the Middle Ages. During the Middle Ages, mines or tunnels were dug underneath castles to let soldiers into the castle or to destroy the walls. Mining was used during World War I to try and break the stalemate of trench warfare. Soldiers tunneled under no man's land and put of explosives beneath the enemy's trench. On 7 June 1914, as part of the Battle of Messines, the Allies set off hundreds of tonnes of high explosive in 19 mines at the same time. About 10,000 German troops were killed.