Slowing things down so you can think...
Sometimes when you are running a game, the players throw you for a loop, or turn left when you totally thought they would turn right. IT HAPPENS. There is no way to determine where the group will go... sure you could have a good idea how they'd react, but you'd never know all the time.
One of the tactics I often like to use while I think, is my slow down method. This method doesn't always work, but does work if your group doesn't always trust what they see in the game. In a game like AD&D 1E (and now even so in D&D 5E) the game is deadly & every turn could spell death if handled the wrong way. So... why not take advantage of said fear the players have for their characters, right?
What I love to do is place something out of the ordinary in a place they'd least expect it to see it or even something they may suspect is there.
They are in a dungeon, throw in an evil altar that has parts of skeleton bodies laying around, describing it to the cleric of the group as, "you feel the evil coming from the altar, to the point your stomach makes you feel real sick and you know it must be destroyed!".
This alone will buy you a ton of time as the group now fueled by the cleric to destroy the altar will be set in motion. The group will then start chatting about it, asking each other questions and if they ask you questions, give vague answers and let them deduct their own reasons behind things.
This whole time you can lean back, relax, munch on your popcorn, while you think about how you can get them back on track with out stopping the entire game for a break!
Don't like that idea? Okay...
Try this one, do your research before the game, grab some riddles or puzzles, convert them into something you can use during the game and allow the players to sit and talk about said riddle (or puzzle) you've presented them and if they answer correctly, it opens a magical door, and gee guess what? That door brings them back on track in your dungeon the way you wanted them to go. They can't see the map you have, and if anyone questions, you can always say, "This is D&D, not real life, maybe this dungeon is magical?"