Big red barrels are perhaps the most common trope in all of video games. You could see it as a crutch for developers, but it's part of the common language of games. A red barrel is as crucial to games as the jump button. Not every game needs it, but it's a comfort to the player when it's there. Removing this trope would be like removing the word "is" from a gamer's vocabulary. And no matter what your definition of "is" is, we can all agree it's a pretty crucial part of our world.
You might think there's some Freudian reason villains stockpile pressurized explosives and haphazardly spread them in every area of their secret lair. Some shrink might write a column about gaming tropes and try and convince you that criminals make unconscious errors in the hopes of being caught (or blown up). Well, there are no amateur psychologists here. I can assure you that Freud's whacky ideas have no merit when it comes to explosive barrels. There are legitimate reasons for these dangerous containers being in so many games.
Villains Never Go Green
Chair Entertainment's Shadow Complex takes place in a sprawling underground headquarters filled with barrels that go boom. If the whole place runs on gas-powered generators, then it probably consumes a small nation's worth of fuel every day. You'd pretty much have to have fuel barrels available throughout the facility to keep the gas-guzzling base running. You can't risk having your giant spider mech run out of petrol when a covert operative infiltrates your base.
Just how much gas is needed? The real-world monster truck eating Robosaurus has a pair of 20-gallon propane tanks just for shooting out fire. Imagine how much fuel is required to get a 48-foot-tall transforming dinosaur up and running. Shadow Complex's similarly effective spider mechs may not be quite as big as the 31-ton Robosaurus, but you can bet these bulky war machines get poor gas mileage.
You could chalk it all up to poor planning. Super villains tend to scrimp on hiring a good architect, which explains why it's so cumbersome to traverse a bad guy's headquarters. And these villains tend to hire inexpensive henchmen who don't understand that red is the international symbol for "Hey, this explodes!" and choose to nestle right next to these dangerous containers.
It's Not like You Can Drill for Oil on Mars
Id Software's games have always been known for their rich subtext. Set on a research facility on Phobos, one of Mars' moons, Doom is clearly a commentary on man's reliance on oil even as technology advances far enough to open portals to Hell. There are dozens upon dozens of idle barrels in this research station. Some are filled with toxic green goop (how else do you clean Martian dirt out of the carpet?) and others are full of oil. Yes, they use gas on Mars.