When police found Thomas Phillips’s silver Toyota Hilux abandoned on Kiritehere Beach near Marokopa, New Zealand, the tide was flowing in and threatening to sweep away the vehicle.

Relatives last saw Phillips, 34, and his three young children on Sept. 11 at a family farm, Waikato police said in a statement on Facebook. Nothing seemed out of the ordinary during the visit, and relatives thought Phillips had probably taken his kids to the coast to catch tiny fish called whitebait, a local delicacy.

That weekend, the surf near Kiritehere Beach was rough, and waves beat into the shoreline before a strong current pulled the water back out to sea in a rush. When Phillips didn’t return to the farm with 8-year-old Jayda, 6-year-old Maverick and 5-year-old Ember, relatives worried the quartet may have been caught up in a violent swell.

“Because of where the vehicle was found we are understandably very anxious and fearful for the safety of Tom and the children,” the family said in a statement shared by Waikato police on Sept. 14. “It is possible that they were all swept off the beach as the sea was particularly wild over the weekend.”

The children’s mother, whose relationship with Phillips was unclear, urged anyone with information to contact authorities.

Police and volunteers searched the coastline for nearly two weeks. Officials sent search-and-rescue teams into the ocean. Volunteers combed through nearby brush and beach sands. Police flew a fixed-wing plane to scour the horizon for signs of the family and piloted drones to probe hard-to-reach terrain.

As time wore on, the family began to lose hope of finding Phillips and the kids alive.

“It had seemed pretty obvious that they had gone into the sea,” Rozzi Pethybridge, Phillips’s sister, told the New Zealand Herald on Thursday. “Hope dwindled and we sort of became more and more resigned, and sad, just deeply sad.”

Still, the family and community tried to keep their hope alive. Phillips was an avid outdoorsman who intimately knew the local terrain and had experience hunting and foraging in the bush during long bouts in the wilderness, the Otago Daily Times reported.

“There was just a feeling they were still alive,” Wikitoria Day, one of the search volunteers, told the Daily Times. ” … There wasn’t an eerie feeling out there, that’s for sure.”

After 12 days, the active search ended, and police said they would resume those efforts if members of the public found any trace of the missing dad and kids. Four more days passed with no sign of the Phillips family.

Then, five days after the search-and-rescue efforts ceased, Phillips and the three children walked through the doors of the family farm unharmed.

The family had gone on an extended camping trip in the dense New Zealand bush, police said, about nine miles south of the beach where Phillips’s truck was found. They appeared to be completely unaware that the local community had been desperately searching for them.

When Pethybridge learned that her brother had been found safe, she said she was able to smile for the first time in weeks.

“Getting a phone call to say that they had come home was just shocking, in the best way possible,” Pethybridge told the Herald. ” … We’re very, very happy, but [it’s been] hard too after such a long time and being braced for the worst and sort of resigning ourselves to the fact that we’d probably never see them all again.”

According to police, Phillips had diligently planned the camping trip but had not informed friends or family about the lengthy excursion. Police said they would continue to speak with the family to seek clarity about their movements during their time away.

Pethybridge said the kids were warm, dry and “perfectly healthy” when they returned home.

“It just goes down to Tom’s awesome skills as a bushman and as an outdoorsman,” she told the Herald.

Waikato West Area Commander Inspector Will Loughrin said in a statement on Wednesday that authorities are “so pleased that the family [has] returned home.”

“This is a family that experienced 17 days of hell, really,” he added at a news conference on Thursday. “This is a community that experienced 17 days of hell wondering what had happened to this family and these children. For the outcome to be what we always wanted is fantastic.”