SYDNEY (Reuters) - The father of a cave-diving Australian doctor died on Wednesday, shortly after his son played a key role in rescuing a boys’ soccer team trapped in a cave for two weeks in northern Thailand.

Soldiers walk after 12 soccer players and their coach were rescued near Tham Luang cave complex in the northern province of Chiang Rai, Thailand, July 10, 2018. REUTERS/Soe Zeya Tun

Anesthetist Richard Harris, who did the final medical checks of the 12 trapped boys and their coach, was among the divers who successfully ended on Tuesday a mission that had gripped the attention of the world.

“Early this morning Harry’s father passed away here in Adelaide ... after they’d all come out of the cave,” said Andrew Pearce, of rescue service MedSTAR in the Australian city, where Harris, also known as Harry, is a specialist.

“It was a complete, unexpected shock,” Pearce, the organization’s clinical services director, told reporters. He gave no cause of death or the age of Harris’ father, Jim.

“Harry put the mission first...now he’s having to come to deal with what actually happened overnight,” Pearce added. “You’ve given your all and then you find out the sad news about your father, who’s your best mate. That’s really, really tough.”

On Wednesday, Harris declined to comment to the Australian newspaper in Thailand.

The “Wild Boars,” aged between 11 and 16, and their 25-year-old coach were trapped on June 23 while exploring a cave complex in the province of Chiang Rai when a downpour flooded the passageways.

British divers found them, hungry and huddled in darkness on a muddy bank in a partly flooded chamber several kilometers inside it, on Monday last week.

Harris played a pivotal role in the rescue effort mounted after days of strategizing how to get the boys out, assessing their fitness for the perilous journey back to the outside.

“His unique skillset as a specialist doctor and his extensive experience as a cave diver were quintessential to the success of this operation,” Major Alex Rubin, of the Australian Defence Force, told reporters in Chiang Rai.

Australian Prime Minster Malcolm Turnbull, in a video he released of a conversation with Harris, offered his condolences and congratulations on the rescue’s success.

“No worries,” Harris is heard replying. “The big heroes in this are the children and the four Thai Navy SEALS who were looking after them. They are the toughest blokes and kids I have ever had the privilege to meet.”

In a condolence message to Harris on its Facebook page, the elite Thai Navy unit said, “We wish you the best for this very tough time. We never thank you enough for what you’ve done for the kids, their families and Thailand.”