A man armed with an assault weapon who fired shots inside an entertainment resort and casino in the capital, Manila, committed suicide by setting himself alight, Philippine police said on Friday.

“Our assessment is he burned himself. He committed suicide,” Oscar Albayalde, chief of the Manila police office, said in a radio interview.

The gunman burst into the casino, fired shots, and set gaming tables alight in Resorts World Manila early on Friday, sowing panic in a country on high alert after martial law was declared in the south. But police said the motive was likely to have been robbery.

National police chief Ronald dela Rosa told DZMM radio the lone gunman had not aimed his assault rifle at people at the entertainment complex during the hours-long drama that began shortly after midnight (16:00 GMT), and may have been trying to steal casino chips.

Around dawn, the body of the suspected gunman was found in a hotel room in the complex, which is close to Ninoy Aquino International Airport and an air force base.

READ MORE: Resorts World Manila complex on lockdown after attack

Police said it appeared the suspect had killed himself after firing at officers searching the still-smoking building.

“Our assessment is he burned himself. He committed suicide,” Oscar Albayalde, chief of the capital’s police office, said in a radio interview.

Officials said at least 30 people were hurt, some seriously, as they rushed to escape what at first had been feared as a “terrorist” attack.

Jeri Ann Santiago, who works in the emergency room at the San Juan de Dios hospital, close to Resorts World, said 13 people were being treated, but more were on the way.

Most of the patients were suffering the effects of smoke inhalation and some had injuries such as fractures, she said, adding none had gunshot wounds.

Kimberly Molitas, a spokeswoman for the capital’s police office, said $2.27m worth of casino chips stolen during the raid had been recovered.

Video footage captured by Al Jazeera also showed thick smoke billowing from one of the buildings in the complex. Local broadcaster ABS-CBN Television posted images on social media showing dozens of police officers, with firearms and bulletproof vests waiting at the entrance of one of the building in the area.

The incident in Manila comes as the entire country is on high alert following the attack by the Maute Group in the southern city of Marawi in Mindanao, which has killed more than 100 people, including many civilians.

Following the Marawi attack, Philippine President Rodrigo Duterte declared martial law in Mindanao. He also warned that the order could be expanded to cover the entire country if violence spreads.