South Africa captain Faf du Plessis scored 118 not out before declaring on 259-9 on the first day of the third Test against Australia in Adelaide.
Du Plessis went into the day-night match having been fined for ball-tampering in the second Test, and was booed on his way to the crease.
He responded with a century as wickets fell around him and put the hosts into bat for the day’s final 12 overs.
Australia reached 14-0 with the pink ball under lights by the close.
Usman Khawaja had to fill in as opener for David Warner, who was not allowed to bat having spent time off the pitch for treatment to a shoulder injury.
Du Plessis admitted he made his declaration after Warner spoke to the umpires.
“I listened to the conversation he had with the umpires – one ear talking to the batter, one ear listening to him,” said Du Plessis.
“And then I heard he had six minutes left before he could bat again so I thought ‘let’s have a crack’.”
The hosts, 2-0 down in the three-match series, had made five changes from the second Test defeat, with batsmen Matthew Renshaw, Peter Handscomb and Nic Maddinson making their debuts.
Wicketkeeper Matthew Wade and bowler Jackson Bird were also recalled and Australia quickly made inroads into the tourists’ line-up, with Josh Hazlewood taking 4-68.
Du Plessis stood firm, though, and his declaration was the second lowest in an opening innings of a Test in Australia.
The South Africa captain was fined 100% of his match fee after television footage appeared to show the 32-year-old licking his finger and shining the ball while eating a sweet in the second Test.
Du Plessis pleaded not guilty to the charge and denied any wrongdoing as he claimed he had been made a “scapegoat”.
It’s not cheating – Woakes
England bowler Chris Woakes, who is in India for the side’s ongoing Test series, called the issue a “grey area”.
“A lot of people have said I think we all shine the ball in a very similar way,” he told BBC Radio 5 live. “You don’t try and overstep the rules of the game.
“We all shine the ball, we all try and make the balls move in the air as, otherwise, it’d be a pretty dull game if it didn’t.
“I heard Hashim Amla saying about having chewing gum in his mouth and if he is shining the ball is that deemed as cheating? I don’t think that is deemed as cheating.”
Despite Du Plessis’ century, the Adelaide Advertiser preferred to concentrate on Australia’s hard-fought 14-0 on their sports pages.
After a series of humiliating collapses, maybe such an achievement should be cheered?
Subscribe to the BBC Sport newsletter to get our pick of news, features and video sent to your inbox.