The suspect in the Santa Fe High School shooting in southeastern Texas said he did not shoot people he liked and meant to kill the students he targeted, according to a probable cause affidavit.

Dimitrios Pagourtzis, 17, allegedly used a shotgun and a revolver to kill 10 people and injure 10 others. He has cooperated with police, Galveston County Magistrate Mark Henry told CNN.

In a video court hearing, Pagourtzis answered “Yes, sir,” when asked if he wanted a court-appointed attorney but did not say much more, CNN reported. Henry denied bail for Pagourtzis, who is accused of capital murder of multiple people and aggravated assault on a public servant.

The student was not asked to enter a plea, CNN reported.

According to the affidavit, Pagourtzis told an investigator that he spared people he liked because he wanted his story told.

Police said Pagourtzis was armed with a shotgun, a .38 revolver and explosives when he opened fire at the school, KHOU reported.

Texas Gov. Greg Abbott said Pagourtzis had planned to kill himself but instead surrendered, calling him a coward, KHOU reported.