William Schallert, a familiar presence on prime-time television for decades, notably as the long-suffering father and uncle to the “identical cousins” played by Patty Duke on the hit 1960s sitcom “The Patty Duke Show,” died on Sunday in Pacific Palisades, Calif. He was 93.  His son Edwin confirmed the death.  Mr. Schallert’s career spanned generations and genres. Over more than 60 years he racked up scores of credits in episodic television as well as noteworthy performances in motion pictures, on the Off Broadway stage and as a voice-over artist.  With his preternaturally mature, intelligent but (by Hollywood standards) unremarkable looks, he was cast almost from the beginning as an authority figure — a father or a teacher, a doctor or a scientist, a mayor or a judge. Most active from the 1950s through the ’80s, Mr. Schallert remained seemingly unchanged in appearance and persona over time, and he was still working in his 90s, dismissing any thoughts of retirement.  On television it sometimes seemed as if he was everywhere. A versatile character actor with a comforting presence, he was equally at home in comedies and dramas, with a résumé ranging from “Leave It to Beaver,” “The Twilight Zone,” “Dr. Kildare” and “The Wild Wild West” to “Melrose Place,” “True Blood” and “Desperate Housewives.”  Before joining the ranks of harried sitcom fathers as Martin Lane on “The Patty Duke Show” (1963-66), he was the equally harried teacher Leander Pomfritt, bane of the title character, on “The Many Loves of Dobie Gillis” (1959-62). He also earned a permanent place in the hearts of “Star Trek” fans in 1967 when he played Nilz Baris, under secretary in charge of agricultural affairs for the United Federation of Planets, in “The Trouble With Tribbles,” often cited by fans and critics as one of the best episodes of the original “Star Trek” series.  Never a leading man, Mr. Schallert was instead a high-caliber embodiment of the working actor.  In an interview for this obituary in 2009, Mr. Schallert said he had never been particularly selective about the roles he played. “That’s not the best way to build a career,” he admitted, “but I kept on doing it, and eventually it paid off.”  While the typical William Schallert character was focused and serious, he expressed particular affection for an atypical role: the wildly decrepit Admiral Hargrade, a recurring character on the spy spoof “Get Smart” (1967-70), who operated in a perpetual state of confusion. (“He reminded me of my grandmother when she got dotty,” Mr. Schallert said.)  His film career, which began in 1947 with small roles in “The Foxes of Harrow” and “Doctor Jim,” was memorable at first for its kitsch value. He made his mark playing intense doctors and scientists in science-fiction fare like “The Man From Planet X” (1951), “Gog” (1954) and “The Incredible Shrinking Man” (1957). Years later, the director Joe Dante paid tribute to Mr. Schallert’s cinematic roots by casting him in his valentine to 1950s schlock cinema, “Matinee” (1993), where he was seen in the film within the film, a black-and-white horror sendup called “Mant.”  He went on to play more substantial screen parts, particularly as the small-town Mississippi mayor in “In the Heat of the Night” (1967) and as the judge in “The Trial of the Catonsville Nine” (1972). He had won an Obie Award for playing the same role in the Off Broadway play on which that movie was based, drawn from the trial of nine Roman Catholic activists who burned military draft files in Maryland in 1968 to protest the Vietnam War. (One character, and actual participant, was the Rev. Daniel Berrigan, who died on April 30.)  Behind the scenes, Mr. Schallert was the versatile voice of various characters in the cartoon series “The Smurfs,” animated characters in commercials, and Abraham Lincoln at the Abraham Lincoln Presidential Library and Museum in Springfield, Ill.  Mr. Schallert was president of the Screen Actors Guild from 1979 to 1981, a bitter period in its history highlighted by a protracted 1980 strike over rates and residuals for cable and satellite television and home video. Resentment over the final settlement ran high, and when he ran for re-election in 1981 he was defeated by Edward Asner, although Mr. Asner had no experience as a board member or officer. (Mr. Schallert’s former television daughter Patty Duke was president of the union from 1985 to 1988. Ms. Duke died on March 29.)  William Joseph Schallert was born on July 6, 1922, in Los Angeles. His father, Edwin Francis Schallert, was a longtime critic and drama editor for The Los Angeles Times; his mother, the former Elza Emily Baumgarten, was a celebrity journalist and radio commentator.  He attended the University of California, Los Angeles, with the intention of becoming a composer, studying at one point under Arnold Schoenberg. But, he said, he came to the conclusion that he could not “work fast enough to make a living” in music, and his interest turned to acting. He found his father’s name helpful in opening doors in Hollywood.  Mr. Schallert became active in theater while a student and in 1946 was a founder with the actor Sydney Chaplin and others of the highly regarded Circle Theater in Hollywood, where he appeared in a production of W. Somerset Maugham’s “Rain” directed by Mr. Chaplin’s father, Charlie Chaplin.  In 1952, Mr. Schallert traveled to Britain on a Fulbright Fellowship to study British repertory theater. He was a guest lecturer at Oxford before returning to Los Angeles.  He married Rosemarie Diann Waggner, an actress known professionally as Leah Waggner, in 1949. She died last year. Besides his son Edwin, he is survived by three other sons, Joseph, Mark and Brendan, and seven grandchildren.  Looking back on his career in 2009, Mr. Schallert was philosophical. “I’ve never been single-minded in my pursuit of acting as a career,” he said. “Whatever it was that got me hired and kept me working probably was just me.”  A version of this article appears in print on May 10, 2016, on page B9 of the New York edition with the headline: William Schallert, 93, Dies; Played ‘Patty Duke’ Father. Order Reprints| Today's Paper|Subscribe
For a time Mr. Schallert seemed to be everywhere on TV, usually as an authority figure, as he was in the popular “Tribbles” episode of “Star Trek.”