Updated

The violence that culminated in a mass shooting Tuesday began five days earlier when police say Kori Ali Muhammad shot an unarmed security guard at a Motel 6, who he said disrespected him while he visited a female friend at the hotel.

Muhammad shot the guard, 25-year-old Carl Williams, multiple times at close range shortly after 11 p.m., police said.

Then the 6-foot-1-inch, 220-pound Muhammad ran behind the motel and climbed onto the roof of a nearby 7-Eleven, where he hid out that night. Friday morning, he watched police officers investigate the crime scene and by evening he was in a ravine, where he told police he conducted voodoo rituals for three days.

Police say Muhammad gave rare and unusual details about his movements and the killings over several hours of questioning following his arrest, even returning with officers to the crimes scenes and demonstrating his actions.

"As he spoke about the shooting and shooting individuals, he did so in a very callous manner," Fresno Police Chief Jerry Dyer said.

Muhammad, 39, told investigators he is Muslim but prays to seven different gods.

After emerging from the ravine Sunday, he cut his braided hair and burned it, altering his appearance from the "wanted" photos police were soon to release in a manhunt for him in the death of the security guard.

On Tuesday, Muhammad headed over to a store called The Brass Unicorn in search of crystals to use for more rituals. But it was closed, so he stopped at a Starbucks where he got on the internet for the first time since Thursday night and learned he was a suspect in the guard's murder.

"Once he saw that he was wanted for murder, he was not going to go down for shooting a security guard for disrespecting him but that he was going to kill as many white males as possible," Dyer said.

Shortly before 11 a.m., he approached two men sitting in a PG&E truck on a tree-lined street in downtown Fresno. He told police he noticed the driver was Latino and the passenger was white so he shot four rounds into the passenger side. Zackary Randalls, 34, died.

In the next three minutes, police say Muhammad killed two more people and shot at several others, shooting 16 rounds of bullets on a stream of people who happened to be in the wrong place.

Muhammad shot at another white man who had just walked out of a house, but he missed. He fired one round into a car that drove by, but then realized the people in the car were Latina and stopped shooting.

Mark Gassett, 37, was standing on a sidewalk near Catholic Charities. Muhammad shot him in the chest, and fired twice more after he fell to make sure he was dead.

He then set his sights on three white men standing at a bus stop. He shot and the men scattered. Muhammad said he selected the one who looked older and heavier, chasing David Jackson, 58, to the parking lot of a Catholic Charities building, where he shot him twice, killing him.

Muhammad ran from the parking lot, wrapped his gun in clothing and set it on the ground. He encountered a man carrying a box of food. They spoke. The man then took the gun from Muhammad and fled.

Police are pleading for the man to turn the weapon in.

Muhammad starting running, until he saw a police car, which was there within minutes. Dyer said he dropped two necklaces he was holding that he said were charms to ward off evil and gave himself up to police.

"I did it. I shot them," Muhammad told officers as they arrested him, according to the chief.