Though Marine Matias Ferreira lost both legs in an IED explosion in Afghanistan, that didn’t stop him from rushing to the scene of a car accident and pulling a baby girl from the rubble.

Ferreira was driving home from his wedding rehearsal in Queens when he heard a woman scream, “My baby, my baby!”

A car had struck a median pole, and both the child and her parents were trapped in the smoking vehicle. As a father of a young daughter himself, Ferreira felt compelled to leap out of his truck and dash to the wreck.

“With the Marines, you are taught to be prepared and act,” Ferreira told the New York Daily News. “Instinctively you just react, you don’t freeze, and thankfully we were able to make a difference.”

Ferreira was traveling with his brother and fiance’s father, who helped the trapped parents get to safety. Meanwhile, Ferreira carefully extracted the baby.

“I didn’t hear the baby crying, so I got kind of concerned,” Ferreira said. “Then I saw her open her eyes, and it kind of reassured me she was doing better.”

They waited at the wreck until first responders arrived on the scene.

Ferreira is a Paralympic athlete and a member of the Wounded Warrior softball team. During his military service, he was a machine gunner with the 1st Battalion 8th Marines. The accident that cost him his legs occurred during his very first deployment in 2011.