Matthew Riehl (Douglas County, Colo., Sheriff’s Office/AP)

A Colorado man who shot and killed a deputy sheriff on New Year’s Eve spent hours leading up to the shoot-out taping himself and posting to social media. But it didn’t stop there—before police killed him, Matthew Riehl also livestreamed the deadly gun battle, CBS News reports.

Riehl, a 37-year-old Iraq War veteran, also had a history of suspicious and harassing behavior, including targeting a Douglas County, Colo., police officer in the weeks prior to the ambush, according to CNN.

On Sunday, Riehl called 911 to report problems with another man whom Riehl called his “domestic partner.” But when deputies arrived at Riehl’s apartment in Highlands Ranch, Colo., he had barricaded himself in. CBS Denver, which reviewed the footage, reports that Douglas County deputies initially tried to coax Riehl into opening the door; Riehl told the officers that he was assaulted before telling the cops to “go away” and saying that he wanted the “civil division.”

Four sheriff’s deputies returned to Riehl’s apartment later, when Riehl asked one of the officers, “What’s your name?” before immediately opening fire on the officers. It’s unclear when a SWAT team became involved in the shooting, during which Riehl unloaded 100 rounds and killed one person, Sheriff’s Deputy Zackari Parrish, and injured four others.

Advertisement

According to the New York Daily News, which cites KDVR-TV and KUSA-TV, Riehl captured everything on Periscope. The shoot-out was so intense, it triggered a smoke alarm. Riehl died in the gunfight.

But as CNN reports, officials say that Riehl was no stranger to several law enforcement agencies.

Following a November traffic stop in a Denver suburb, Riehl wrote harassing posts and emails targeting local police officers. Riehl’s alma mater, the University of Wyoming, also issued a warning late last year alerting the campus to Riehl’s behavior.

Advertisement

Citing a letter sent to faculty and staff in November, CNN reports that campus police and the Laramie Police Department were alerted to Riehl’s “rambling, nonsensical messages on his Facebook page.” University of Wyoming faculty was also asked to get in contact with police if Riehl was seen on campus.