As they set out for the haunted house the following morning, Huck notes that it's Friday and that he dreamed about rats the night before. Both are bad omens, and Tom decides they had better not dig that day and Huck agrees to follow Tom's lead. They play Robin Hood instead.
Huck is more independent than Tom and has more experience of real life because of his tough upbringing, but Huck is in awe of Tom's knowledge of books (not knowing how incorrect Tom's "knowledge" often is) and therefore follows Tom's lead.
On Saturday morning they have no success digging at their first dead tree. They head to the haunted house. Inside, the building is covered in cobwebs and falling apart. They are scared at first, but become more confident as time passes and decide to explore upstairs. While they look around upstairs, they hear some mysterious noises below. They peek through the floorboards and see two men. One is the deaf and dumb Spaniard who recently arrived in town and the other is a stranger. They are shocked when the Spaniard speaks, and even more shocked when they realize it is Injun Joe's voice!
The reappearance of Injun Joe gives the novel a trajectory to follow in its final chapters. Until now, its structure has followed a series of short stories that serve almost as moral lessons. Injun Joe's escape introduced a real, as opposed to imagined, danger to the boys, and tracking him down to prevent further brutality will be the novel's resolution. Twain turns his novel into an exciting tale of pursuit and capture, much like one Tom would enjoy reading.
Injun Joe wants the stranger to join him in a "dangerous job." They plan to leave their hide-out here at the haunted house, and complain to each other that they would have left earlier but that Tom and Huck's hanging around nearby held them back the day before. After lunch, the two men take a nap.
The stranger is never developed as a character, nor is his connection to Injun Joe fully explained. He is only a plot device, and Injun Joe remains an isolated, anti-social character, presumably incapable of friendship.
Once the men are asleep, Tom insists on leaving. Huck is terrified of waking the men. When Tom decides to leave and stands up to go, the floorboards squeak and he changes his plan and stays put.
In their past adventures, the boys faced dangers of their own imagining. Now, as they move into adulthood, they face real violent harm from a villain.
The men awaken and discuss what to do with the 600 dollars in silver coins that they have on them. It's a heavy load, so they decide to hide it in the house for now. The boys are ecstatic at the prospect of taking this fortune.
In all of Tom and Huck's previous adventures, superstitious tokens and other junk assumed the status of treasure to them. In coveting the silver coins, the boys desire something of actual value in the adult world.
As Injun Joe digs a hole to bury the money, his knife strikes something hard under the floor. The men grab a pick and shovel the boys had left downstairs and start digging. They uncover a wooden box full of several thousand dollars in gold coins. They presume "Murrel's gang" left it there long ago.
Even as the dangers and rewards Tom and Huck are faced with take on adult significance, Twain continues to make his story even more fantastic, with hugely improbable events occurring.
The stranger thinks that finding this treasure means they don't have to do the "dangerous job." Injun Joe insists that they will do it, that they'll get revenge, and afterwards head to Texas.
Tom and Huck fear that Injun Joe's revenge is on them. The notion of revenge is a common trope of the romantic tales Tom loves, so Twain continues to shape his story through formulaic plot devices.
Injun Joe initially plans to hide the treasure in the house for now, but then it occurs to him that the presence of the pick and shovel in the house, which had fresh dirt on them, means that others have recently visited the house. He decides instead to take the treasure to his den at "Number Two—under the cross".
"Number Two—under the cross" echoes the language of a mystery novel or drama, rather than the plain speak that the robbers would likely use at a time like this. Twain is able to keep the reader engaged through such unrealistic plot-devices, just as Tom might engage his playmates.
Injun Joe is about to head upstairs to look for the tools' owners there, but the stranger convinces him that it's unlikely anyone is there and that they're better off using the remaining hours of daylight to organize themselves for leaving after dark. Once they've gone, Tom and Huck leave as well, furious with themselves for having left their equipment out. They wonder, too, if Injun Joe's revenge is aimed at them. Huck points out that he is probably plotting revenge against just Tom.
Being a realist, Huck fails to console Tom, who would like to hear about how he'll escape Injun Joe by some fantastic stroke of luck. Twain's descriptions of the boys' final adventure with Injun Joe moves back and forth between realism and sentimentality. Twain also offers constant reminders of how the real world is encroaching on Tom's perception. His path towards maturity is bittersweet.