From the first minutes after a gunman began shooting, officers descended on Robb Elementary School. Local police from the town of Uvalde. County sheriff’s deputies. Agents from the federal Border Patrol.

But none of the growing number of agencies had control over the scores of officers at the scene on Tuesday of what would become the deadliest school shooting since the massacre at Sandy Hook Elementary School a decade ago.

That fell to the chief of a small police department created only four years ago to help provide security at Uvalde’s eight schools. Its chief, Pedro Arredondo, had ordered the assembled officers to hold off on storming the two adjoining classrooms where the gunman had already fired more than 100 rounds at the walls, the door and the terrified fourth graders locked inside with him, the state police said.