Prosecutor Godot (goh-doh) from Phoenix Wright: Ace Attorney is obsessed with coffee, it being his "gimmick" of sorts. He often uses obscure coffee metaphors when describing his case, drinks up to seventeen cups in one trial day, has coffee served to him in a mug slid across the prosecutor's desk, does Spit Takes, and throws his coffee at Phoenix when things aren't looking so good. It's also worth noting that it was the aroma of coffee in his room what woke him up from his Convenient Coma.
In Case 4 of Trials and Tribulations, which is set six years before the presentit becomes very clear that Diego Armando is Godot when he starts making coffee metaphors to Mia.
It also ends up being an important symbol at the end of the game, as when he drinks his last cup Phoenix drinks one as well, indicating reconciliation.
In one point in the story of Super Mario RPG, you befriend an innkeeper, who lets you stay the night at her inn. When you wake up, she asks Mario how he's feeling, and you have two ways you can respond:
In Day of the Tentacle, Dr. Fred's hands are jittering constantly since he's on a continuous caffeine high. In fact, he drinks coffee all the time to avoid falling asleep, nightmares and sleepwalking, and hasn't slept for ten years! As a result, when you need him to fall asleep to solve a puzzle, all you have to do is pour some decaf into his mug, and that by itself is enough for Instant Sedation.
Francis York Morgan in Deadly Premonition relies upon coffee not just for a quick pick-me-up, but to predict the future. Hence the meme, "F...K! In the coffee!"
Coffee and caffeinated soft drinks also refill York's sleep meter, so it's possible for him to go the entire game without ever going to sleep outside of a cutscene. Then again, there are consequences to staying up too late...
In Harvest Moon: Animal Parade, the Wizard stays up until 2 AM, and is obsessed with stargazing. Not surprisingly, his favorite items are all coffee-related.
This could be true for the Scout in Team Fortress 2. In an early trailer, his motto simply reads "Too. Much. Caffeine." Plus, two of his unlockable weapons are energy drinks.
Forget the Scout. The Meet the Sniper video shows him, as the hours go by, drinking cup after cup after cup of coffee. Where else do you think the Jarate comes from?
Averted. It's decaf. Observe the video at around one minute in. The coffee pot has an orange handle.
It does still explain the Jarate, though.
Some casual flash games use coffee as their mode of energy-boost.
The fan game Space Quest Incinerations opens with Roger Wilco stumbling out of a broom closet in search of coffee. It isn't until he's caffeinated himself that he notices half the kitchen is missing thanks to his ship being under attack.
In the browser game Twilight Heroes, superheroes rely on sugar and caffeine to stay awake while adventuring at night.
There's a twist on this in Shantae: Risky's Revenge. In the first game, Shantae met a number of zombies, but they didn't attack her on sight and were as intelligent and as coherent as any human. Risky's Revenge reveals the reason for this: the zombies drink coffee, and the coffee makes them smart. If they go too long without coffee, however, they degenerate into mindlessly violent zombies. So in their case, caffeine really is a necessity.
In This War of Mine, some of the survivors are addicted to coffee, and their mood will go down if they can't get any.