Boston police attempting to stop a man on a motor scooter instead made an arrest in connection to an earlier carjacking after finding two suspects running through Trotter Park.

Around 1:00 a.m. on Sunday, officers tried to stop a man on a motor scooter for riding without a helmet or headlight, but they lost sight of the driver after he entered Roxbury’s Trotter Park on the scooter, police reported. While at the park entrance, police saw two other men running toward them.

RELATED: Police seek suspect who fled after car chase crash: Report

Authorities stopped the two running men for trespassing in the park and conducted a pat frisk for safety, during which officers found a large knife on 25-year-old Cody Brown of Dorchester, police stated. As officers were speaking with the men, the scooter rider whom they had originally followed returned to the park entrance.

The man on the scooter explained to officers that the two other men had carjacked him earlier in the evening while he was sleeping in his SUV, according to police. He alleged that the two men had dragged him out of his vehicle by his shirt, assaulted him and drove away in the SUV, leading him to borrow a friend’s scooter and go searching for the suspects.

RELATED: Police: Man passed out in car in Dorchester had stolen gun, bottle of beer on him

Officers then recovered the key to the victim’s SUV in Brown’s pants pocket, authorities added. Both Brown and the other man, Raquawn Givens, 20, of Dorchester, were arrested and charged with armed carjacking and trespassing, with Brown additionally charged with weapon possession and Givens charged with drug possession after officers found 20 Xanax pills on him.