NEW YORK — Comedian Dave Attell told a packed house at the Comedy Cellar that New York after Superstorm Sandy had a familiar feel. “It was dark. Toilets were backing up. ... It was pretty much like it always was.”

Another comic, Paul Mecurio, told the same crowd that he got so many calls from worried family members that he started making things up about how bad it was.

“I’m drinking my own urine to survive,” he joked.

New York’s comedy clubs, some of which had to shut down or go on generator power in the aftermath of the storm, dealt with a bad situation like they always have — by turning Sandy into a running punchline.

“If they’re going to do jokes on Sept. 12 about Sept. 11, then this thing isn’t going to slow us down,” said Vic Henley, the emcee of a show Oct. 28 at Gotham Comedy Club.

Sean Flynn, Gotham’s operating manager, said comics were including the storm in their acts but had to be careful nonetheless not to make people feel worse than they already did.

“There’s the old adage that tragedy plus time equals comedy. The variable is the time,” he said. Still, he added: “You can’t ignore the subject. That’s what comedy’s all about.”

The Comedy Cellar, a regular stop for decades for the country’s most notable comedians, was closed from Oct. 28 through Nov. 1, but reopened on Nov. 2 after a generator was brought in at a cost of several thousand dollars. Power didn’t return until the next day, and the crowds came with it.

“Everyone has a bad case of cabin fever,” said Valerie Scott, the club’s manager.

Mecurio said he thought the joke was on him when he got a call from the Comedy Cellar saying the club was going ahead with its show even though there was no light in the West Village. He headed downtown from the Upper East Side, hitting dark streets after midtown.

“It’s pitch dark,” he said. “And there’s a room packed with people laughing. It was so surreal. ... I’m calling it the generator show. It was a really cool thing.”

“You could feel there was something special about the show,” he said. “The audiences were tempered in their mood. You could tell something was up, something was in the air. I knew it was cathartic for people.”

He said a woman approached him after the show to thank him, saying: “You kind of brightened my day.”

Sometimes, comics used the storm to get a laugh at the expense of the crowd, like when Mark Normand looked down from the Comedy Cellar stage at a man with a thin beard.

“I like the beard,” he told him. “Is that because of Sandy? You couldn’t get your razor working?”

And Attell used Sandy to mock a heckler, telling him: “You must have been a load of laughs without power.”

At another point, Attell looked for positives in the storm.

“There’s nothing better than Doomsday sex,” he said.

Mecurio said he has made a point of including the storm and the havoc it caused whenever he takes the stage.

“I feel like as a comedian in the spirit of social satire, it’s what we’re supposed to do,” he said. “It’s the elephant in the room. How do you not do it?”