CHICAGO (STMW) — Bond was set on Saturday at $500,000 for a reputed gang member charged with attempted murder after he allegedly shot and wounded an off-duty police officer and sent a bullet through the officer’s car window — narrowly missing the officer’s 2-year-old son.

The 34-year-old officer, had just gotten out of his car and was about to take his son out of a car seat early Monday near 63rd and Nashville when police say Mario Froylan, 27, approached and announced a robbery before a gun battle ensued.

About 10 shots were fired: three of them hit the officer, and police believe at least one hit Froylan, who fled in a car to a relative’s house in Westmont. Through information offered by an informant to police in Summit, officers were able to track Froylan down, Chicago Police Supt. Garry McCarthy said at a news conference Saturday.

“It could have been much worse, and in fact, there’s a bullet hole in the window of the officer’s car, right in the vicinity of where his child was,” McCarthy said.

“This offender does not have a violent history, but he apparently made some sort of leap,” he said of Froylan.

“This is the eighth officer who’s been shot since I’ve been here,” said McCarthy, who spoke in frustration about gun violence. “The fact is, something’s got to change.”

The injured officer was lucky to be alive and wanted to get back to work out of concern for his partner, he said.

Froylan, of Summit, was also charged with attempted armed robbery and aggravated battery with a firearm. His next scheduled court appearance is on Monday at 26th and California.