He wins it in a wager. A gambler at heart, he plays a game of chance or skill with a cosmic entity—maybe Death itself. The stakes: his soul versus a spark of eternity. He wins, of course, but the entity twists the deal. He gets eternal power, but it's tied to a condition, like he must always be the antagonist, the catalyst for heroes to rise. His power is eternal as long as he plays his assigned role in the cosmic story. The first gain was rolling the dice. Now he's stuck in a narrative loop.