Clarence Williams III, who played the cool undercover cop Linc Hayes on the counterculture series “The Mod Squad” and Prince’s father in “Purple Rain,” has died. He was 81.

Williams died Friday at his home in Los Angeles after a battle with colon cancer, his manager Allan Mindel said Sunday. Tributes came quickly on social media from both those who worked with Williams and those who admired him for his trailblazing roles and impactful performances.

“Tales from the Hood” director Rusty Cundieff tweeted that his sadness over Williams’ passing, “cannot be overstated. His artistry and sheer coolness was extraordinary. I will forever be in his debt for his brilliant performance in Tales From the Hood. Loved working with him! Blessed travels good sir!”

Lenny Kravitz wrote on Twitter, “When I was a kid growing up in NYC Clarence Williams III was a face on TV that I identified with and that inspired me. From the Mod Squad, to Purple Rain and Sugar Hill, he always performed with dynamic energy. Rest in power, king.”

FORMER PARATROOPER

Director Peyton Reed tweeted that he worked with Williams on the TV movie “The Love Bug” in 1995.

“I had grown up watching him as Linc in `The Mod Squad’ and thought he was the epitome of cool. Turns out he was. Rest In Peace, Clarence,” Reed wrote.

A native of New York, Williams career spanned over five decades in theater, television and film. He was born into a creative family in 1939 and  raised by his musical grandparents. His grandfather was a jazz composer and pianist, his father a musician and his mother, Eva Taylor, a singer and actress. He got his acting start on Broadway after a stint as a paratrooper and received a Tony nomination for his role in William Hanley’s “Slow Dance on the Killing Ground” in 1964.

His breakout role would come with “The Mod Squad,” which he led with Peggy Lipton and Michael Cole. Bill Cosby had seen Williams perform and told Aaron Spelling he should consider him for the role of Linc. The show ran from on ABC from 1968 through 1973. A trailblazing show for attempting to portray the hippie generation of the time, “The Mod Squad” was a star-maker for all three. But roles were not quick to follow for Williams.

He appeared on Broadway opposite Maggie Smith in Tom Stoppard’s “Night and Day” in 1979 before getting cast as the troubled father in “Purple Rain,” which came out in 1984.

ONLY FOUR LINES

Director John Frankenheimer would become a frequent collaborator. They first teamed up for his adaptation of Elmore Leonard’s “52 Pick-Up” at a time when Williams was not having much luck in Hollywood and crashing on Cosby’s couch to keep a roof over his head.

“He asked me to read for the part of one of the blackmailers, but after only four lines, he told me to stop,” Williams recalled in a 1999 interview. “I thought it was all over, but he said, `Have your agent call me. It will be a 10-week shoot. Thank you for coming in.’ That was it.”

Williams also appeared in Frankenheimer’s “Against the Wall,” “Reindeer Games” and some episodes of “Tales from the Crypt.”

Williams could command a variety of genres, including comedy. He played a drug lord opposite Dave Chappelle in “Half Baked” and stole scenes in Keenen Ivory Wayans’ blaxploitation parody film “I’m Gonna Git You Sucka.” He also had a recurring role as the FBI agent in David Lynch’s “Twin Peaks” who tells Agent Cooper he’s been suspended.

“SQUAD” YEARS

Other film roles included “Tales from the Hood,” “Deep Cover,” “Sugar Hill, “The General’s Daughter,” Lee Daniels’ “The Butler” and an uncredited role in “American Gangster.” And he had many, many television appear-