During Apophis's attack on the Dallas Museum, Sadie Kane is contacted by a face in the wall who tells her that they won't be able to save the Book of Overcoming Apophis, but to save King Tut's shadow box instead, that it will give them a clue in how to defeat Apophis. The face also informs her that they will need his help to stop Apophis and that they only have until sunset the two days later to save him from something in order to get his help. Sadie is confused, but they manage to get the box. After discovering that it contains King Tut's sheut, his shadow, they hit upon the idea of using Apophis' shadow to defeat him. This idea is further reinforced by Anubis.
Looking for information on how to use Apophis' shadow against him, Carter Kane and Walt Stone visit the god Thoth who confirms their theory about using shadows to destroy Apophis, but is unable to help them as its against godly laws to tell mortals where to find a god's shadow or how to use it against them. However, he points them in the direction of a way to do it themselves: a long time before, he wrote the Book of Thoth, a field guide of sorts that contained a lot of very valuable information on the gods including where to find their shadows. It was stolen by an evil magician named Setne who used its knowledge to create a number of spells, including one to destroy a god's shadow. Thoth suggests that Setne could lead them to the Book of Thoth and show them how to capture and destroy Apophis' shadow. However, Setne is now a ghost and after having escaped many times before, will be tried in the court of Osiris that night at sunset and likely destroyed as Julius Kane is now Osiris' host and is cracking down on rebellious ghosts. Carter and Walt realize they have to convince Julius to turn Setne over to them in order to stop Apophis and Sadie realizes he is the face in the wall she saw at the museum. When he told her she'd have to save him by a certain time in order for him to help them, he meant his trial.
Joined by Zia Rashid, Carter, Sadie and Walt travel to the Hall of Judgment to inform Julius of their plans. While he is horrified and angry at first, he eventually agrees to help as its the only way. However, he doesn't know the magic they need personally and before they can tell him about their need for Setne's help, his trial begins.
Setne is led into the Hall bound by the Seven Ribbons of Hathor and enchantments and faces Julius with no fear. The judgment god, Disturber reads off Setne's crimes: blaspheming against the gods four thousand and ninety-two times, using magic for evil purposes including twenty-three murders one of which he was paid to do, plotting against three separate pharaohs, trying to overthrow the House of Life six times and robbing the tombs of the dead to steal books of magic. Setne claims that one of the blasphemes was just a joke and that the murders were self-defense, including where he killed for someone else, saying that was self-defense for his employer. Setne tries to use Divine Words to confuse Disturber and get him to let him go as Setne had faced these charges before in his previous trials, but Julius sees through it and strangles Setne with the Ribbons until Sadie gets him to stop. Julius then reminds Setne how his previous trials went: in the first instance, he got a deal to serve the pharaoh with his magic, but escaped en route, killing his guards and sowed chaos across Egypt for three hundred years before being captured again. Setne escaped three more times, running amok when the gods were gone, committing crimes and terrorizing mortals during which time he caused the French Revolution and World War I. Julius informs him he is out of tricks, will be judged and then destroyed, but Setne just laughs and informs him that he is not out of tricks as Julius' children and their friends need his help. Julius is furious at first until Carter and Sadie inform him that Setne is right and they need him to be released into their custody so that they can stop Apophis. Julius refuses to believe that Setne would help, saying he's a servant of Apophis, but Setne tells him that he doesn't serve Apophis as there is nothing in it for him and tells Sadie, using Divine Magic to influence her, to tell Julius their plan. Julius refuses, believing its impossible and that even if it wasn't, Setne can't be trusted and would kill Carter and Sadie at the first opportunity if released to them. After Sadie pleads with him to let them try and Setne tells him that this is the only way to save the spirits of the dead before Apophis' shadow consumes them all, including his wife, Julius decides to hand Setne the Feather of Truth to test his truthfulness as it will destroy him if he lies. With the feather, Setne confirms that he did create a shadow execration spell that could be used to destroy gods, including Apophis though he died before he could test the spell. Setne can't use it himself as it can only be cast by a living magician and had planned to use the spell to blackmail the gods into doing his bidding. While the copies of the Book of Overcoming Apophis he wrote the spell in were destroyed, the original Book of Thoth would still have Setne's notes on the spell and Apophis wouldn't have found it as Setne hid it too well. The Book can tell them how to find the shadow, capture it and destroy it. Setne tells them he can't tell them the spell himself as its complicated and it has been a long time since he wrote it so its dangerous to get it wrong. They also need his help to decipher the notes. He also can't just tell them where the Book is as he needs to disable the traps and curses he set to protect it. With the Ribbons and Zia's knowledge of them, they can control him and he promises not to try to escape until he leads them to the shadow, saying that no one knows the deeper levels of the Duat like he does and he's their best hope for a guide.
With the help of Setne, Carter and Zia are able to get the Book of Thoth and reach Apophis' shadow, but Setne tries several times to betray them along the way. Despite this, they have no choice but to trust him and he leads them to Apophis' shadow in the Land of Demons. After Zia summons it, Setne turns the glamour he cast on them into bindings and reveals that his real plan is to capture the shadow and use it to force Apophis to do his bidding and destroy only what he wants or get destroyed. He couldn't cast the summoning spell as a ghost and it was thus complicated and he didn't lie, but he can capture the shadow for himself. However, before he can, Sadie suddenly arrives after having restored Bes with the help of Anubis who, along with Walt who is now his host, realized that Setne was lying and sent her to the others. Sadie binds Setne in the Ribbons and frees Carter and Zia. However, while they are able to get Apophis' shadow, Setne once more escapes with the Book of Thoth, meaning he has the potential to be a very great threat though he lacks the ability to cast most of the spells as a ghost. When Carter and Sadie inform Julius of Setne's escape after Apophis is killed, he tells them he expected it but hoped that Setne wouldn't escape before he could help them get the Book of Thoth and the shadow. Setne later starts mixing Greek and Egyptian magic, but is finally defeated by a combination of Carter, Sadie, Percy Jackson and Annabeth Chase with some help from Nekhbet. Instead of taking him for judgment, they imprison him in a miniature snow globe with a spell from the Book of Thoth and it becomes Carter's new paperweight.