Or at least, the body wasn’t that of Jesus.
Firstly, it is most unlikely that Pilate scourged Him that much. Pilate didn’t want Him killed, he wanted to release Jesus and did everything he could to encourage Him to proclaim His innocence. Pilate had been told by his wife that she had been warned in a dream that he should have nothing to do with this man. Pilate had to give Jesus a ritual scourging before releasing Him to the crowd but it isn’t realistic to expect him to inflict such a beating. The roman soldiers didn’t scourge Him at all, they mocked Him, slapped His face with the palms of their hands and beat his head with a reed.
Secondly He did not suffer over a 24 to 36 hour period for the bilirubin effect to take place, and in any case wasn’t in a state of shock, as He gave a small sermon to a group of women as He carried the cross up to Golgotha. He also spoke to one of the other criminals on the cross promising him a place in heaven.
Thirdly, there is no mention anywhere in the Bible, in prophecies or the NT, that he was nailed to the cross. There are two references in Acts to Him being hung from the tree (cross), not nailed to it. John 19:37 pretty much ends the argument – He hadn’t been pierced before He died, so had to be pierced by a spear so that the prophecy in Zech 12:10 would be fulfilled.
All these myths and legends distract people from the truth, which is that He died for our sins, that it was our sins that took Him to the cross and essentially killed Him. See Matt 26:37-38, the weight of our sins was beginning to crush His soul even unto death before He had been arrested. That’s what you need to believe, along with the fact that He returned to life on the Sunday. You don’t need to believe in shrouds, or bloody, sado-masochistic thrashings, nails or whatever. These are totally unscriptural distractions to what is really important, which is that by His sacrifice anyone who believes in Him will have eternal life.