Felipe Vazquez, a former relief pitcher for the MLB outfit Pittsburgh Pirates, was sentenced on Tuesday to at least two years behind bars for statutory sexual assault and child pornography, among other charges, in a case involving a girl who was 13 when the encounters began.

Vazquez, 30, was sentenced to two to four years. He has already served almost two years in jail and will be eligible for a parole hearing one month after arriving in prison, the Pittsburgh Post-Gazette reported.

Prosecutors said the former All-Star closer was in touch with the girl by text message from 2017 to 2019, the same years he played for Pittsburgh, and once met her outside a home in Scottdale, southeast of Pittsburgh, where, investigators say, he told them he tried to have sex with her.

The girl testified in court that they had sex in his car outside her home hours before a Pirates game, the New York Post reported. They struck up a relationship on social media and Vazquez’s defense had argued that the girl misled him about her age.

The girl’s mother found their communication after the family had moved from Pennsylvania to Florida. Vazquez was arrested in September 2019 and is also facing related charges in Florida and Missouri.