Watch a 'Beverly Hills Cop' scene that Eddie Murphy would never perform today (exclusive)

Back in the 1980s, Eddie Murphy was comedy’s answer to Superman, boasting a joke-generating mind that was faster than a speeding bullet and able to elevate weak material with a single punchline. Murphy’s swift and sharp comic instincts famously saved Saturday Night Live, and rescued more than a few movies as well. Case in point: Beverly Hills Cop, the 1984 blockbuster that began its life as a Sylvester Stallone action movie that became something better — and funnier — once Murphy took over the role of fish-out-of-water Detroit cop Axel Foley. Because the casting switch happened quickly, director Martin Brest started shooting while the script was still being reworked, and he relied heavily on his new leading man to fill in the gaps, and generate the laughs, that the screenwriters couldn’t.

Murphy’s comic contributions to Cop made the movie a global hit, and spawned a three-movie franchise that’s collected in a remastered collection that’s currently available to purchase on digital platforms and is arriving on Blu-ray on Jan. 14. Among the bonus features is an all-new featurette — featuring a vintage 1984 interview with Brest — that reveals just how much of the film his star made up on the spot. “Whenever we would get into a bind, Eddie would always have a way out,” Brest says in an exclusive clip that Yahoo Entertainment is premiering today. (Watch the clip above.)

Brest has a go-to example for how Murphy repeatedly got Beverly Hills Cop back on track whenever it threatened to fall apart. Midway through the movie, the script requires Foley to infiltrate a snooty Beverly Hills gentleman’s club in pursuit of the movie’s villain, Victor Maitland (Steven Berkoff), who ordered a hit on the cop’s best friend, Mikey (James Russo). There was just one problem with the scene: neither the writers nor Brest had been able to come up with a convincing way for Axel to make into the club’s dining room.

“I went into his trailer in the morning and he was real tired,” Brest remembers. “I said, ‘Eddie we’re in trouble. In around 80 seconds we’re going out there to shoot a scene where you con your way into a men’s club. Whaddya got?’” After glancing at the two scripted versions of the scene, it took Murphy “between six and eight seconds” to come up with a solution. “He proceeded to enact the scene in front of me, and I fell on the floor in hysterics.”

Murphy’s big idea was that Axel would take on the identity of Ramon, a “fella” that Maitland met a week ago. And he’s got an urgent message for his friend: “Tell him Ramon went to the clinic today and I found out that I have herpes simplex 10. I think Victor should go check himself out with his physician to make sure everything is fine before things start falling off on the man.”

That joke worked in the moment, moving the plot along and allowing a 1984 audience to chuckle at the sight of Foley outsmarting a pompous elitist. Flash-forward to 2020, though, and the scene hasn’t aged well, relying on outdated gay stereotypes and an STD punchline that’s uncomfortably reminiscent of some the now-infamous AIDS jokes that Murphy worked into his comedy special Delirious, which was released the year before Beverly Hills Cop hit theaters. Murphy himself would likely agree. In a recent interview with CBS Sunday Morning, the Dolemite Is My Name star — who just made a celebrated return to SNL as a prelude to a possible stand-up tour — confessed that he regrets some of his ’80s material, particularly the pronounced homophobia.

“Some of it, I cringe when I watch,” Murphy remarked. “I'm like, ‘Oh my God, I can't believe I said that!’ In the moment, you kind of was like, ‘Hey, it is what it is, you know?’” (He went even further in 1996, releasing a statement in which he apologized for some of the material in Delirious.) The actor may soon have the chance to show us an older, wiser — but still funny — Axel Foley: Netflix is reportedly developing a fourth Beverly Hills Cop installment with Murphy and producer Jerry Bruckheimer. It’s OK with us if Ramon sits this one out.

The Beverly Hills Cop three-movie collection is currently available on Digital in 4K Ultra HD and will be available on Blu-ray on Jan. 14 from Amazon and Walmart.

Read more from Yahoo Entertainment:

Want daily pop culture news delivered to your inbox? Sign up here for Yahoo Entertainment & Lifestyle’s newsletter.