Ch Insp Matt Holdsworth said the shooting was “an isolated incident” and officers were not looking for anyone else in connection with it.
He said: “This is a very serious incident which has sadly resulted in a young man losing his life.
“I am still keen to speak to anyone who saw anything suspicious in the area at around 21:30 on Thursday, or who may have CCTV or ring doorbell footage that could help with the investigation.
Mr Batty’s family have been informed and are being supported by officers, he added.
According to police, Mr Batty and two other men had gone to the property and forced their way inside when a firearm was discharged, resulting in his death.
A silver Peugeot Partner van was found burnt out on Dove Valley Way, Barnsley, at about 23:00 on Thursday.
Officers urged anyone who saw the vehicle in the Barnsley Road area of Hemsworth or in the Dove Valley Way area of Barnsley to contact police.