LOS ANGELES — Chris Evert and Lindsay Davenport are taking a swing at acting as guest stars on “CSI.”

Some script revisions were in order, though, when the retired tennis champions shot their scenes.

Evert, Davenport and tennis commentator Justin Gimelstob all play themselves on Wednesday’s episode of the CBS series starring Ted Danson and Elisabeth Shue, a friend of Evert’s.

According to Evert, the original script called for Davenport to find the body of a female pro player that sets the episode in motion.

Evert recalled thinking: “Oh my God, Lindsay has a scene where she has to act.”

“She never likes attention,” Evert said.

Davenport read the script and said, “I had a panic attack. I was like, ‘There’s no way.’ ”

By the time Evert arrived at Calabasas Tennis Club for filming, Gimelstob was being fingered as the suspect.

“Most things that come to me that are outside my comfort zone are things that I don’t want to do,” Davenport said. “You either have that personality or you don’t.”

Gimelstob egged both Evert and Davenport on, although Evert didn’t need too much persuasion.

She hosted “Saturday Night Live” in 1989 and played a commentator in the movie “Wimbledon.”