Police on Tuesday arrested a man accused of opening fire at a child's birthday party, killing a woman and her 5-year-old granddaughter.

Authorities said Erick Daniel Davila, 21, was arrested on a capital murder warrant, a charge that carries the death penalty.

Officers followed Davila after seeing him at an apartment complex, but he tried to get away by driving through another complex where he hit some cars, crashed into a fence and then ran away while carrying a gun before he was caught by SWAT officers, said police Lt. Paul Henderson.

Davila was being questioned by police and had not been booked into the jail as of late Tuesday afternoon, according to a jail employee. It was unclear if Davila had an attorney.

Investigators are still trying to determine why a man driving by the duplex Sunday night got out and started firing multiple shots while Annette Stevenson was hosting a party for one of her granddaughters, Henderson said. Police believe the house was targeted, he said.

Stevenson, 48, died at the scene and Queshawn Stevenson, 5, died at a hospital early Monday morning.

Another woman and three other children, including the birthday girl who turned 9 on Monday, were wounded. Information on their conditions was not available Tuesday, but relatives have said their injuries were not life-threatening.

Davila was released from prison on mandatory supervision in August after serving a little more than a year for a 2004 burglary in Tarrant County, according to the Texas Department of Criminal Justice.

He then had to report to the Tarrant County Sheriff's Office because of an earlier marijuana possession charge from 2006 before he was sent to prison. He was convicted late last year and sentenced to 60 days in jail, but it's unclear if he spent any time behind bars or was credited for time already served, according to the Sheriff's Office.