Although it’s about characters who use a scam to win the Pennsylvania State Lottery, everyone connected with Nora Ephron’s new comedy is a loser. That’s especially true of unwary viewers who might be snookered into paying good money to see the dreary, gruesomely unfunny, surprisingly unpleasant flick. Despite the title, “Lucky Numbers” pretty much comes up snake eyes all around.

What Ephron and writer Adam Resnick were apparently aiming for was a dark but goofy farce about a bunch of grubby lower-class types whose efforts to get rich through chicanery prove so inept that they lead to catastrophe after catastrophe; the structural notion was to build up the hilarity by adding layers of comic frustration and introducing more and more oddball participants into the mix. But nothing works as intended. First of all, for the recipe to succeed, the characters would have to have at least a modicum of likability, but they don’t. Indeed, everybody in the picture comes across not merely as dense and incompetent, but nasty and brutish to boot; and, under Ephron’s heavy-handed encouragement, the large cast flails about desperately trying to make them into people you’d care to pass even a second with. John Travolta, looking puffy and smirking and strutting uncontrollably, plays Russ Richards, a pompously stupid Harrisburg TV weatherman who longs to be a TV game show host. When his financial situation collapses as the result of a December heatwave that destroys his snowmobile franchise, he allows seedy strip-bar owner Gig (Tim Roth, who shows absolutely no flair for comedy) to persuade him to use illegal means to get on his feet again. First there’s a disastrous attempt to burglarize his own dealership featuring a crazed, baseball-wielding thug named Dale (Michael Rapaport, screaming and chewing up the scenery in his customary way–see also “Bamboozled”); then there’s the scheme to fix the $6-million lottery drawing at the TV station–a plot that requires the collaboration of dumb but ambitious Crystal (Lisa Kudrow, exaggerating her TV mannerisms in a failed attempt to achieve the sort of hard-boiled but lovable quality that Judy Holliday epitomized), the gal who extracts the numbered balls to identify the winner, as well as of her doofus cousin Walter (Michael Moore), who’s picked to claim the prize. (Moore, the comic documentarian known for his anti-establishment riffs in pictures like “Roger and Me” and a variety of TV series–most recently Bravo’s “The Awful Truth”–is simply terrible as this hapless, asthmatic schlub. Having missed the mark as a fiction writer-director with 1995’s “Canadian Bacon,” he now shows he can’t act, either.) Needless to say, the lottery scheme goes awry, and before long a variety of other supposedly colorful characters have been drawn into the resultant chaos, including sleazy station manager Dick (Ed O’Neill, so loathesome that he makes his “Married With Children” dad seem positively benign), Russ’ goofy assistant Larry (Michael Weston, who seems to be channeling the spirit of Michael J. Pollard), a greasy bookie played by “The West Wing’s” Richard Schiff, and a dumb, lazy, thoroughly inept cop (tired-looking Bill Pullman) whose phony attempt to claim disability has just been disallowed.

It’s not just the crummy characterizations that sink “Lucky Numbers,” though; it’s a screenplay that’s incredibly misconceived and totally hamfisted direction. The script includes no fewer that three violent deaths, a couple of assaults, periodic (and utterly gratuitous) shots of unattractive strippers gyrating about in smoke-filled rooms, and so much foul language that it might make Quentin Tarantino blush. It would require a helmer of rare genius to transform such a mix into an edgy laugh riot. Ephron comes nowhere close. At best she’s a mediocre craftsman with a talent for cobbling together limp but crowd-pleasing comedies (“Sleepless in Seattle,” “Michael,” “You’ve Got Mail”); but at her worst (as in the dreadful 1995 Steve Martin vehicle “Mixed Nuts”) she’s demonstrated that she can fall to nearly the Ed Wood level. This latest effort resembles “Nuts” (and another would-be black comedy about lower-class schmucks, Lawrence Kasdan’s 1990 fiasco “I Love You To Death”) in that everyone and everything in it seems off–the tone unpleasantly sour, the characters uniformly revolting, the scenes pitched either too high or too low, the pacing clumsy, the violence overly explicit, the humor variously puerile or strident. As director, it’s Ephron who must bear the ultimate responsibility for the fact that in a picture where the joke is based on the premise that everything goes wrong, that turns out to be all too cinematically true.

To close on a positive note, one must admit that “Lucky Numbers” is better than John Travolta’s last movie. Of course, that was “Battlefield Earth.” And it’s not that much better.