Former major league players Luis Valbuena and Jose Castillo were killed in a car crash in Venezuela caused by highway bandits who then robbed them, officials said on Friday.

The 33-year-old Valbuena and 37-year-old Castillo died late on Thursday when their SUV crashed as it tried to veer around an object on the road, Yaracuy state governor Julio Leon Heredia said on his Twitter account. Officials said some bandits place or throw objects on highways to force vehicles to stop or crash so they can rob the occupants.

Heredia said four people have been detained after being found with property of the athletes.

Valbuena and Castillo were teammates on the Cardenales de Lara team in the Venezuelan winter league and were returning from a game in the capital when the crash occurred en route to the city of Barquisimeto.

Third baseman Carlos Rivero was in the car and survived, according to the website beisbolplay.

Valbuena, an 11-year major league veteran, hit .199 with nine homers and 33 RBIs in 96 games this year for the Los Angeles Angels, who released him on 7 August.

“I will miss Luis’s banter, smile, genuine love for his teammates, and, of course, the bat flips,” Astros manager AJ Hinch said in a statement. “He was a beloved person whether he was on our team or across the field.”

Valbuena hit .226 with 114 home runs over 11 big league seasons with the Angels, Seattle, Cleveland, the Chicago Cubs and Houston.

“Luis was always smiling and was one of the happiest players in baseball,” Astros general manager Jeff Luhnow said. “He provided joy to his teammates and our fans. He helped our franchise turn a corner in 2015 and provided many cherished memories.”

Castillo played five seasons with Pittsburgh, San Francisco and Houston. He had a .254 average with 39 home runs.

Venezuelan President Nicolas Maduro said in a tweet: “I join in the mourning that has overwhelmed the Venezuelan baseball family and all of its fans.”

Baseball commissioner Rob Manfred issued a statement calling it “a very sad day for our sport”.

“It is clear by all the stories today that they loved baseball and made an impact on their teammates and the clubs they represented,” he said, expressing “my deepest condolences to their families, friends and fans, particularly those in their native Venezuela”.

On Friday afternoon, the coffins with the players’ bodies arrived in Antonio Herrera Gutierrez stadium in Barquisimeto where they were received amid tears by their teammates. A mass was held to bid them goodbye.

The Venezuelan professional baseball league announced all three scheduled games Friday were cancelled and it said flags will fly at half-staff in all stadiums for three days.

League president Juan Jose Avila told Union Radio players may be forbidden from using private cars to move between games, saying if the players had been on the team bus, “nothing would have happened to them”.

Venezuelan teams generally travel in buses protected by security forces.