A Denver man who was shot by a Douglas County Sheriff’s deputy, as he approached the lawman while holding an AR-15 rifle, has been sentenced to 16 years in prison.

Deyon Rivas-Maestas, 26, pleaded guilty Feb. 5 to felony first-degree assault — threatening a peace officer with a weapon, according to the district attorney’s office.

On Tuesday, District Judge Shay Whitaker sentenced Rivas-Maestas to the maximum term allowed as part of a plea agreement.

“It is important for the officers, for the community, for the state to know that actions such as these cannot be tolerated,” Whitaker said in a news release. “It is important to this court to let the people of the

community know that their officers need to be safe, and the officers need to know these situations will be taken seriously.”

On May 12, 2017, Deputy Brad Proulx, a six-year veteran who was on patrol, stopped when saw what appeared to be a disabled white GMC Yukon on the roadside near East County Line Road and South Santa Fe Drive.

As Proux walked around the SUV, Rivas-Maestas, holding a rifle, suddenly appeared. Proulx immediately fired his service weapon, hitting Rivas-Maestas in the arm. The encounter was caught on video by the deputy’s body camera. The 18th Judicial District Attorney’s Office determined Proux was justified in the shooting.

Since the incident, Rivas-Maestas, who was free on bond, was arrested in Denver on a drug charge. Since the drug arrest, he has tested positive for methamphetamine, according to a new release.

“This case was outrageous. We are lucky neither the public nor the deputy was injured. Given the quick reaction of the well trained deputy, Rivas-Maestas is lucky he isn’t dead,” said District Attorney George Brauchler. “The message is clear: Attack one of our guardians, and the best for which you can hope is to go to prison.”