The magnitude-5.3 quake was recorded 5km off the coast of Mackay on Thursday afternoon by Geoscience Australia.