Disney Channel star Selena Gomez.

Selena Gomez at the 53rd Annual Grammy Awards held at the Staples Center on February 13, 2011 in Los Angeles, California. (Photo By Kirk McKoy / Los Angeles Times)

Disney star Selena Gomez has obtained a restraining order against a 46-year-old man who allegedly planned to kill her based on conversations he had with God.

Los Angeles County Superior Court Judge William Stewart last week ordered Thomas Brodnicki, whose residence is listed as Los Angeles hotel, to stay at least 100 yards away from Gomez, her parents and an assistant.

In court documents, Gomez said she feared Brodnicki “will harm them in his attempts to see me or to harm or kill me.”

Brodnicki allegedly has a long history of mental illness.

The 19-year-old "Monte Carlo" and "Wizards of Waverly Place" star and girlfriend of teen heartthrob Justin Bieber told the court, which issued the temporary restraining order Oct. 13, that Brodnicki visited her workplace at least three times.

The Los Angeles Police Department’s Threat Management Unit was also taking Brodnicki’s threat to kill Gomez “extremely seriously,” due to his history of stalking, criminal threats, visits to Gomez’s workplace and mental illness, according to court records.

Brodnicki allegedly traveled from Chicago to Los Angeles in September to meet Gomez, but police placed him on a 72-hour mental health hold after he told passersby that he would “scratch people’s eyes out,” according to court records.

During the detention, Brodnicki allegedly told a doctor that he had thoughts of hurting and killing Gomez. The doctor reported Brodnicki’s threats to police because he “presented a serious danger of violence” to Gomez, according to court records.

A hearing regarding the temporary restraining order is scheduled for Nov. 4 in the Burbank courthouse.

ALSO:

'Hannah Montana' actor arrested in Burbank for alleged DUI

-- Veronica Rocha, Times Community News

Twitter: @VeronicaRochaLA