You wouldn't know it to look at the footage, but when the square-jawed actor Armie Hammer shot a door clean off its hinges on the set of Clint Eastwood's recent movie J Edgar, he was being given expert coaching by one of America's most accomplished door-shooters.
Scott Nelson, who was standing out of view just a couple of yards away, is a former agent who spent 25 years with the Federal Bureau of Investigation. As a "technical consultant" on the historical movie, his job involved helping Hammer to correctly use a vintage Thompson sub-machine gun to blow apart the woodwork. "Those Thompsons have a hell of a kick," he says. "They can knock you off your feet. So shooting them isn't easy. It has to be done in a stance where you have to crouch and lean. I was standing just out of sight of the camera, helping Armie fire it properly, and also making sure the hot shell casings didn't hit anyone."
Mr Nelson, 69, is part of a now-sprawling community of expert "consultants" who help Hollywood film-makers portray everything from fight scenes to the intricacies of real-life police investigations realistically. On J Edgar, a biopic of the FBI's founder, J Edgar Hoover, Mr Nelson spent six weeks helping Eastwood recreate the bureau's wood-panelled HQ, and ensuring that cars, jargon, tactics and the demeanour of agents in the film were historically accurate.
"People don't always understand what a real FBI agent looks like," he says. "In my experience, they look purposeful, put together, neat, and very respectable. I met Hoover twice, early in my career, and he could be very demanding about appearances. If you worked for him, you had to have a white shirt, a moderate tie, a blue or black suit and absolutely no facial hair."
Mr Nelson, who later rose to head the FBI's public affairs office, where he helped to launch the television series America's Most Wanted, counts as highlights of his consulting career work on the series 24 and the film The Silence Of The Lambs, where he helped persuade the FBI to allow filming at its training base in Quantico, Virginia.
There is barely a studio movie in production now that doesn't use a retired boxer or martial artist to help with fight scenes, or a former marine to ensure that battlefields are realistic. Medical dramas are vetted for howlers by medics; university professors cast their eyes over science-fiction scripts. The trend partly reflects a growing need for "special features" to lift DVD sales. And it also stems from increased studio interest in "real-life" stories and historical biopics.
"When you are telling a true-life story, a little inaccuracy provides a foothold for people who want to be critical of the whole project," says Dustin Lance-Black, the screenwriter of J Edgar. "So it of course helps me, as a screenwriter, to really stand behind a project if I can say that we did everything that we could do to get the important facts right."
Black won an Oscar for Milk, a biopic of the pioneering gay-rights activist Harvey Milk, on which he consulted with several of his subject's surviving acquaintances, and employed Cleve Jones, a close colleague of Milk's, to help recreate 1970s San Francisco.
The rise of the internet has added to the market value of technical consultants, he adds, since armchair viewers use the web to identify perceived historical inaccuracies in films. "When they made a movie like Patton [the biopic of the Second World War general] people would have to go to libraries and look at reference books to check things out. Information is far more widely available today."
The job isn't always glamorous. A Los Angeles police officer called Brett Goodkin was suspended from active duty recently after it emerged that he was a technical adviser for Sofia Coppola on The Bling Ring, a film about a group of teenagers who burgled celebrity homes. Prosecutors were, understandably, concerned that the paid gig would undermine his credibility as an impartial witness in the group's imminent trial.
Mr Nelson, meanwhile, had to put up with calls from old FBI colleagues and contacts who were angered by a controversial plotline in J Edgar, which suggests the protagonist was a repressed homosexual with a keen interest in cross-dressing.
"It's a very sensitive issue which galled a lot of the FBI guys," he says. "Some of them spoke with Clint on the phone about it. At one point, the head of public affairs at the Bureau got involved. They blamed me. I understand their concerns, but as I told them, I don't have final say on films. In this job, you just advise."
- More about: