A teenager is facing serious consequences after ramming into a police car and breaking an officer’s leg.

Benjamin Saurini, 19, says he had trouble seeing out of his windshield on Friday because of the pot smoke fogging up his car windows. Saurini admitted he was trying to flee police near Melbourne, Australia, after smoking cannabis in the car with some friends.

Driving away from the scene, he panicked and side-swiped a police cruiser—pinning a senior constable against the car and breaking the officer’s leg. The constable is still in the hospital after undergoing surgery on Monday.

The day after the accident, Saurini saw a newspaper article about the injured cop and realized he was in trouble. He allegedly tried to get rid of the car and its plates so it couldn’t be identified, reports 7 News.

But the teen—who doesn’t have his driver’s license yet—agreed to turn himself in after officers called his parent’s house in Sunbury, about 25 miles from downtown Melbourne. Saurini must now follow an 8pm curfew and agree to no longer drive or take drugs.

He initially faced 14 charges, including ramming an emergency vehicle, assaulting a police officer, conduct endangering life and unlicensed driving. Instead, he will participate in a drug education program with strict requirements, including weekly check-ins with police and an agreement not to associate with anyone else involved in the incident.

Saurini’s father, John, told the court he discovered Benjamin was using drugs about three years ago, but only realized he had a problem eight months ago.

Medical marijuana is legal across Australia with a prescription, but recreational use is still prohibited.

In the U.S., where 11 states have legalized recreational marijuana, there have been scattered arrests of stoned drivers. As marijuana legalization spreads across the country, more police departments are working to change the perception that it’s okay to drive under the influence of cannabis.

The stakes are high: a 2018 Colorado Department of Transportation study found that, after legalization, highway deaths in Colorado involving drivers with marijuana in their system increased from 75 in 2014 to 139 in 2017.

On the other hand, the number of drivers who were over the legal limit for marijuana (5 nanograms) decreased from 52 to 35 during the same period.

According to a 2018 Gallup poll, a majority of Americans support legalizing marijuana.