HUALIEN, Taiwan -- Rescuers were working Wednesday to try to reach people who were trapped after a strong earthquake near Taiwan's east coast caused several buildings to cave in and tilt dangerously. At least six people were killed and 88 missing in the quake.

Video footage and photos showed several midsized buildings in worst-hit Hualien county leaning at sharp angles, their lowest floors crushed into mangled heaps of concrete, shattered glass, bent iron beams and other debris. Firefighters could be seen climbing ladders hoisted against windows as they sought to reach residents inside apartments.

The shallow, magnitude 6.4 quake that struck late Tuesday night caused at least four buildings to cave in and tilt dangerously.

Get Breaking News Delivered to Your Inbox

A maintenance worker who was rescued after being trapped in the basement of the Marshal Hotel, whose ground floor had caved in, said the force of the earthquake was unusual.

"At first it wasn't that big ... we get this sort of thing all the time and it's really nothing. But then it got really terrifying," the worker, Chen Ming-hui, told Taiwan's official Central News Agency after he was reunited with his son and grandson following the quake. "It was really scary."

Two employees of the hotel were killed in the disaster, CNA said. Taiwan's National Fire Agency said rescuers freed another employee from the rubble.

Other buildings shifted on their foundations and rescuers used ladders, ropes and cranes to get residents to safety.

Six people were killed in the quake, while 256 others were injured and 88 left unaccounted for, according to the fire agency. CNA reported that seven had been killed.

Rescue and emergency workers block off a street where a building came off its foundation, the morning after a 6.4 magnitude quake hit the eastern Taiwanese city of Hualien, on February 7, 2018 GETTY

The force of the tremor buckled roads and disrupted electricity and water supplies to thousands of households, the fire agency said.

Japan's Foreign Ministry said nine Japanese were among the injured. Six mainland Chinese were also injured, the Chinese Communist Party-run People's Daily reported.

Taiwanese President Tsai Ing-wen moved to reassure the Taiwanese public that every effort would be made to look for survivors. In a post on her official Facebook page, Tsai said she arrived in Hualien on Wednesday to review rescue efforts.

Tsai said she "ordered search and rescue workers not to give up on any opportunity to save people, while keeping their own safety in mind."

"This is when the Taiwanese people show their calm, resilience and love," she wrote. "The government will work with everyone to guard their homeland."

China's official Xinhua News Agency reported that the director of China's Taiwan Affairs office, Zhang Zhijun, said China was "willing to send a rescue team to Taiwan" to help with relief efforts, adding that he was aware of a shortage of rescue workers in the disaster area.

China Central Television reported that more than 40 of the missing people were trapped in the Yunmen Cuiti building, a 12-story apartment building. Rescue efforts at the building were suspended because the structure was sliding, according to Taiwan's Central Emergency Operation Center.

Rescue workers block off the area to search for survivors outside a building which tilted to one side after its foundation collapsed in Hualien after a strong 6.4-magnitude quake rocked eastern Taiwan early on February 7, 2018 GETTY

Taiwanese media reported that the Beautiful Life Hotel also was tilting. CNA posted photos showing a road fractured in several parts.

Bridges and some highways were closed pending inspections.

With aftershocks continuing to hit after the quake, residents were directed to shelters, including a newly built baseball stadium, where beds and hot food were provided.

Speaking from a crisis center in Taipei, Cabinet spokesman Hsu Kuo-yung said rail links appeared to be unaffected and the runway of Hualien airport was intact.

"We're putting a priority on Hualien people being able to return home to check on their loved ones," Hsu said.

The U.S. Geological Survey said the quake struck just before midnight Tuesday about 13 miles northeast of Hualien at a relatively shallow depth of about 6.6 miles.

Taiwan has frequent earthquakes due to its position along the "Ring of Fire," the seismic faults encircling the Pacific Ocean where most of the world's earthquakes occur.

Exactly two years earlier, a magnitude 6.4 quake collapsed an apartment complex in southern Taiwan, killing 115 people. Five people involved in the construction of the complex were later found guilty of negligence and given prison sentences.

A magnitude 7.6 quake in central Taiwan killed more than 2,300 people in 1999.