JOLIET (CBS) –– An Indiana man who forced his way into his former girlfriend’s house last year and held police at bay with a gun has been sentenced to 17 years in prison.

Richard Petrick, 49, pleaded guilty in April to aggravated assault, aggravated stalking and home invasion.

Will County Circuit Judge Daniel Rozak sentenced Petrick on Wednesday.

Will County Sheriff’s Deputy Christopher Cavera had been called to the victim’s residence in Frankfort Square on the evening of Feb. 12, 2010 in response to a report that Petrick was driving by her home.

The victim had an order of protection filed against Petrick.

Deputy Cavera witnessed the defendant drive past the residence again. He was unable to apprehend the defendant initially, but he continued to patrol the area during his shift.

Later that same night, Deputy Cavera found the defendant parked outside the victim’s residence with a small arsenal in his vehicle.

Inside Petrick’s car he found a pellet gun, a 10-inch hunting knife, a Winchester rifle, a .22 caliber semiautomatic rifle, a box of ammunition and a pair of binoculars.

Petrick was in violation of an order of protection and charged with aggravated stalking for that incident.

On April 9, 2010, while Petrick was on bond for aggravated stalking, his former girlfriend smelled cigarette smoke outside her residence and saw him hiding in the bushes about 6 a.m.

The woman ran into her house, locked her doors, dialed 911 and hit a panic button on her home alarm system when she saw Petrick.

The defendant used a pellet gun to shoot through the sliding glass door, entered the residence and threatened to kill the woman.

The victim managed to run out the front door. Her adult daughter, who lived in the residence, jumped from a second-floor bedroom window onto a car parked in the driveway to escape.

After deputies responded, Sgt. Thomas Budde saw the defendant hiding behind a wall inside the home and ordered him to drop the weapon. Petrick refused, telling police they would have to shoot him. As Petrick pointed his weapon at deputies, Sgt. Budde fired, shooting him in the eye.

Watch & Listen LIVE