A man died from a self-inflicted gunshot wound at Universal Studios in California on Friday afternoon, authorities said. The incident, which is considered a possible suicide, reportedly took place near the Despicable Me Minion Mayhem ride. The man was pronounced dead at the scene, and his name was not released.

The shooting occurred shortly after 2 p.m., according to Los Angeles County Sheriff's Department spokeswoman Nicole Nishida, the Los Angeles Times reported. Investigators plan to question witnesses near the scene and check surveillance footage.

Authorities said the man’s ex-girlfriend, who works as a waitress at the park, had notified security after seeing him there on Friday, the Associated Press (AP) reported. "We know he and his girlfriend have been estranged since February," sheriff's homicide bureau's Lt. Eddie Hernandez reportedly said. "She had a restraining order against him, and today she saw him outside the restaurant and she alerted security."

When an officer approached the man in a secluded smoking area near the ride, he reportedly pulled out a gun and shot himself, despite the officer's efforts to talk him out of harming himself.

The restraining orders prevented the man from contacting his former girlfriend, after two separate incidents at the park, including one where he reportedly vandalized the woman’s car in a parking lot.

Universal Studios said in a statement they would remain open and cooperate with authorities. "The safety and security of our guests is always of the utmost importance," it said, according to the AP.