PORTLAND, Maine (AP) — A Maine man accused of placing a gun to the neck of a sheriff's deputy and pulling the trigger has been convicted of murder.

Both sides agree that defendant John Williams fired the shot that killed Cpl. Eugene Cole last year. The trial focused on his state of mind.

The defense contended Williams' drug use and lack of sleep left him too impaired to meet the legal standard for intentionally killing Cole.

But Deputy Attorney General Lisa Marchese said Williams understood what he was doing and the consequences of his actions.

The jury delivered the guilty verdict Tuesday afternoon.

Cole was shot when he tried to arrest Williams during a late-night encounter on April 25, 2018, in Norridgewock. Williams was arrested several days later outside a cabin after a manhunt.