The identity of Carlos Ruiz Zafón's literary hero soon becomes crystal clear in The Angel's Game, a Gothic prequel to his immensely successful The Shadow of the Wind. The breeze from Charles Dickens and his Great Expectations blows through this novel from the start, as a hero who starts off as a Catalan version of Dickens's hard-done-by young Pip looks set for both greater things and troubled times. There are other winks at Great Expectations, which soon gets name-checked and finally appears as a gift to the young hero that causes him to be beaten black and blue by his father - a lost, violent, book-hating soul from the putrid underworld of early 20th century Barcelona.

Zafón also gives us an initially aloof and unattainable girl, a wealthy benefactor and, even, a witch-like figure with a resemblance to the spooky Miss Havisham. There, however, the similarities end. Zafón has his own story to tell, that of a young writer of pulp fiction, David Martín. His hero achieves popular success by inventing a glamorous murderess who, clad in exotic lingerie, hypnotises her victims with an erotic dance before killing them with a kiss made deadly by poisoned lipstick. The writer goes on to make a Faustian pact with a Lucifer figure to write a book that will create a religion and a legion of believers. Not Dickens then, but Zafón - a man with a clear, if sometimes strident and pulp-like, voice of his own. Spanish readers, who get his books first, cannot get enough of them: The Angel's Game was the fastest selling book in Spanish history.

Zafón used to write children's books and his narrative style embraces relentless pace and fantastical and magical diversions. He also spent time as a scriptwriter and The Angel's Game often seems written with the screen in mind. A near miss with the kind of tram that famously put paid to the great architect Antoni Gaudí, for example, includes the sort of brake-grinding, two-inches-from-death experience that invites the "to be continued" of an old-fashioned TV series or, indeed, a novel written in instalments.

The cemetery of books from The Shadow of the Wind reappears here, along with the Sempere and Sons bookshop, as the hero tastes the bitter fruits of his fall into temptation. "If Shadow is the good girl in the family, The Angel's Game is the wicked stepsister," is how Zafón explains things.

He, like Dickens, also has a city to write about. The Angel's Game is set in his native Barcelona, whose back streets, parks, cemeteries, slums, eccentric architecture, violent 1920s underclass and well-heeled bourgeoisie provide fertile ground for the imagination. What better, after all, for a writer of gothic tales than to have a ready-made gothic quarter to hand? Its labyrinthine and intimidating streets provide the perfect setting for the dark, terrible deeds that seed his story with mystery, blood and tension. Barcelona is a character in itself. Lovers of the city will enjoy being tugged down its more claustrophobic streets and taken on a tour of the still-fresh splendours imposed on the city by Gaudí and the 1929 great exhibition.

Barcelona's soaring Tibidabo mountain is said to be named after the words used by Satan to tempt Christ: "All these things will I give thee (tibi-dabo)." Zafón constantly invites us to see Barcelona, his "city of the damned", from above. He takes us into sinful corners, indulging fantasies that are erotic, magical or violent. In the end Zafón is the tempter. Many will fall for his vigorous and exhaustingly relentless story-telling.

• Giles Tremlett's Ghosts of Spain: Travels Through a Country's Hidden Past is published by Faber