A man was shot during an attempted robbery in Hollywood early Thursday after grabbing the gun of one of the suspects, officials said.

The incident occurred just before 1 a.m. at the intersection of Wilcox and Selma avenues, according to the Los Angeles Police Department.

Two assailants walked up to the victim and demanded money. The victim refused, grabbed the gun of one of the suspects, and the second assailant allegedly shot the victim, police said.

The victim, described only as a man in his 20s, was taken to a hospital and is currently in stable condition.

Both assailants fled from the scene and continued firing shots, police said.

One of them was last seen running west on Selma Avenue. Witnesses say he’s about 6 feet tall and was wearing a blue jacket and khaki pants. A witness at a rooftop bar said he saw the other suspect causally walk away from the scene.

“It was crazy because after the first six, seven shots, everybody was inside the hotel and they were just popping back and forth at each other, like it was a freaking showdown,” the witness described to KTLA.

Both suspects remain outstanding.

A bullet hole was left at nearby Mama Shelter hotel. Employees told KTLA that another bullet ricocheted through a window of a guest room on the fifth floor, but no one else was injured, although the hotel’s general manager disputed that report.

No further details about the incident have been released.