The Warner Bros. superhero mashup “Suicide Squad” world premiered at the Beacon Theatre in uptown Manhattan on Monday night to an enthusiastic reception. The tentpole, directed by David Ayer, follows an ensemble of DC comic-book villains — including the Joker (Jared Leto), Deadshot (Will Smith), and Harley Quinn (Margot Robbie) — who band together to take on an even greater foe.

After director Ayer took the stage, he thanked his agent when he was interrupted by a voice in the crowd. “F— Marvel,” Ayer said, repeating what the fan had yelled at him. (Ayer later apologized on Twitter for the incident.)

Joining the cast inside the theater, Smith recalled something that Ayer had said to him. “It’s not a movie of good vs. evil — it’s a movie of bad vs. evil,” Smith recalled. Then he added his own take onstage: “This is one of the baddest casts in the whole damn world,” he said.

“And also, what I love about working with this group, as you see up on this stage, it’s a rainbow,” Smith continued. “It’s all races, creeds, and colors. This is the diversity that this country is supposed to be about. It’s the inclusion this country is supposed to be about.” The sentiment was met with loud cheers.

The movie could reignite Smith’s hot streak at the summer box office, that extended from 1996’s “Independence Day” through 2012’s “Men in Black 3.” “Suicide Squad” will also serve as a launching pad for more DC spinoffs and sequels, following last spring’s “Batman v Superman,” which Robbie confessed she hadn’t seen yet. Even so, the consensus at the after-party was the “The Wolf of Wall Street” actress walks away with “Suicide Squad,” given her crowd-pleasing one-liners as Harley Quinn, the Joker’s girlfriend.

Although extravagant premieres have been shrinking because of cost-cutting in the movie business, Warner Bros. spared no expense for the “Suicide Squad” party. Held at downtown’s Skylight at Moynihan Station, the space was converted to look like a giant carnival, complete with a hanging dancer in a box overlooking the bar and a make-your-own-TV-star next to a faux tattoo parlor. Guests not only scarfed down hamburgers, pizza, crab cakes, and macaroni and cheese, but also cupcakes, ice cream sandwiches, cotton candy (via two man-operated machines) and chocolate-covered twinkies.

The cast partied past midnight. Leto, wearing a blue Gucci jacket with a lion stitched on its back, chatted with Sue Kroll, the studio’s president of worldwide marketing and distribution. Not to be outdone, Robbie donned an Alexander McQueen gown with a shimmering unicorn on the side.

‘Suicide Squad’ Members: Who’s Who