Joe Utichi is a contributor to Deadline Hollywood.

Tim Hanks’ job in the Louisiana State Police took him to the very locations that paint the small screen in Nic Pizzolatto’s True Detective. He was the real-life Rust Cohle and Marty Hart, facing off against Louisiana’s darkest and most dangerous criminals. “I was doing pretty much just what Nic had written about,” Hanks says. “What he described, as far as the territory Image (2) Awardsline-logo_use-this-one__140529211810-275x38.jpg for post 738599they worked, was my territory.” Surely the bleakness of fighting crime that is depicted in the Emmy-nominated HBO drama was more fiction than fact. “No, it’s pretty spot on,” Hanks assures. “That’s police work. You have to deal with the unpleasantness of life.”

Related: EMMYS: A Fierce Year For Drama Series

As technical adviser on True Detective, Hanks was responsible for helping the creative team accurately capture the world of 1990s police work, which he says amounted to little more than fine-tuning. “Nic is from Louisiana, a'True Detective' Finale and Why Season Finales Are a Treacherous Businessnd had a lot of intimate knowledge,” he explains. “He’s brilliant, and he wrote a great story. I just helped him with the intricacies of how the troopers wore their uniforms—the pins and lapel badges they’d wear.”

Hanks’ modesty and matter-of-factness speaks to his long experience in law enforcement. He spent 22 years on the force, 15 of them as a detective, and retired shortly before True Detective started production in 2012. He now oversees security at the University of Louisiana’s New Iberia Research Center in Lafayette.

The timing of his police retirement couldn’t have been more perfect. “HBO had been reaching out to State Police for a long time, and I don’t think they were getting what they wanted,” Hanks remembers. “When they circulated the script to some of the higher-ups in investigation, one of the lieutenant colonels called me and said, ‘You’d be just what they need.’ ”

Related: Nic Pizzolatto & HBO Refute ‘True Detective’ Plagiarism Claims

Pizzolatto wrote the series without input from Hanks, whose role mostly was to interact with director Cary Fukunaga and the cast. “I’d stand behind (Fukunaga), and when Matthew McConaughey and Woody Harrelson felt like they needed help, I was there for them to reach out to.” But the pro actors mostly had it down. “They’d maybe ask me about whether I’d bring my weapon into a jail, or how I’d hold it,” Hanks says. “Those kinds of things.”

Related: EMMYS: The Treacherous Business Of Ending A TV Series

'True Detective'If it sounds as if Hanks had a fairly easy task, consider the challenges he faced when on the job for real. “Maybe some of (True Detective) was made for TV,” he says. But the way in which the fictional detectives sacrificed to get the job done “was absolutely true to form.”

In exchange for the technical expertise, Fukunaga rewarded Hanks with a small speaking part as a jailer in the opening scene of Episode 6. “It was me and Woody Harrelson,” Hanks says. “I didn’t expect it, but it was interesting. I was a little nervous, but I think it all worked out.”

So how does life on a television set compare with that of a homicide detective? “I didn’t realize how hard the cast and crew work,” Hanks admits. “They have a really hard job.”