The 2015 film Avengers: Age of Ultron saw Earth's Mightiest Heroes take on the evil robot Ultron and his army of deadly drones, but the creation of Ultron itself was inspired by Tony Stark receiving an apocalyptic vision of a potential future fueled by a magical suggestion from Wanda Maximoff. And while the specific circumstances behind Tony's vision of the Avengers being defeated by Thanos did not come to pass, many of the ominous portents within the magical prophecy were fulfilled in their own indirect ways by the time Iron Man faced off against Thanos in  Avengers: Endgame.

Tony's nightmarish vision saw a triumphant Thanos sitting upon his throne in the cosmos, with the Avengers defeated and scattered at his feet. Obviously, while the final battle against Thanos in Endgame was set in the ruins of the Avengers headquarters in upstate New York, the heroes were handed a defeat on Thanos' home planet of Titan during Avengers: Infinity War as the supervillain bested his opponents and recovered the Infinity Stones they possessed by using a fully-powered Infinity Gauntlet. Tony's vision also saw a resurgent Chitauri armada at Thanos' command, following their explosive defeat in 2012's The Avengers, foreshadowing the Chitauri's return for the climactic battle in Endgame.

RELATED: MCU Theory: Black Widow's Red Guardian Is Slowly Dying - and His [SPOILER] Is to Blame

The Avengers' fates would similarly be hinted at by Tony's vision, most notably with Black Widow dead and the Hulk defeated. This sets up Bruce Banner being beaten down singlehandedly by Thanos at the start of Infinity War while Natasha Romanoff would sacrifice her life during Endgame. The most evident foreshadowing provided by Tony's vision involves Captain America on several different levels -- most visibly, Captain America's signature vibranium shield lies broken in two on the battlefield, hinting at Thanos eventually breaking the shield to pieces while fighting the Avengers in Endgame. In the vision, Steve Rogers would momentarily revive long enough to accuse Tony of not doing enough, an accusation that drives to create Ultron and alludes to the conflict between the two teammates that would result in the grand falling out of Captain America: Civil War.

While the creative team behind Age of Ultron certainly knew the Marvel Cinematic Universe was heading towards an eventual showdown against Thanos over the Infinity Gauntlet, as evidenced by Age of Ultron's mid-credits scene featuring Thanos preparing to take the initiative, there was the details of the coming confrontation were likely largely undefined at that point. Similarly, the creative team behind Infinity War and Endgame did not have to follow the prophetic roadmap laid out by Age of Ultron but the synchronicity between Tony's vision and what it predicted for the MCU lines up rather nicely, underscoring how outmatched the Avengers in their current state are against the coming Mad Titan.

RELATED: Moon Knight Trailer Has MCU Fans Infatuated With Oscar Isaac’s Marvel Hero

Obviously, Tony's Age of Ultron vision and the actual way events unfolded in the MCU involving the Avengers' battle against Thanos are not a perfect sync, but it does predict the final fates of major characters with a surprising amount of accuracy. Given that the vision was generated by the Scarlet Witch to throw off Tony and help divide the Avengers from within, this is particularly impressive and perhaps a sign of the immense magical power Wanda is truly capable of, as revealed in WandaVision. The only major detail missing is Tony's own untimely end, with the Armored Avenger discovering his own destiny as he fashioned his own Infinity Gauntlet and paid the ultimate price to prevent the Mad Titan from attaining a decisive victory.

KEEP READING: Why a Martin Scorsese Kingpin Film Would Be an Epic MCU Addition