Older Than Steam: Don Quixote has filled his head with the "damnable books of Romance" (what would be called knightly adventure stories in the modern sense) and is convinced that the world works that way. He promptly sets out and attempts to fight monsters, rescue damsels in distress, and so on, and everyone concludes he's dangerous and insane.
There is a having Portugal as the setting of Madame Bovary named Primo Basílionote Cousin Bazilio, written by Eça de Queirós, that has almost the same plot. But the ending is very different: the Madame Bovary's expy, Luísa, is blackmailed by her own servant who threatened to reveal to her husband and is driven to get a stress-induced disease. She deeply regrets having betrayed her husband, has to shave her head, which in an Brazilian TV-adaptation was considered one of the most tearjerking moments of the history of Brazilian TV, and ultimately dies. There is no Power of Love to save her, there is no Black Comedy like the original, only pure Tear Jerker. In the last scene, Basílio, the eponymous adulterer is shown that he didn't care with Luísa and he should have brought "Alphonsine", making him THE biggest JerkassKarma Houdini of the entire Portuguese-language literature.
In the climax of Martin The Warrior, where the Big Bad slams the LancerChick Rose into a wall when she attempts to jump him. She is immediately dead as it broke her neck. Likewise, when Martin disarms said Big Bad, he wastes no further time on him and kills him while he is still on the ground.
In the original novel, the Anti-Villain Sela The Vixen comes to sell intelligence to the Redwallers outside the castle walls. She is instead met by his aide-de-camp, Constance The Badger. The transaction is over right and there, with Constance nonchalantly knocking Sela out and taking the papers with her.
In Mattimeo a gang of slave traders disguise themselves as entertainers to sneak into Redwall Abbey and abduct the children (for underground mining labour). At an ensuing festival inside the abbey grounds, they manage to spike all of the partygoers' drinks, and get them to drink them at the same time by calling out a toast. All seems to be working according to plan. It turns out that the cooks and kitchen aides naturally didn't drink anything, and try to stop the slavers by themselves. The slavers, on the other hand... simply beat them up/slaughter them and calmly proceed loading the unconscious on their cart.
In Retribution Falls the heroes find the legendary pirate port Retribution Falls to be exactly what a city built by pirates would be like: a badly built Wretched Hive.
In War of the Dreaming, there is an scene where a Beatrix-Potteresque Mouse shows up to rescue one of the heroes. Then the setting changes back and Mouse promptly gets stepped on.
James Patterson has this as a side effect of the Author Tract in Cross Country, Alex Cross's ex girlfriend gets brutally murdered by an African mercenary. He heads to Africa. The second he gets out of the airport, he's kidnapped. By the police. Then it gets worse. You could cut out several hundred pages from the middle of the book, and all you'd miss would be the Author Tract and Reality Ensuing, over and over again.
In Brothers of the Snake, Apothecary Menon wanders around a village with suspected Chaos cultists with his helmet's faceplate up. For a good reason, mind, as the daemon his squad is hunting is invisible to helmet sensors and can only be seen with the naked eye. Unfortunately, when he gets into a fight with said cultists, he takes a bullet in the face and dies.
Used numerous times in Changes, nearly always as yet another way to horribly torture Harry. Example: the Red Court sends in assassins to take him out. Rather than attacking him directly the way that, say, the gruffs did, they pay lesser thugs to try to kill him over and over, then set his house on fire. He barely manages to get his elderly neighbors out... then falls off a ladder and breaks his back, leaving him paralyzed. He has to make a Deal With TheFair Folk to fix it.
In the short story Day Off, Harry goes home to find a group of weak-talented wizard wannabes waiting outside his home. Apparently, Harry dispelled a bad luck curse they'd placed on some lady (which was so weak that Harry was mostly convinced wasn't real, and dispelled it to give her peace of mind). They sneer and threaten him, with the leader demanding that Harry prepare to defend himself, before he and his posse begin gathering their power to attack him. Harry responds by shrugging, drawing his .44 revolver, and pointing it at them. At their shocked disbelief, his response is "I'm a'fixin' to defend myself."
The Archive is incredibly powerful, able to hold her own against any number of opponents. However, in Small Favor, she is subdued because she is also a little girl and can be knocked out by gas even more effectively than an adult.
This is why Necropolis is a Bittersweet Ending. The heroes technically win and successfuly defend Vervunhive, but the city is so horribly damaged by the fighting that it's no longer livable, forcing the survivors to either become refugees to the planet's other cities or join up with the Imperial Guard.
Traitor General demonstrates why Helmets Are Hardly Heroic is a bad idea. You may be a Super Soldier with systems able to resist even the horribly deadly poison that coats the arrows being fired against you, but that doesn't work when dozens of those arrows are fired into your unarmoured face.
In His Last Command, this is how a scout takes down a stalker, an Implacable Man that can soak up ridiculous amounts of damage and keep coming. Chaos enhanced beastie or no, it's still an animal that can be paralysed by hamstringing and slain by getting shanked in the brain through the base of the neck.
In The Witcher Saga Geralt tells a story about when he was young, he wanted to pose as a knight when dealing with thugs mugging a merchant and his daughter. The downright brutal method he used to dispatch the thug's leader ended in daughter fainting from horror, and merchant running away from him along with the bandits.
In Wearing the Cape, Hope/Astra is given a lesson in momentum and force and why it's a good idea to know how tough something is before you fly yourself into it like a missile. The book is actually full of little reality-checks, like superheroes getting warrants before going after supervillains, villains whose lawyers get the charges dropped, and strangers committing random acts of badness.
At the end of Brandon Sanderson's Mistborn, they kill the Big Bad who betrayed the hero of ages past, stole the power of the Well of Eternity for himself, dislodged the Earth from its proper orbit, brought up volcanoes that constantly choke the air with ash, created a permanent underclass of slaves, and turned HIS OWN FRIENDS into monsters. Good riddance, right? Well, no. The second book then details the political consequences of such a sudden power vacuum, and trying to go from a totalitarian dictatorship directly to a constitutional monarchy (hint: a lot of people die.)
In On Basilisk Station, the Bronze Age-tech Medusans manage to brutally kill some Manticorans by surprise and swarming them. Then, the Manties bring out the heavy weapons and air support. The aliens die. And die. And die some more.
The Grav Lance is a powerful experimental weapon. That also means it is unreliable.
Gutting the ship's regular weaponry to accommodate the experimental weapon leaves it undergunned when it is forced to confront an enemy vessel and although our heroes win the encounter, it's not without very serious casualties and the ship is so badly damaged it must be scrapped.
A major B-plot in Honor Among Enemies has a New Meat technician bullied by a crooked crewmember, beaten up and intimidated. Scared to testify, he instead accepts an offer to train with the shipboard marine company, ultimately standing up to the bully, bringing him down in a fair fight and exposing all his evil schemes. The seriousness of these schemes earn him some leniency three pages later when he's being busted for fighting on duty.
The Solarian League, having been at peace for centuries, butts in on the Manticore-Haven conflict, whose participants have been in a sustained Lensman Arms Race. The asskicking that follows is surprising to no one but the interlopers.
Losing large numbers of crewmen in a battle will result in a board of inquiry and will make the rest of the navy reluctant to serve with you, no matter how charismatic you are or how often you get results. Political connections become meaningless once you become a liability to your patrons.
The Discworld books play this for equal parts comedy and drama. Among other things, characters frequently react realistically to outlandish situations (in Going Postal, after tricking a banshee into getting killed by a malfunctioning sorting machine, the protagonist is too busy being ill to shoot off a Post-Mortem One-Liner), and the narrative often points out that happy endings in "real life" are never as simple as they are in stories (at the end of Monstrous Regiment, the protagonist and her companions end up stopping the war between Borogravia and Zlobenia, but some months later in story-time the ruthless ruler of Zlobenia just tries to start another war). Complicating things is the influence that narrative causality has on the Discworld, making the line between "reality" and "fiction" as blurry as it gets.
There are a number of points where the protagonists forget basic things as a result of their panic at a situation. A prominent example is in the first book, when Hermione is so freaked out at the sight of Harry and Ron being strangled by the Devil's Snare that she forgets that she can use magic to save them. This is given a callback in the last book, when they are trying to get into the Shrieking Shack via the tunnel by the Whomping Willow. Ron panics because there's apparently no way to freeze the tree, prompting Hermione to remind him that they can use magic.
In the Big Bad's backstory, his mother fell madly in love with a non-wizard, so she subdued his mind with magic and had him run away from home and have a baby with her. Somewhile later she decided that she could stop using magic, for he would certainly remain at her side on his own volition, if not out of love, then for the sake of their child. Turned out that Mind Raping (and then just raping), abducting and subjugating people through occult means tends to build up quite a bit of resentment in them.
At the end of the book Across the Universe, Amy and Elder stop the dumping of drugs into the water, which means that the population of Godspeed is no longer doped up into being compliant. In A Million Suns, we see that this does not lead to an automatic happy ending. Instead, there are riots, strikes, suicides, and panic attacks, as a large number of people suddenly find themselves having to deal with emotions and thoughts that they never experienced before.
In the Black Prism, the main character's friends and love interest run from an attack very early in the book. Arrows fly after them, and the main character's power manifests just in time to redirect the arrow from his love interest... only to have two more arrows pepper her back and kill her.
In the second Artemis Fowl book, a gangster attempts to kill Holly by firing a laser gun from the hip... and ends up missing with every shot.
What happens when a boy king who is steadfast and forthright and honorable in all things makes war against a seasoned commander decades his senior, who has armies that outnumber his own and sees honor as a polite suggestion? He loses. Of course he does. Honor does not win nearly as many allies as carrot-and-stick realpolitik.
Like Father, Like Son. What happens when a man with a reputation for honor and incorruptability takes a position of leadership in a corrupt royal court? He fails spectacularly. It turns out that being the paragon of simple straightforward virtue does not equip you with the skills necessary to survive in a Deadly Decadent Court. Nor, for that matter, does it help you determine who you can really trust and who won't just sell you down the river to save their own necks.
He also assumes that a decree issued by King Robert minutes before his death will grant him temporary power and protect him. Queen Cersei simply tears up the piece of paper and orders Stark seized by troops loyal to her house.
Also very Like Father, Like Son; when Jon Snow signs up for the Night's Watch, expecting a jovial brotherhood of honest men ready to defend the realm, he's more than a little disappointed by the dwindling patrol of old men, green boys and apprehended criminals he finds there. The same thing happens when the Night's Watch ride it in force beyond the Wall, most of them getting killed or defecting and when they elect Jon Snow as Lord Commander, which forces a teenaged boy to make several very tough choices.
In the War of the Five Kings, the Stark/Tully alliance who are easily the most just and honorable houses in the Seven Kingdoms must command universal respect, right? Wrong. Their levies don't have any stake in their lord's quarrels and like to rape and plunder as much as the next army; the smallfolk hate them just as much as the Lannisters.
Oberyn Martell stands as Tyrion's champion at his (second) Trial by Combat and spends the first half of the fight demanding his opponent to admit that he killed (and raped) Oberyn's sister, as well as brutally murdering her infant children. It seems like he's going to succeed, having stabbed Gregor Clegane with his spear, until Clegane beats the ever-living crap out of him and kills him as he gloats about his crimes and Oberyn's lover screams on at the sidelines. Reality also ensues for Gregor when it turns out that Oberyn had covered his spearhead in an excruciating poison that takes weeks to kill.
Arianne Martell and a group of confidants attempt to crown Princess Myrcella as Queen of Westeros and run away with her to stage a rebellion, but they are run down and captured, Arianne's lover, Arys Oakheart, is killed and Myrcella is scarred horribly. The group is then broken up and imprisoned.
Quentyn Martell devises a daring plan to seize control of Danaerys's two remaining dragons. Fiery dragon breath ensues, and Quentyn dies after days of horrible agony, with fourth degree burns over 100% of his body. Poor brave fool.
In Petyr "Littlefinger" Baelish's backstory as he tells it to one of his associates, he challenged Brandon Stark to a duel for the hand of Catelyn Tully. Despite being small and having little training, Baelish thought he was like the plucky little heroes of the stories who triumph over the evil knight and win the maiden fair (paraphrased). Instead, Brandon, a master swordsman and seasoned soldier kicks his ass, nearly killing him and leaving him with a scar from his navel to his collar bone.
Dany goes and liberates the slaves in Astapor. A solid move for a compassionate queen, right? Nah- it screws up the economy of the Free Cities. Yunkai mounts an attack on Dany, half the slaves she liberated starve to death living in the ghost town, and the combination of the two helps a plague spread.
Also, after Dany takes Mereen and stays there as ruler, an underground rebel force known as the Sons of the Harpy starts killing Dany's personal soldiers and the former slaves.
The Brotherhood Without Banners, a troop of would-be Robin Hoods, led by Thoros OfMyr and Beric Dondarrion, quickly degenerates into several fractured segments, mostly composed of bitter soldiers and cut throats (or misguided war orphans), as the much-revived Dondarrion (and the decomposed living corpse of Catelyn Tully) loses all semblance of humanity and begin executing people left, right and center, as Thoros of Myr looks on in despair.
Animorphs: The Animorphs are a bunch of teenagers who fight alien invaders, and have to make increasingly morally ambiguous choices to win. War Is Hell is in full effect throughout the story. Ultimately, the war ends, but Rachel, Tom, Jara Hamee, James and presumably all of the auxiliary Animorphs are dead. The Blade ship escapes. There is no final all out battle with Visser Three, he merely surrenders when he realizes he's lost. He is then captured but not executed. Jake is left a broken man due to his actions in the war, he and Cassie break up, and Tobias leaves society. Marco does become famous, but it's hollow. There's even the possibility of a new war (with a different enemy) on the horizon. It is in short, exactly what would really happen after a war ends. When a number of fans complained about these things, author K.A. Applegate wrote a letter saying "This is the way it works in real life."
The Nero Wolfe stories can be seen as applying this to many of the classic tropes of detective fiction. Wolfe, like many of the Great Detectives, is a cultured intellectual who, when he isn't solving mysteries, lives a comfortable, even lavish lifestyle despite apparently having no source of income... except in Wolfe's case, it's established that he can afford to do so primarily because when he does solve mysteries he makes a point of charging what are at times almost extortionate fees for doing so, and both often has to keep ahead of draining his savings accounts through his luxurious lifestyle and has earned a reputation as being something of a mercenary Ambulance Chaser (or at least the Private Detective equivalent thereof). He's also a brilliant Amateur Sleuth who frequently exposes the police as blunderingincompetents... and naturally, the police resent both his interference in criminal matters and his showing them up.
By the end of On the Jellicoe Road, Taylor's pieced the stories together and figured out what happened to everyone. Her mother, finally clean and sober, returns home for the first time in years, and manages to build an actual relationship with her daughter. And then she dies from her cancer, because love and relationships are not medicine.
This comes to bite Griffin in The Invisible Man. For example, he finds out the hard way that being invisible doesn't protect him from the cold, factors such as the bloodied soles of his feet from walking everywhere unprotected and food digesting in his stomach can compromise his invisibility, rain will make an outline against his body, he still leaves footprints, etc.
In the fourth Diary of a Wimpy Kid book, Greg finds a bike some neighbors left out with the trash and decides to use it as his new way of getting around. However, his plans come to ruin when it falls apart in four days. Turns out a bike left out with the garbage where anybody can take it probably isn't a very good one.
Out of the Dark: Though mankind fights tenaciously and wins small victories, it ultimately has no way of defending itself from an enemy that controls the orbitals. It's a Hopeless War for man. Until the Twist Ending at any rate.
Harry Turtledove's Vilcabamba: When aliens far tougher and more powerful than anything humanity can field attack, no amount of skill or will can usefully close the gap, and mankind's governments continue to exist only at their pleasure, which can be and is withdrawn for reasons we can't fathom. Something of a Spiritual Antithesis to his own Worldwar books, where mankind does successfully resist Insufficiently Advanced Aliens.
In Petty Pewter Gods, two minor Shayir with the power to transform into owls set out to track Garrett's movements through the city from above. They soon discover that, while they can make themselves invisible to humans, it's the city's crows they should've been hiding from: spotting the "owls" flying around in daylight, TunFaire's urban crow population gathers in huge flocks to mob and harass them, driving them back to the ground.
The Wild Cards series attempted to portray superpowers as though they were dependent on real-world physics, and often without the Required Secondary Powers that keep comic-book superheroes from just being a danger to themselves and others. Many Aces have stock superpowers with completely logical downsides:
Golden Boy has Super Strength and Nigh-Invulnerability, but he's still an average-sized person, and when he tries to stop a moving car, a much-heavier object in motion, he gets knocked flat on his ass.
Envoy has a Compelling Voice that can make anyone who hears him do what he wants them to do. But the effect wears off when he leaves the general area. When he tries to do something important with his power, like change foreign or domestic policy, not only does it not accomplish anything lasting, but it ends up making things worse, because the people he used his power on know that he did something to them, and now they're angry and distrustful of him.
Brain Trust can telepathically absorb the knowledge of any nearby mind. The government decides to use her as a "backup copy" for their finest scientific thinkers. This basically gives her Dissociative Identity Disorder. It's not just the knowledge she absorbs, but the whole personalities of the people, which means she's basically got an entire university's worth of scientists rattling around in her skull...and sometimes they fight with each other. The stress of trying to keep her own personality intact costs her her family, and eventually her sanity.
Kid Dinosaur can Shape Shift into any dinosaur he wants to be, but he can't change his overall body mass. So he can be a T-Rex, but the T-Rex can only be about four feet tall.
Water Lily develops a secondary power where she can cure Jokers through sex. She promptly has to go into hiding, out of fear of being gang-raped by desperate mutants.
The Sleeper has an abnormal mutation which causes him to hybernate for weeks or months at a time, then awaken with a brand new form and new superpowers. After waking up he binge-eats to replace stored calories. And by the end of his waking cycle, fear of going to sleep and waking up a hideous monster (which does happen) turns him into a paranoid amphetamine addict.
Peregrine has wings and can fly. The wings are non-functional; an adult human woman is simply too heavy to fly. Her flying power is telekinetic. The wings are a placebo.
A minor Ace with electricity-based powers is not immune to his own powers. He has terrible personal hygene, because he can't bathe himself properly without risking electrocution.
Several Aces are giants. They're also crippled; their huge bodies can't support their own weight.
The Land of Stories: After spending 100 asleep, the Sleeping Kingdom is mostly dead and the inhabitants still prefer to sleep all day. Sleeping Beauty is still trying to make things right.
A bunch of college students who think they're in a typical Romero style zombie movie consider it inevitable that the Army & government forces will fail go into town to take matters into their own hands. After showing startling incompetence with their guns, the only thing they manage to do is kill a bunch of innocent people trying to escape being wrongfully quarantined before the actual monsters easily wipe them out.
Local people (who are filled with the full range of normal human stupidity and prejudices) form militias and kill anyone that they can't verify as being free from infection except the end of the book reveals that at most somewhere around 70 total people were infected, so the hundreds of people slaughtered by these militias are mostly innocent. As the book repeatedly points out, the paranoia that anybody could be infected and you couldn't tell that from looking at them was a much greater danger than the actual parasites.
Lastly, when David sees an Army barricade around town he realizes that the idea of the US Army getting overrun by zombies, whether slow or fast, is really pretty silly. The Army has plenty of Dakka and Tanks, not a single soldier is exposed to be bitten, the ground in front of them is covered with razor wire that will result in anything walking in being helplessly entangled and becoming an easy target, etc. Strategy is, after all, what the Army does and it would require them to grab an Idiot Ball bigger than the actual planet for them to be overrun from a small outbreak when they've had time to prepare themselves.
In Swamplandia!, when 13-year old Ava's Bigtree's sister runs off to the underworld, and with the rest of her family away, Ava sets off to retrieve her, taking a mysterious stranger called the Bird Man to be her guide. It turns out that just because a strange adult confirms your claims about a supposed 'underworld' (and claims to have been there before), does not mean that you should go off unaccompanied and alone with them. The whole underworld story was a lie, and Ava ends up getting molested by the so-called 'Bird Man'. Thankfully she manages to escape, but still.
The fairy tale ''Diamonds and Toads'' has a fairy bless and curse a younger daughter and older daughter, respectively. The kind younger sister has diamonds fall out of her mouth when she speaks, while the rude older sister has snakes, toads, and insects fall out instead. In the original story, the younger sister later marries a prince and the older gets kicked out of the house for being disgusting. But a rewritten version has a different outcome: the prince just wants his bride's free diamonds and the older sister uses her instant vermin creation powers to bully and threaten people.
In the backstory of The Elenium it is revealed that the previous war with Zemoch had resulted in a battle that saw tens of thousands killed on each side. When told that the Western kingdoms won, Talen eagerly assumes that they pushed the war on and succeeded in destroying their enemy. He is then informed that conscripting every able-bodied man to fight a war during the planting season has its consequences, and the famine that resulted nealy destroyed the Western kingdoms; leading to an upheaval in society by having the Knights forced to work alongside the peasantry in order to produce enough food to avoid extinction.