NilesB said:
Explain to me why it makes sense from a security standpoint to put trapped levers in your dungeon.
It doesn't, trapped levers make sense only as a metagame constuct, and very little even as that.
Occasionally it does make sense. Not all the time-- probably not even most of the time-- but every so often it fits.
Sometimes the "trap" is caused by a malfunction of the lever's intended purpose. Maybe the lever is supposed to free a counterweighted pulley and raise the portcullis, but the pulley's axle is rotten, so when you pull the lever the whole mechanism comes crashing down on your head.
Perhaps the dungeon is a tomb, the final resting place of a king and his wealth. The builders intended the place to remain sealed forever, so anyone entering is assumed to be grave robber and therefore worthy of death. Some of the traps could be placed on attractive or interesting objects, like shiny levers and golden idols, so that greedy or curious intruders would activate them and get themselves killed.
For intentional traps in an inhabited dungeon, sometimes the affected area includes the lever, but leaves enough of a delay for an informed user to escape before it hits. E.g., there's a lever at the bottom of a long stairway, next to a shallow alcove. Pulling the lever releases a huge boulder at the top of the staircase, which rolls to the bottom in two rounds and crushes anybody in its way. This was intended to be a lookout station; if the lookout spotted somebody coming, he would pull the lever and dive into the alcove, and would be safely out of the way when the boulder passed by.
Occasionally, a trap will be designed for a specific lever-puller who is immune to its effects. Constructs are very popular for this. Stick a golem at the door to the treasure room, and order it to pull a lever if anyone tries to enter without saying the password. Pulling the lever makes it the center of a
fireball or
cloudkill or some other effect that will harm intruders but leave the golem unaffected.