Foreclosure in the future for this ‘Castle’

Is “Castle” (9 p.m., ABC) DOA? I couldn’t find a pulse. Mystery writer Richard Castle (Nathan Fillion) is so bored with his career that he kills off a major character behind a bestselling mystery franchise. Even his professional rivals (real-life mystery writers James Patterson and Stephen J. Cannell, who cameo as themselves) seem dumbfounded.

Castle snaps out of his creative funk when he’s informed that a killer has been using his novels as blueprints for a series of gruesome crimes. The first leaves a fetching corpse covered in rose petals. Apparently, Castle and the killer were big fans of “American Beauty.”

Enter NYPD Detective Kate Beckett (Stana Katic, “The Spirit”), a tough, attractive policewoman who doesn’t fall for Castle’s brand of sweet talk. As soon as you can say “Moonlighting,” the novelist cracks wise as he trails her team in pursuit of the killer. And before episode’s end, forces conspire to allow Castle to collaborate with an uptight Beckett on an ongoing basis. She might not be amusing, but she’s his muse now.

Chemistry is a problem. She’s pretty enough, but basically a drag. And he’s an idiot, except when he’s not. Beckett sums up Castle rather nicely as “a 9-year-old on a sugar rush.” It says something when the cop is more facile with words than the writer and the novelist has better detective skills than the entire police force.

On the plus side, Molly Quinn does a nice job as Castle’s responsible teenage daughter, the kind of kid who does homework at the bar while dad signs his autograph on the breasts of willing strangers. And look out for Susan Sullivan as Castle’s frisky mother, forever on the prowl for rich, older men, using her “gray-dar” to find them.

• Just how do you get the kids hooked on history? Try a little sadism! Blending animation and brief snippets of live action, “Battles B.C.” (8 p.m., History) offers a blood-soaked comic-book approach (think “300”) to military history. The 9-year-old boy in me rather liked it.

The graphic approach solves the problem of supplying dynamic footage for events that occurred before photography. In tonight’s debut, Hannibal of Carthage looks like Vin Diesel on a rather rough day. Talking-head historians with Ph.D.s recall tactics, strategies and politics. But just when things get too talky, we can watch a cartoonish Hannibal decapitate an unlucky Gaul as blood splashes across the screen. Call it grotesque, but it’s anything but dry.

Tonight’s other highlights

• A deadly rival emerges on “Chuck” (7 p.m., NBC).

• A new patient (Jay Karnes, “The Shield”) has no internal censor on “House” (7 p.m., Fox).

• “Dancing with the Stars” (7 p.m., ABC) returns.

• Anne Meara, Jerry Stiller and Ben Vereen guest star on “The Wonder Pets! Join the Circus” (7 p.m., Nickelodeon).

• Sylar returns to his origins on “Heroes” (8 p.m., NBC).

• The White House remains in disarray on “24” (8 p.m., Fox).

• Horatio tries to save his son on “CSI: Miami” (9 p.m., CBS).

• Allison’s dreams point toward the end of days on “Medium” (9 p.m., NBC).

• A drug binge leaves many victims on “Saving Grace” (9 p.m., TNT).

Cult choice

Medical students (Julia Roberts, Kiefer Sutherland, Oliver Platt, Kevin Bacon, Hope Davis and William Baldwin) toy with mortality in the gloomy/silly 1990 drama “Flatliners” (6 p.m. and 8:30 p.m., Bravo).