The powerful quake damaged buildings and sent residents to higher ground.