William Shatner will star in the independent romantic comedy “Senior Moment.”

Giorgio Serafini is directing from a screenplay by Kurt Brungardt and Christopher Momenee. Rene Sheridan and Gina G. Goff are producing.

Shooting will start in the late spring in Palm Springs, Calif.

Shatner plays a retired Top Gun Navy pilot who tested aircraft for NASA. After speeding around town in his vintage convertible hot rod with his best friend in tow, he gets caught in a major crackdown to get dangerous senior drivers off the road, resulting in his car being impounded and his license revoked.

“I’m thrilled to be working with this group of talented people,” Shatner said. “I’m really looking forward to making a wonderfully funny movie.”

Shatner is best known for appearing in the original “Star Trek” TV series and the first seven “Star Trek” movies as Captain James T. Kirk. He also won two Emmys for his role as Denny Crane in the series “Boston Legal.”

“William Shatner is an amazing actor and legend,” Goff said. “We could not be happier to be working with him.”

Serafini has directed numerous European TV series, including the Italian show “Orgoglio,” along with the feature “Johnny’s Gone” and the documentary “Sin Fronteras/Without Borders.”