World of Dreams

is episode 346 of the Naruto: Shippūden anime.

Summary
Still in disbelief, Obito walks over towards Rin's body, with Madara and White Zetsu's words echoing in his head. Phasing right through Kakashi's body as he went, he stopped only when he had reached Rin's corpse. Initially phasing through the kunoichi's body as he tried to hold her, Obito finally realises that she is in fact dead and as he cradled her lifeless form, vowed to create a world where she was alive, and change the fate of this world. After returning to Madara, as the elder Uchiha had predicted, and hearing from White Zetsu that no one saw them, he beckons the young Uchiha to his side. Telling Obito to look into his left eye, Madara takes the young man to a genjutsu where as a means to explain his plans, made himself look younger before telling Obito the story of the Sage of the Six Paths and the Ten-Tails. Some time after this, Obito and Zetsu would travel to Amegakure to meet Nagato — a young man of Senju lineage that Madara had implanted his Rinnegan which he had awoken before shutting himself away from the world. Obito remembers Madara telling him that he had acquired the dōjutsu after implanting Senju DNA into his body, but not until he had neared the end of his lifespan, did the dōjutsu awaken. Madara would later explain that this allowed him to summon the empty shell of the Ten-Tails and use it as a catalyst to cultivate the Hashirama's living clone. Madara would then teach Obito how to control the statue, several Uchiha kinjutsu and Yin–Yang Release. He, at some point, put his will into half of White Zetsu, thus creating Black Zetsu, and also into Hashirama's living clone, causing a black rod to extend from the clone's navel and told Obito to use it when he was going to use the Outer Path: Samsara of Heavenly Life Technique to revive him before breaking the connection to the statue. As life left the elder Uchiha's body, he told Obito to go until the time he was revived. At this point, Obito and Zetsu approach Nagato, with Obito announcing himself to be Madara Uchiha.