Late wickets gave New Zealand hope of winning the first Test against South Africa after they wasted chances on day four in Dunedin.
First-innings centurion Dean Elgar (89) and captain Faf Du Plessis (unbeaten 56) led South Africa to 224-6 at University Oval on Saturday.
The tourists edged their way to a 191-run lead before bad light again brought an early end to play.
Jeetan Patel (2-72) and Mitchell Santner (1-37) struck late in the day to give the Black Caps hopes of victory.
To add to their woes, Trent Boult (1-34) is battling a suspected groin strain – adding to the injury suffered by Ross Taylor earlier in the Test.
The hosts could be in complete control of the match if not for missed opportunities, while rain is expected to play a part on Sunday.
Weather delayed the start of play on day four before Hashim Amla (24) mistimed a Neil Wagner (2-57) delivery to depart.
Bad light briefly stopped play early in the day and run-scoring proved to be a major challenge throughout the first session.
The Black Caps wasted a poor review on JP Duminy for caught behind, before the left-hander was given a life, Tom Latham dropping a sitter at first slip.
It was the first of several early chances for New Zealand.
Duminy survived a huge lbw appeal off Patel, the Black Caps not reviewing a decision which would have been overturned.
They did review another lbw shout against Duminy shortly after, but the South Africa batsman got an inside edge onto a Patel delivery.
The frustrations continued for Kane Williamson and his team, BJ Watling diving to his left but dropping Elgar on 35.
Duminy finally went for 39 when he was trapped in front by Wagner, trying his luck with a review which failed.
Substitute fielder Colin de Grandhomme also dropped Elgar, who was given out caught behind off the last ball before tea but survived after a review.
South Africa showed no great urgency to push ahead and they were punished late in the day.
Elgar, finally chasing some quick runs, was caught by Williamson off Patel, before Temba Bavuma (6) and Quinton De Kock (4) went in quick succession to give New Zealand hope heading into day five.