When director Gary Gray was standing on an L.A. street filming “Straight Outta Compton” he got a call from an irate Suge Knight.

According to detectives. Knight was mad about the way he was being depicted in the film and that he was not getting paid.

The phone call ended when Gray hung up on Knight. There were two other phone calls but Gray ignored them both. That’s when he got the text message.

“I will see u in person … u have kids just like me so let’s play hardball,” Knight, 52, wrote, before signing off with a couple of expletives and a racial slur.

Gray was terrified and it appears he still is. According to court transcripts, he repeatedly claimed on the stand that he couldn’t remember anything about the messages. At one point in his testimony, he seemed to have trouble recalling details of the film even though he directed it and it was nominated for an Academy Award.

Deputy District Attorney Cynthia Barnes told the grand jury that the director’s testimony showed just how much fear Suge Knight was able to instill in people.

“He’s so afraid he came in here and lied under oath,” Barnes stated. “He’s perjuring himself because he’s that afraid.”

The hearing took place in February even though the transcripts are only being released now. After the hearing, Knight was indicted on a charge of threatening Gray with death or great bodily injury.

Prosecutors argue that Knight’s rage over the film is part of why he ran over two men, killing Terry Carter and injuring Cle “Bone” Sloan in January 2015.

Knight claims he was acting in self-defense and says that Dr. Dre paid $20,000 to have him killed. He also claims that the hitman was there the day he ran over those two men.

The text messages to Gray in August 2014 show Knight using gang terminology and making reference to other N.W.A members.

“I’m from Bomton,” Knight texted, using Bloods slang. “I’m a Blood criminal street gang member from the city of Compton … Time has arrived Faith in God keep ppl safe. The Devil’s Money can’t save No 1.”

He went on to say that he would “make sure” that Gray, Young and Ice Cube would receive “hugs” more slang for physical violence.

When Gray called police to the set, they found him “extremely agitated as well as extremely frightened,” according to police. They were told that Knight threatened Gray’s family and coworkers because he was not happy with his portrayal in the film.