It may sound like the scene out of an action movie, but it was all too real.

Two deputies in California's San Mateo County pulled a man from his car on Monday night right before a train crashed into the vehicle. No one was hurt.

The deputies have been identified as Lance Whitted and Erik Rueppel. They raced to the scene after hearing a car crash into a crossing post.

Whitted, who pulled the driver away by the wrists, took the whole matter in stride, telling the Contra Costa Times, "That's why we become police officers and deputy sheriffs, to help people. And you can't help anyone anymore than saving their life."

The man in the car has been identified as Nelson Gomez, 20.

You can see the rescue from another angle in the video below.

It's not clear why Gomez was on the tracks, although it appears he may have been under the influence. He was cited for driving under the influence, hit and run, violating his probation and driving without a license.

More From AM 1050 KSIS