Wiaan Mulder arrived at the Wanderers in October 2016 with a helmet, hope and homework. He was 17 and already earmarked for bigger things.

Geoffrey Toyana, the Lions coach at the time, had heard about a schoolboy allrounder who was being courted by other franchises, so he had gone down to St Stithians, one of South Africa's most prestigious schools, the alma mater of Kagiso Rabada among others, to see what the fuss was all about.

Toyana was so impressed by Mulder at the school that he nearly guaranteed him a place in the Lions first XI. "I remember saying to him that we don't have many allrounders at the Lions and that if Dwaine Pretorius got selected by the Proteas, [Mulder] would be the next guy in," Toyana said. "Within a week Dwaine was selected and even though Wiaan was busy with his school exams at that point, I couldn't go back on my word."

Pretorius' call-up to South Africa's ODI squad came at the beginning of the 2016-17 season, when the domestic franchises were about to kick off their four-day competition. Mulder slotted straight into a high-performing Lions side with a strong bowling attack - bypassing the second-tier provincial structure entirely - and made his debut against the historically strong Cape Cobras. He bowled second change and took three wickets in the first innings. In the next, he was promoted to first change and took four more. Mulder had hit the big time while still occupied with his studies and turning up for training in his school uniform.

In his next match, Mulder took what are still his career-best figures, 7 for 25 against a Dolphins team that included Imraan Khan, Morne van Wyk and Keshav Maharaj. A week later he scored his maiden first-class hundred, batting at No. 8 against a Knights attack featuring Duanne Olivier and Marchant de Lange.

"He had to bring his books into the change room to study," Toyana said. "And we could all see he was talented. He could bat, he could bowl, and I was planning to use him at No. 5. We knew we had a gem in him."

From his early days Mulder was labelled a batting allrounder in the mould of - don't say it too loudly - Jacques Kallis, and the numbers explain why. In 35 first-class matches, he has five hundreds - four at franchise level and one against India A in Mysore - and a batting average closing in on 40. Three of those matches came for Kent, for whom he played briefly in 2019.

But in his fledgling international career he appears to have been used largely as a bowing allrounder. Although he first played for South Africa in 2017, Mulder has really come to notice only now, after taking nine wickets at 20.55 in the 2-0 win over Sri Lanka at home this season.

Mulder made his ODI debut at the start of Ottis Gibson's coaching tenure, when South Africa were looking for 2019 World Cup candidates, but back and ankle injuries dominated his next two summers.

"He was carrying a lot of weight," said Enoch Nkwe, who succeeded Toyana at the Lions and now works as South Africa's assistant coach. At one point Mulder weighed 106kg and he knew he needed to shed some of it to be able to stay on the park. He was putting too much stress on his lower back, partly because of the weight, but more because of the way his forearm fell away when he delivered the ball. He had to work on straightening his arm and landing with his torso approximately in the same plane as his hips to make his action more efficient and less damaging.

He changed his diet, and on former South Africa fast bowler Morne Morkel's recommendation, worked with Andrew Gray, a biokineticist, and his wife Janine, a researcher who holds a PhD in lower back pain in adolescent fast bowlers. In the couple, Mulder found people who could help him understand his physique and how to make it work for him.

"He has the right physios, the right medical team and the right coaching around him, and he has been able to pick himself up and find new ways of reaching new levels," Nkwe said.

But it wasn't all smooth sailing. The following year Mulder battled with an ankle issue and missed the 2019-20 international summer with further injury problems. His time off was sobering and he realised he had to work his way back almost from the beginning.

Although Mulder went to an elite school, he comes from humble beginnings on Johannesburg's West Rand. His parents were not financially flush and put all their resources into ensuring Mulder and his younger brother got the best opportunities.

When available, Mulder plays his club cricket at the Dobsonville Cricket Club in Soweto, which is notable because Mulder is white and the club is situated in an area the apartheid-era government had demarcated for black Africans, and which still has a majority population of colour. "Some of the young white players who are from schools where they are coached by young black coaches end up playing at clubs like Dobsonville and they are encouraged to mix with different cultures," Toyana said.

In a country polarised by racial inequality, Mulder's experience in Soweto would have been eye-opening, and it will be interesting to see how it affects the way he and South Africa's next generation of players relate to each other. For now, he has shown an impressive level of maturity in the national set-up. When fellow quick bowler Lutho Sipamla, with whom he played at the Under-19 level, was struggling early in his first Test - going for 66 runs in 12 wicketless overs - Mulder told him to trust his ability, keep running in and to believe it would work for him. Sipamla took ten wickets for 101 across the two Tests against Sri Lanka, finishing the series in second place on the bowlers' list, right above Mulder and below Anrich Nortje.

Mulder bowled 12.5 more overs than Sipamla, taking on the role of doing the donkey work with full commitment. He explained that he understood his role as being a container and that his nine wickets at 20.55 were a bonus. In fact, the bonus for South Africa was the load that Mulder willingly carried.

Nkwe cautioned that they will have to expect him to not bowl so much in the future. "We shouldn't get too excited and allow him to bowl long spells. We understand that with the scheduling, if we start to fall into that trap of allowing bowlers to bowl long spells, it could catch up with us in three or four months' time. It is part of player management to ensure that players don't get burnt out or break down. He needs to continue to see himself as a batting allrounder and go after that."

Scores of 36 and 7 in the Sri Lanka series don't necessarily indicate what Mulder is capable of. Ultimately South Africa want him to develop into a top-order allrounder in the Kallis mould. Though Quinton de Kock is currently installed at No. 5, it is not the position he performs best in (that's No. 7), and over time it is likely that Temba Bavuma and Mulder will leapfrog de Kock into the top six. But South Africa don't want to rush Mulder.

"Technically there is still some work to do. He's got a good cricket brain, he has got the skills, and I have no doubt he is one for the future," Nkwe said. "There is going to be a lot of information thrown at him, so he needs to be smart about what resonates with him in this journey of becoming an all-round cricketer. We will do our best to guide him in the right direction but he will also have to do his homework," Nkwe said.

And if there is one thing Mulder knows how to do, it's homework at the cricket.

Firdose Moonda is ESPNcricinfo's South Africa correspondent