As flat and generic as its title, “Night School” is a limp comedy that comes off like a cruelly extended episode of a bad classroom-based network sitcom (though one with rougher language than would be permissible on the tube). A running-time that approaches two full hours is explicable only by the fact that the dreary screenplay is credited to (or to be blamed on) no fewer than six writers, and it must have been a contractual obligation to include the worst ideas provided by each of them.

Kevin Hart, whose company produced the misfire and also headed the bevy of scripters, plays Teddy Walker, who’s introduced as a very old-looking high-school student flunking out and being harassed by his classmate and nemesis Stuart (Taran Killam). Years later, he’s a salesman at a place that sells BBQ grills, successful because of his motor-mouthed skill with customers he’s sized up for big purchases. But that’s not enough for him; he’s got a flashy car and expensive clothes, all to impress his girlfriend Lisa (Megalyn Echikunwoke), a well-heeled executive for whom he buys a big engagement ring his buddy Marvin (Ben Schwartz), a financial advisor, reminds him he can’t afford.

When he pops the question in the BBQ showroom, disaster strikes when a propane container catches fire and blows the place up. Suddenly unemployed, he’s told he must get his GED to find a new job, but when he returns to his old high school to try to finesse a diploma, whom should he find sitting in the principal’s chair but old Stuart? Nevertheless he’s compelled to let Teddy join the night class taught by dedicated, tough-talking Carrie (Tiffany Haddish).

The other students are oddballs, of course. There are Mac (Rob Riggle), a big lunkhead who’s agreed to get his degree to convince his son to stay in school; Theresa (Lynn Rajskub), a housewife with three kids continually trying to convince herself she’s happy; Jaylen (Romany Malco), a conspiracy buff; Mila (Anne Winters), an apathetic teen dropout; and Luis (Al Madrigal), who just happens to be the waiter Teddy just got fired. There’s also Bobby (Fat Joe), a convict who joins them by skype.

With such a cast, you can expect a few good moments. Hart and Carrie trade insults at a ridiculously long stoplight early on (curiously enough, the incident isn’t mentioned when they later meet), and Malco milks the goofy conspiratorial stuff pretty effectively. A few good moments also come from Keith David, doing his stentorian stuff as Teddy’s disappointed dad.

But most of the cast, quite frankly, is pretty much wasted, and despite all the writers on hand, the episodes haven’t been assembled into a coherent whole. One example can suffice. At one point the students are trapped on the roof of the school. Mac tries to jump to an adjacent roof, doesn’t make it and falls to the cement steps below; he lies their contorted, looking as though he’s broken his back, and Jaylen vomits on him from above (an upchuck scene is, of course, obligatory in a movie like this). Then cut to the next day: the students are back in class (no explanation of how they got off the roof) and Mac seems none the worse for wear. Even in a farce, such illogic won’t play.

But certainly the worst aspect of the script is that, late in the day, Terry’s troubles in dealing with mastering material are explained medically: he’s diagnosed with dyslexia, dyscalculia and a host of other learning disabilities. How does Carrie help him overcome these? By dragging him into a mixed martial arts cage and beating him up until he understands the subjects, ordering him to “focus” until he does. This gives Hart and Haddish an opportunity to do some physical comedy, of course, but from the point of view of people actually afflicted with such problems, it’s unbelievably insulting.

Moreover, that sequence, like so much of the picture, is atrociously directed by Malcolm D. Lee. “Night School” has no shape or rhythm; scenes play out sluggishly, further slowed down by innumerable reaction shots, and then linger for a few dreary seconds before finally ending. That just reinforces the feeling that what we have here isn’t a movie—it’s a series of individual sketches stitched together haphazardly into a two-hour revue, which would be fine if they were funny; they’re not. The picture is pretty threadbare technically as well, though at least for a change Atlanta is playing itself rather than serving as an unconvincing stand-in for some other city.

There’s no need for you to register at this “School.”