The gunman opened fire on a crowd at a pool party on Sunday in San Diego before being fatally shot by police

A gunman killed one woman and injured six other people on Sunday when he opened fire on a crowd at a bustling pool party in an upscale San Diego neighborhood, police say.

Peter Selis, 49, started shooting at guests at a birthday party in the La Jolla Crossroads complex at around 6 p.m., hitting four women — one of whom died — and three men, the New York Times reports. Six of the victims were black and one was Latino.

Get push notifications with news, features and more.

Responding officers spotted the man as he attempted to reload, according to the Times. Police fatally shot Selis after he pointed his weapon at them, authorities told the Times.

Image zoom AP Photo/Gregory Bull

“It was like a war zone or something,” Amit Godbole, who said he heard the gunfire from inside his apartment, told the San Diego Union-Tribune. “There would be three or four shots, a pause and then more shots. I was trying to count them. I counted 30 or 40.”

One witness said a partygoer offered Selis, a white man, food and drink. He allegedly declined and continued to sit in a chair by the pool just minutes before opening fire, according to the Union-Tribune.

“This was a truly horrific and disturbing act,” Mayor Kevin Faulconer wrote in a tweet. “We pray for the victims and thank our 1st responders. Our city rejects this senseless violence.”

The injured victims were taken to area hospitals, San Diego Police Chief Shelley Zimmerman said at a news conference.

• Want to keep up with the latest crime coverage? Click here to get breaking crime news, ongoing trial coverage and details of intriguing unsolved cases in the True Crime Newsletter.

Zimmerman said investigators are working to determine a motive for the incident. The shooting has not been declared a hate crime.

One witness who heard the commotion from a nearby hot tub told the Tribune that she heard Selis threaten partygoers who tried to help a victim.

Image zoom AP Photo/Gregory Bull

“You can either leave or you can stay here and die,” the witness said.

Witnesses reported hearing “a lot of screaming.” And in video footage of the incident, gunshots were heard as police scrambled at the scene.

One resident of the complex, Susan Berry, said students, doctors and military families all live at the complex. She said she was she was shocked by the attack, according to CNN.