SOUTHBOROUGH, Mass. — A college baseball pitcher who'd been a standout high school player in New Jersey was struck and killed by a train in Massachusetts early Sunday morning.

Massachusetts Bay Transportation Authority Police said Dan Cooney, 20, a sophomore at Babson College in Wellesley, Massachusetts, was along the right of way and was hit by a CSX freight train in Southborough around 1:30 a.m. He was from Verona, New Jersey. The MBTA described him a as "trespasser," a term transit agencies use to describe someone who was not authorized to be present in a dangerous area.

Cooney was a 2015 graduate of St. Peter's Prep in Jersey City, according to his bio on the Babson website. NJ.com named Cooney the Hudson County Interscholastic League Player of the Year. with a .547 batting average and 4-1 record including 20 strikeouts.

"We are shocked and saddened to hear of the passing of Daniel Cooney. He was a well-regarded member of the Babson undergraduate community," Babson College spokesman Michael Chmura said in a statement. "The college has reached out to his family members during this difficult time. Our thoughts and prayers are with them and with his classmates and friends."

Chumura said counselors were available on campus.

"It is with profound sadness that we face the loss of Dan Cooney. Dan was the type of young man that every parent prays their son will have as a friend. I will forever be grateful for the time Matt had him in his life as a friend, teammate and mentor. Prayers for strength for the Cooney family. Rest easy Dan. You are already greatly missed," Kim Ferrara McDermott wrote on Facebook.

St. Peter's, in a message sent to New Jersey 101.5, said its community was "shocked and saddened by the passing of Dan Cooney from the Class of 2015."

"Dan was the whole package at Prep — an outstanding student who earned a merit-based Ignatian Scholarship as an incoming freshman, and an All-State baseball player and team captain whose leadership was instrumental in winning the Hudson County championship in his senior year. Most importantly, throughout his Prep career he exemplified the Jesuit ideal of being a 'man for others' ... and for that we are most proud," the school said.

Contact reporter Dan Alexander at Dan.Alexander@townsquaremedia.com.

More from New Jersey 101.5

Sign up for the NJ1015.com Newsletter

Get the best of NJ1015.com delivered to your inbox every day.